ie_icnn_network_stats.hpp
Go to the documentation of this file.
1 // Copyright (C) 2018-2019 Intel Corporation
2 // SPDX-License-Identifier: Apache-2.0
3 //
4 
5 /**
6  * @brief This is a header file for the ICNNNetworkStats class
7  * @file ie_icnn_network_stats.hpp
8  */
9 #pragma once
10 
11 #include <string>
12 #include <memory>
13 #include <limits>
14 #include <vector>
15 #include <map>
16 #include "details/ie_irelease.hpp"
17 
18 namespace InferenceEngine {
19 
20 class NetworkNodeStats;
21 
22 using NetworkNodeStatsPtr = std::shared_ptr<NetworkNodeStats>;
23 using NetworkNodeStatsWeakPtr = std::weak_ptr<NetworkNodeStats>;
24 using NetworkStatsMap = std::map<std::string, NetworkNodeStatsPtr>;
25 /**
26  * @class ICNNNetworkStats
27  * @brief This is the interface to describe the NN topology scoring statistics
28  */
29 class ICNNNetworkStats : public details::IRelease {
30 public:
31  virtual void setNodesStats(const NetworkStatsMap& stats) = 0;
32  virtual const NetworkStatsMap& getNodesStats() const = 0;
33 
34  virtual bool isEmpty() const = 0;
35 };
36 
37 
39 public:
40  NetworkNodeStats() { }
41  explicit NetworkNodeStats(int statCount) {
42  float mn = (std::numeric_limits<float>::max)();
43  float mx = (std::numeric_limits<float>::min)();
44 
45  for (int i = 0; i < statCount; i++) {
46  _minOutputs.push_back(mn);
47  _maxOutputs.push_back(mx);
48  }
49  }
50 
51 public:
52  std::vector<float> _minOutputs;
53  std::vector<float> _maxOutputs;
54 };
55 
56 
57 } // namespace InferenceEngine
Definition: ie_argmax_layer.hpp:11
Definition: ie_icnn_network_stats.hpp:38
A header file for the Inference Engine plugins destruction mechanism.
This is the interface to describe the NN topology scoring statistics.
Definition: ie_icnn_network_stats.hpp:29