diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/armnn/IRuntime.hpp | 5 | ||||
-rw-r--r-- | include/armnn/Types.hpp | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/include/armnn/IRuntime.hpp b/include/armnn/IRuntime.hpp index b977afe5e7..44864ce86d 100644 --- a/include/armnn/IRuntime.hpp +++ b/include/armnn/IRuntime.hpp @@ -83,6 +83,11 @@ public: /// @return A pointer to the requested profiler, or nullptr if not found. virtual const std::shared_ptr<IProfiler> GetProfiler(NetworkId networkId) const = 0; + /// Registers a callback function to debug layers performing custom computations on intermediate tensors. + /// @param networkId The id of the network to register the callback. + /// @param func callback function to pass to the debug layer. + virtual void RegisterDebugCallback(NetworkId networkId, const DebugCallbackFunction& func) = 0; + protected: ~IRuntime() {} }; diff --git a/include/armnn/Types.hpp b/include/armnn/Types.hpp index 36e3c5b52a..693a050586 100644 --- a/include/armnn/Types.hpp +++ b/include/armnn/Types.hpp @@ -180,4 +180,9 @@ private: /// Define LayerGuid type. using LayerGuid = unsigned int; +class ITensorHandle; + +/// Define the type of callback for the debug layer to call +using DebugCallbackFunction = std::function<void(LayerGuid, unsigned int, ITensorHandle*)>; + } // namespace armnn |