24.02
|
Go to the documentation of this file.
60 return m_MemoryManagers;
64 std::vector<std::unique_ptr<ITensorHandleFactory>> m_Factories;
65 std::vector<std::shared_ptr<IMemoryManager>> m_MemoryManagers;
void ReleaseMemory()
Release memory required for inference.
ITensorHandleFactory * GetFactory(ITensorHandleFactory::FactoryId id) const
Find a TensorHandleFactory by Id Returns nullptr if not found.
std::vector< std::shared_ptr< IMemoryManager > > & GetMemoryManagers()
void RegisterMemoryManager(std::shared_ptr< IMemoryManager > memoryManger)
Register a memory manager with shared ownership.
ITensorHandleFactory::FactoryId GetMatchingImportFactoryId(ITensorHandleFactory::FactoryId copyFactoryId)
Get a matching TensorHandleFatory Id for Memory Import given TensorHandleFactory Id for Memory Copy.
void AquireMemory()
Aquire memory required for inference.
TensorHandleFactoryRegistry()=default
MemorySource
Define the Memory Source to reduce copies.
Copyright (c) 2021 ARM Limited and Contributors.
void RegisterFactory(std::unique_ptr< ITensorHandleFactory > allocator)
Register a TensorHandleFactory and transfer ownership.
std::map< ITensorHandleFactory::FactoryId, ITensorHandleFactory::FactoryId > CopyAndImportFactoryPairs
void RegisterCopyAndImportFactoryPair(ITensorHandleFactory::FactoryId copyFactoryId, ITensorHandleFactory::FactoryId importFactoryId)
Register a pair of TensorHandleFactory Id for Memory Copy and TensorHandleFactory Id for Memory Impor...