diff options
author | Matthew Sloyan <matthew.sloyan@arm.com> | 2021-01-18 16:10:20 +0000 |
---|---|---|
committer | Jim Flynn <jim.flynn@arm.com> | 2021-01-29 15:41:29 +0000 |
commit | 4f29f156599e0d1ebf5b9b5423450ba2ae3288b4 (patch) | |
tree | 97099227f3dc41647f28e7679e4e35b4a12f408c | |
parent | 7909c53e3b91f96a12f2d587741575d4d1becdce (diff) | |
download | armnn-4f29f156599e0d1ebf5b9b5423450ba2ae3288b4.tar.gz |
IVGCVSW-5484 Add Network loading time to InferenceModel
* Added output log to capture time taken to load network into runtime.
* This time is cut down when loading a cached network.
Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com>
Change-Id: I043c177f17d01df35fbe0752ec5d77e350749164
-rw-r--r-- | tests/InferenceModel.hpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/InferenceModel.hpp b/tests/InferenceModel.hpp index 7daae26bd4..936d0bf9ea 100644 --- a/tests/InferenceModel.hpp +++ b/tests/InferenceModel.hpp @@ -464,7 +464,12 @@ public: armnn::Status ret; { ARMNN_SCOPED_HEAP_PROFILING("LoadNetwork"); + + const auto loading_start_time = armnn::GetTimeNow(); ret = m_Runtime->LoadNetwork(m_NetworkIdentifier, std::move(optNet)); + + ARMNN_LOG(info) << "Network loading time: " << std::setprecision(2) + << std::fixed << armnn::GetTimeDuration(loading_start_time).count() << " ms\n"; } if (ret == armnn::Status::Failure) |