diff options
author | Keith Davis <keith.davis@arm.com> | 2021-08-09 16:49:18 +0100 |
---|---|---|
committer | Matthew Sloyan <matthew.sloyan@arm.com> | 2021-08-10 14:07:27 +0000 |
commit | f487486c843a38fced90229923433d09f99fc2e5 (patch) | |
tree | 63a2268196279a5c97c3b9dea86024f0bf4a751e /src/armnn/Profiling.cpp | |
parent | bcd860a30eba22bb2ba0943ad705734ce0ec5b23 (diff) | |
download | armnn-f487486c843a38fced90229923433d09f99fc2e5.tar.gz |
IVGCVSW-6292 Allow profiling details to be switched off during profiling
* Add switch for network details during profiling
Signed-off-by: Keith Davis <keith.davis@arm.com>
Change-Id: I8bd49fd58f0e0255598106e9ab36806ee78391d6
Diffstat (limited to 'src/armnn/Profiling.cpp')
-rw-r--r-- | src/armnn/Profiling.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/armnn/Profiling.cpp b/src/armnn/Profiling.cpp index 509e9dec08..b9afc8665a 100644 --- a/src/armnn/Profiling.cpp +++ b/src/armnn/Profiling.cpp @@ -196,6 +196,11 @@ void ProfilerImpl::EnableProfiling(bool enableProfiling) m_ProfilingEnabled = enableProfiling; } +void ProfilerImpl::EnableNetworkDetailsToStdOut() +{ + m_EnableDetailsToStdOut = true; +} + Event* ProfilerImpl::BeginEvent(armnn::IProfiler* profiler, const BackendId& backendId, const std::string& label, @@ -378,7 +383,7 @@ void ProfilerImpl::Print(std::ostream& outStream) const printer.PrintHeader(); printer.PrintArmNNHeader(); - if (m_ProfilingDetails.get()->DetailsExist()) + if (m_ProfilingDetails.get()->DetailsExist() && m_EnableDetailsToStdOut) { JsonChildObject detailsObject{ "layer_details" }; ConfigureDetailsObject(detailsObject, m_ProfilingDetails.get()->GetProfilingDetails()); @@ -539,6 +544,11 @@ void IProfiler::EnableProfiling(bool enableProfiling) pProfilerImpl->EnableProfiling(enableProfiling); } +void IProfiler::EnableNetworkDetailsToStdOut() +{ + pProfilerImpl->EnableNetworkDetailsToStdOut(); +} + bool IProfiler::IsProfilingEnabled() { return pProfilerImpl->IsProfilingEnabled(); |