ArmNN
 24.08
ClDequantizeWorkload Class Reference

#include <ClDequantizeWorkload.hpp>

Inheritance diagram for ClDequantizeWorkload:
[legend]
Collaboration diagram for ClDequantizeWorkload:
[legend]

Public Member Functions

 ClDequantizeWorkload (const DequantizeQueueDescriptor &descriptor, const WorkloadInfo &workloadInfo, const arm_compute::CLCompileContext &clCompileContext)
 
void Execute () const override
 
- Public Member Functions inherited from ClBaseWorkload< DequantizeQueueDescriptor >
 ClBaseWorkload (const DequantizeQueueDescriptor &descriptor, const WorkloadInfo &info)
 
void ReplaceInputTensorHandle (ITensorHandle *tensorHandle, unsigned int slot) override
 
void ReplaceOutputTensorHandle (ITensorHandle *tensorHandle, unsigned int slot) override
 
- Public Member Functions inherited from BaseWorkload< DequantizeQueueDescriptor >
 BaseWorkload (const DequantizeQueueDescriptor &descriptor, const WorkloadInfo &info)
 
virtual const std::string & GetName () const override
 
void ExecuteAsync (ExecutionData &executionData) override
 
void PostAllocationConfigure () override
 
const DequantizeQueueDescriptorGetData () const
 
arm::pipe::ProfilingGuid GetGuid () const final
 
virtual bool SupportsTensorHandleReplacement () const override
 
- Public Member Functions inherited from IWorkload
virtual ~IWorkload ()
 
virtual arm::pipe::ProfilingGuid GetGuid () const =0
 
virtual bool SupportsTensorHandleReplacement () const =0
 
virtual const std::string & GetName () const =0
 
virtual void RegisterDebugCallback (const DebugCallbackFunction &)
 
virtual armnn::Optional< armnn::MemoryRequirementsGetMemoryRequirements ()
 

Additional Inherited Members

- Protected Member Functions inherited from ClBaseWorkload< DequantizeQueueDescriptor >
virtual void Reconfigure ()
 
- Protected Attributes inherited from BaseWorkload< DequantizeQueueDescriptor >
DequantizeQueueDescriptor m_Data
 
const arm::pipe::ProfilingGuid m_Guid
 
const std::string m_Name
 

Detailed Description

Definition at line 17 of file ClDequantizeWorkload.hpp.

Constructor & Destructor Documentation

◆ ClDequantizeWorkload()

ClDequantizeWorkload ( const DequantizeQueueDescriptor descriptor,
const WorkloadInfo workloadInfo,
const arm_compute::CLCompileContext &  clCompileContext 
)

Definition at line 30 of file ClDequantizeWorkload.cpp.

33  : ClBaseWorkload<DequantizeQueueDescriptor>(descriptor, workloadInfo)
34 {
35  m_Data.ValidateInputsOutputs("ClDequantizeWorkload", 1, 1);
36 
37  arm_compute::ICLTensor& input = armnn::PolymorphicPointerDowncast<IClTensorHandle>(
38  m_Data.m_Inputs[0])->GetTensor();
39 
40  arm_compute::ICLTensor& output = armnn::PolymorphicPointerDowncast<IClTensorHandle>(
41  m_Data.m_Outputs[0])->GetTensor();
42 
43  m_Layer.reset(new arm_compute::CLDequantizationLayer());
44  {
45  ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID("ClDequantizeWorkload_configure");
46  m_Layer->configure(clCompileContext, &input, &output);
47  }
48  m_Layer->prepare();
49 }

References ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID, BaseWorkload< DequantizeQueueDescriptor >::m_Data, QueueDescriptor::m_Inputs, QueueDescriptor::m_Outputs, and QueueDescriptor::ValidateInputsOutputs().

Member Function Documentation

◆ Execute()

void Execute ( ) const
overridevirtual

Implements IWorkload.

Definition at line 51 of file ClDequantizeWorkload.cpp.

52 {
53  if (m_Layer)
54  {
55  ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID("ClDequantizeWorkload_Execute");
56  m_Layer->run();
57  }
58 }

References ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID.


The documentation for this class was generated from the following files:
armnn::QueueDescriptor::ValidateInputsOutputs
void ValidateInputsOutputs(const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const
Definition: WorkloadData.cpp:447
m_Layer
IConnectableLayer * m_Layer
Definition: SubgraphViewSelector.cpp:257
ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID
#define ARMNN_SCOPED_PROFILING_EVENT_CL_NAME_GUID(label)
Creates a profiling event that uses GetGuid() and GetName() from the calling class.
Definition: ClWorkloadUtils.hpp:36
armnn::QueueDescriptor::m_Outputs
std::vector< ITensorHandle * > m_Outputs
Definition: WorkloadData.hpp:27
armnn::BaseWorkload< DequantizeQueueDescriptor >::m_Data
DequantizeQueueDescriptor m_Data
Definition: Workload.hpp:89
armnn::QueueDescriptor::m_Inputs
std::vector< ITensorHandle * > m_Inputs
Definition: WorkloadData.hpp:26