From 8efb48a6847c5cd166c561127ae6611150963ce3 Mon Sep 17 00:00:00 2001 From: Nikhil Raj Date: Fri, 19 May 2023 11:14:28 +0100 Subject: Update Doxygen docu for 23.05 Signed-off-by: Nikhil Raj Change-Id: I0a992286f14fa68fcc6e5eba31ac39fed003cbbe --- 23.05/_instrument_8hpp_source.xhtml | 203 ++++++++++++++++++++++++++++++++++++ 1 file changed, 203 insertions(+) create mode 100644 23.05/_instrument_8hpp_source.xhtml (limited to '23.05/_instrument_8hpp_source.xhtml') diff --git a/23.05/_instrument_8hpp_source.xhtml b/23.05/_instrument_8hpp_source.xhtml new file mode 100644 index 0000000000..905b39b92b --- /dev/null +++ b/23.05/_instrument_8hpp_source.xhtml @@ -0,0 +1,203 @@ + + + + + + + + + + + + + +ArmNN: src/armnn/Instrument.hpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  23.05 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+
+
Instrument.hpp
+
+
+Go to the documentation of this file.
1 //
+
2 // Copyright © 2017 Arm Ltd. All rights reserved.
+
3 // SPDX-License-Identifier: MIT
+
4 //
+
5 
+
6 #pragma once
+
7 
+
8 #include <string>
+
9 #include <vector>
+
10 
+
11 namespace armnn
+
12 {
+
13 
+ +
15 {
+
16  enum Unit
+
17  {
+ + + +
21  };
+
22 
+
23  inline static const char* ToString(Unit unit)
+
24  {
+
25  switch (unit)
+
26  {
+
27  case TIME_NS: return "ns";
+
28  case TIME_US: return "us";
+
29  case TIME_MS: return "ms";
+
30  default: return "";
+
31  }
+
32  }
+
33 
+
34  Measurement(const std::string& name, double value, Unit unit)
+
35  : m_Name(name)
+
36  , m_Value(value)
+
37  , m_Unit(unit)
+
38  {}
+
39  Measurement(const Measurement&) = default;
+
40  ~Measurement() = default;
+
41 
+
42  std::string m_Name;
+
43  double m_Value;
+ +
45 
+
46 private:
+
47  // please don't default construct, otherwise Units will be wrong
+
48  Measurement() = delete;
+
49 };
+
50 
+ +
52 {
+
53 public:
+
54  virtual ~Instrument() {}
+
55 
+
56  virtual void Start() = 0;
+
57 
+
58  virtual void Stop() = 0;
+
59 
+
60  virtual std::vector<Measurement> GetMeasurements() const = 0;
+
61 
+
62  virtual const char* GetName() const = 0;
+
63 
+
64  virtual bool HasKernelMeasurements() const { return false;}
+
65 
+
66 };
+
67 
+
68 } //namespace armnn
+
+
+ +
virtual std::vector< Measurement > GetMeasurements() const =0
+ +
~Measurement()=default
+
virtual void Start()=0
+ + +
Copyright (c) 2021 ARM Limited and Contributors.
+
Measurement(const std::string &name, double value, Unit unit)
Definition: Instrument.hpp:34
+ +
std::string m_Name
Definition: Instrument.hpp:42
+
static const char * ToString(Unit unit)
Definition: Instrument.hpp:23
+
virtual const char * GetName() const =0
+
virtual bool HasKernelMeasurements() const
Definition: Instrument.hpp:64
+ +
virtual ~Instrument()
Definition: Instrument.hpp:54
+
virtual void Stop()=0
+ + + + + + -- cgit v1.2.1