24.02.1
|
Go to the documentation of this file.
24 #ifndef ARM_COMPUTE_GRAPH_BACKENDS_UTILS_H
25 #define ARM_COMPUTE_GRAPH_BACKENDS_UTILS_H
44 template <
typename FunctionType,
typename FunctionNameType,
typename... ParameterType>
46 ParameterType...
args)
48 auto f = std::make_unique<FunctionType>();
49 f->configure(std::forward<ParameterType>(
args)...);
50 return std::make_pair(std::move(f),
name);
61 template <
typename FunctionType,
typename FunctionNameType,
typename MemoryManagerType,
typename... ParameterType>
62 std::tuple<std::unique_ptr<arm_compute::IFunction>, FunctionNameType>
65 auto f = std::make_unique<FunctionType>(mm);
66 f->configure(std::forward<ParameterType>(
args)...);
67 return std::make_pair(std::move(f),
name);
79 return (output ==
nullptr) || (
input == output);
MemoryManagerContext * memory_management_ctx(Target target)
Gets a memory manager context for a given target.
const GraphConfig & config() const
Graph configuration accessor.
bool use_function_memory_manager
Use a memory manager to manage per-function auxilary memory.
WeightsManagerContext * weights_management_ctx(Target target)
Gets a weights manager context for a given target.
std::tuple< std::unique_ptr< arm_compute::IFunction >, FunctionNameType > create_named_memory_managed_function(FunctionNameType name, MemoryManagerType mm, ParameterType... args)
Creates and configures a named function.
std::shared_ptr< IWeightsManager > get_weights_manager(GraphContext &ctx, Target target)
Returns the weights manager for a given target.
std::tuple< std::unique_ptr< arm_compute::IFunction >, FunctionNameType > create_named_function(FunctionNameType name, ParameterType... args)
Creates and configures a named function.
std::shared_ptr< IMemoryManager > get_memory_manager(GraphContext &ctx, Target target)
Returns the memory manager for a given target.
bool use_function_weights_manager
Use a weights manager to manage transformed weights.
Copyright (c) 2017-2024 Arm Limited.
bool is_in_place_operation(void *input, void *output)
Checks if an operation is in place.
std::shared_ptr< arm_compute::IWeightsManager > wm
Weights manager.
std::shared_ptr< arm_compute::IMemoryManager > intra_mm
Intra-function memory manager.