From 6940dd720ebb6b3d1df8ca203ab696daefe58189 Mon Sep 17 00:00:00 2001 From: Jim Flynn Date: Fri, 20 Mar 2020 12:25:56 +0000 Subject: renamed Documentation folder 20.02 and added .nojekyll file Signed-off-by: Jim Flynn --- 20.02/classarmnn_1_1_ref_comparison_workload.xhtml | 282 +++++++++++++++++++++ 1 file changed, 282 insertions(+) create mode 100644 20.02/classarmnn_1_1_ref_comparison_workload.xhtml (limited to '20.02/classarmnn_1_1_ref_comparison_workload.xhtml') diff --git a/20.02/classarmnn_1_1_ref_comparison_workload.xhtml b/20.02/classarmnn_1_1_ref_comparison_workload.xhtml new file mode 100644 index 0000000000..ca08ea0967 --- /dev/null +++ b/20.02/classarmnn_1_1_ref_comparison_workload.xhtml @@ -0,0 +1,282 @@ + + + + + + + + + + + + + +ArmNN: RefComparisonWorkload Class Reference + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  20.02 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+ +
+
RefComparisonWorkload Class Reference
+
+
+ +

#include <RefComparisonWorkload.hpp>

+
+Inheritance diagram for RefComparisonWorkload:
+
+
+ + +BaseWorkload< ComparisonQueueDescriptor > +IWorkload + +
+ + + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 RefComparisonWorkload (const ComparisonQueueDescriptor &descriptor, const WorkloadInfo &info)
 
void PostAllocationConfigure () override
 
void Execute () const override
 
- Public Member Functions inherited from BaseWorkload< ComparisonQueueDescriptor >
 BaseWorkload (const ComparisonQueueDescriptor &descriptor, const WorkloadInfo &info)
 
void PostAllocationConfigure () override
 
const ComparisonQueueDescriptorGetData () const
 
profiling::ProfilingGuid GetGuid () const final
 
- Public Member Functions inherited from IWorkload
virtual ~IWorkload ()
 
virtual void RegisterDebugCallback (const DebugCallbackFunction &)
 
+ + + + + + +

+Additional Inherited Members

- Protected Attributes inherited from BaseWorkload< ComparisonQueueDescriptor >
const ComparisonQueueDescriptor m_Data
 
const profiling::ProfilingGuid m_Guid
 
+

Detailed Description

+
+

Definition at line 16 of file RefComparisonWorkload.hpp.

+

Constructor & Destructor Documentation

+ +

◆ RefComparisonWorkload()

+ +
+
+ + + + + + + + + + + + + + + + + + +
RefComparisonWorkload (const ComparisonQueueDescriptordescriptor,
const WorkloadInfoinfo 
)
+
+ +

Definition at line 22 of file RefComparisonWorkload.cpp.

+
24  : BaseWorkload<ComparisonQueueDescriptor>(desc, info)
25 {}
+
+
+
+

Member Function Documentation

+ +

◆ Execute()

+ +
+
+ + + + + +
+ + + + + + + +
void Execute () const
+
+overridevirtual
+
+ +

Implements IWorkload.

+ +

Definition at line 39 of file RefComparisonWorkload.cpp.

+ +

References ARMNN_SCOPED_PROFILING_EVENT, CHECK_LOCATION, armnn::CpuRef, armnn::Equal, armnn::GetComparisonOperationAsCString(), TensorInfo::GetShape(), armnn::GetTensorInfo(), armnn::Greater, armnn::GreaterOrEqual, armnn::Less, armnn::LessOrEqual, BaseWorkload< ComparisonQueueDescriptor >::m_Data, QueueDescriptor::m_Inputs, ComparisonDescriptor::m_Operation, QueueDescriptor::m_Outputs, QueueDescriptorWithParameters< LayerDescriptor >::m_Parameters, and armnn::NotEqual.

+
40 {
41  ARMNN_SCOPED_PROFILING_EVENT(Compute::CpuRef, "RefComparisonWorkload_Execute");
42 
43  const TensorInfo& inputInfo0 = GetTensorInfo(m_Data.m_Inputs[0]);
44  const TensorInfo& inputInfo1 = GetTensorInfo(m_Data.m_Inputs[1]);
45  const TensorInfo& outputInfo = GetTensorInfo(m_Data.m_Outputs[0]);
46 
47  const TensorShape& inShape0 = inputInfo0.GetShape();
48  const TensorShape& inShape1 = inputInfo1.GetShape();
49  const TensorShape& outShape = outputInfo.GetShape();
50 
51  m_Input0->Reset(m_Data.m_Inputs[0]->Map());
52  m_Input1->Reset(m_Data.m_Inputs[1]->Map());
53  m_Output->Reset(m_Data.m_Outputs[0]->Map());
54 
55  using EqualFunction = ElementwiseBinaryFunction<std::equal_to<InType>>;
56  using GreaterFunction = ElementwiseBinaryFunction<std::greater<InType>>;
57  using GreaterOrEqualFunction = ElementwiseBinaryFunction<std::greater_equal<InType>>;
58  using LessFunction = ElementwiseBinaryFunction<std::less<InType>>;
59  using LessOrEqualFunction = ElementwiseBinaryFunction<std::less_equal<InType>>;
60  using NotEqualFunction = ElementwiseBinaryFunction<std::not_equal_to<InType>>;
61 
63  {
65  {
66  EqualFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
67  break;
68  }
70  {
71  GreaterFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
72  break;
73  }
75  {
76  GreaterOrEqualFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
77  break;
78  }
80  {
81  LessFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
82  break;
83  }
85  {
86  LessOrEqualFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
87  break;
88  }
90  {
91  NotEqualFunction(inShape0, inShape1, outShape, *m_Input0, *m_Input1, *m_Output);
92  break;
93  }
94  default:
95  {
96  throw InvalidArgumentException(std::string("Unsupported comparison operation ") +
98  }
99  }
100 }
+
CPU Execution: Reference C++ kernels.
+ + +
const ComparisonQueueDescriptor m_Data
Definition: Workload.hpp:46
+
const TensorInfo & GetTensorInfo(const ITensorHandle *tensorHandle)
float32 helpers
+ +
#define ARMNN_SCOPED_PROFILING_EVENT(backendId, name)
Definition: Profiling.hpp:169
+ +
#define CHECK_LOCATION()
Definition: Exceptions.hpp:192
+
ComparisonOperation m_Operation
Specifies the comparison operation to execute.
Definition: Descriptors.hpp:78
+
std::vector< ITensorHandle * > m_Outputs
+
constexpr char const * GetComparisonOperationAsCString(ComparisonOperation operation)
Definition: TypesUtils.hpp:57
+
std::vector< ITensorHandle * > m_Inputs
+ + +
+
+
+ +

◆ PostAllocationConfigure()

+ +
+
+ + + + + +
+ + + + + + + +
void PostAllocationConfigure ()
+
+overridevirtual
+
+ +

Implements IWorkload.

+ +

Definition at line 27 of file RefComparisonWorkload.cpp.

+ +

References armnn::GetTensorInfo(), BaseWorkload< ComparisonQueueDescriptor >::m_Data, QueueDescriptor::m_Inputs, and QueueDescriptor::m_Outputs.

+
28 {
29  const TensorInfo& inputInfo0 = GetTensorInfo(m_Data.m_Inputs[0]);
30  const TensorInfo& inputInfo1 = GetTensorInfo(m_Data.m_Inputs[1]);
31  const TensorInfo& outputInfo = GetTensorInfo(m_Data.m_Outputs[0]);
32 
33  m_Input0 = MakeDecoder<InType>(inputInfo0);
34  m_Input1 = MakeDecoder<InType>(inputInfo1);
35 
36  m_Output = MakeEncoder<OutType>(outputInfo);
37 }
const ComparisonQueueDescriptor m_Data
Definition: Workload.hpp:46
+
const TensorInfo & GetTensorInfo(const ITensorHandle *tensorHandle)
float32 helpers
+
std::vector< ITensorHandle * > m_Outputs
+
std::vector< ITensorHandle * > m_Inputs
+
+
+
+
The documentation for this class was generated from the following files: +
+
+ + + + -- cgit v1.2.1