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_neon_constant_workload.xhtml | 233 ++++++++++++++++++++++ 1 file changed, 233 insertions(+) create mode 100644 20.02/classarmnn_1_1_neon_constant_workload.xhtml (limited to '20.02/classarmnn_1_1_neon_constant_workload.xhtml') diff --git a/20.02/classarmnn_1_1_neon_constant_workload.xhtml b/20.02/classarmnn_1_1_neon_constant_workload.xhtml new file mode 100644 index 0000000000..84db1ae965 --- /dev/null +++ b/20.02/classarmnn_1_1_neon_constant_workload.xhtml @@ -0,0 +1,233 @@ + + + + + + + + + + + + + +ArmNN: NeonConstantWorkload Class Reference + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  20.02 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+ +
+
NeonConstantWorkload Class Reference
+
+
+ +

#include <NeonConstantWorkload.hpp>

+
+Inheritance diagram for NeonConstantWorkload:
+
+
+ + +BaseWorkload< ConstantQueueDescriptor > +IWorkload + +
+ + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 NeonConstantWorkload (const ConstantQueueDescriptor &descriptor, const WorkloadInfo &info)
 
virtual void Execute () const override
 
- Public Member Functions inherited from BaseWorkload< ConstantQueueDescriptor >
 BaseWorkload (const ConstantQueueDescriptor &descriptor, const WorkloadInfo &info)
 
void PostAllocationConfigure () override
 
const ConstantQueueDescriptorGetData () 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< ConstantQueueDescriptor >
const ConstantQueueDescriptor m_Data
 
const profiling::ProfilingGuid m_Guid
 
+

Detailed Description

+
+

Definition at line 13 of file NeonConstantWorkload.hpp.

+

Constructor & Destructor Documentation

+ +

◆ NeonConstantWorkload()

+ +
+
+ + + + + + + + + + + + + + + + + + +
NeonConstantWorkload (const ConstantQueueDescriptordescriptor,
const WorkloadInfoinfo 
)
+
+ +

Definition at line 20 of file NeonConstantWorkload.cpp.

+
22  : BaseWorkload<ConstantQueueDescriptor>(descriptor, info)
23  , m_RanOnce(false)
24 {
25 }
+
+
+
+

Member Function Documentation

+ +

◆ Execute()

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

Implements IWorkload.

+ +

Definition at line 27 of file NeonConstantWorkload.cpp.

+ +

References ARMNN_SCOPED_PROFILING_EVENT_NEON, BaseWorkload< ConstantQueueDescriptor >::m_Data, ConstantQueueDescriptor::m_LayerOutput, and QueueDescriptor::m_Outputs.

+
28 {
29  ARMNN_SCOPED_PROFILING_EVENT_NEON("NeonConstantWorkload_Execute");
30 
31  using namespace armcomputetensorutils;
32 
33  // The intermediate tensor held by the corresponding layer output handler can be initialised with the
34  // given data on the first inference, then reused for subsequent inferences.
35  // The initialisation cannot happen at workload construction time since the ACL kernel for the next layer
36  // may not have been configured at the time.
37  if (!m_RanOnce)
38  {
39  const ConstantQueueDescriptor& data = this->m_Data;
40 
41  BOOST_ASSERT(data.m_LayerOutput != nullptr);
42  arm_compute::ITensor& output =
43  boost::polymorphic_downcast<NeonTensorHandle*>(data.m_Outputs[0])->GetTensor();
44  arm_compute::DataType computeDataType =
45  boost::polymorphic_downcast<NeonTensorHandle*>(data.m_Outputs[0])->GetDataType();
46 
47  switch (computeDataType)
48  {
49  case arm_compute::DataType::F16:
50  {
51  CopyArmComputeITensorData(data.m_LayerOutput->GetConstTensor<Half>(), output);
52  break;
53  }
54  case arm_compute::DataType::F32:
55  {
56  CopyArmComputeITensorData(data.m_LayerOutput->GetConstTensor<float>(), output);
57  break;
58  }
59  case arm_compute::DataType::QASYMM8:
60  {
61  CopyArmComputeITensorData(data.m_LayerOutput->GetConstTensor<uint8_t>(), output);
62  break;
63  }
64  default:
65  {
66  BOOST_ASSERT_MSG(false, "Unknown data type");
67  break;
68  }
69  }
70 
71  m_RanOnce = true;
72  }
73 }
const ConstantQueueDescriptor m_Data
Definition: Workload.hpp:46
+
#define ARMNN_SCOPED_PROFILING_EVENT_NEON(name)
+
DataType
Definition: Types.hpp:32
+
half_float::half Half
Definition: Half.hpp:16
+
+
+
+
The documentation for this class was generated from the following files: +
+
+ + + + -- cgit v1.2.1