17 for (
unsigned int i = 0; i < numElements; ++i)
19 switch (OutputDataType)
27 out.
Set(std::floor(in.
Get()));
40 for (
unsigned int i = 0; i < numElements; ++i)
52 for (
unsigned int i = 0; i < numElements; ++i)
54 out.
Set(
static_cast<float>(in.
Get()));
78 if (inputTensorInfo.IsQuantized())
80 inputTensorInfo.SetQuantizationScale(1.0f);
81 inputTensorInfo.SetQuantizationOffset(0);
83 if (outputTensorInfo.IsQuantized())
85 outputTensorInfo.SetQuantizationScale(1.0f);
86 outputTensorInfo.SetQuantizationOffset(0);
91 Cast(*MakeDecoder<double_t>(inputTensorInfo, inputs[0]->
Map()),
92 *MakeEncoder<float>(outputTensorInfo, outputs[0]->
Map()),
93 inputTensorInfo.GetNumElements(),
94 outputTensorInfo.GetDataType());
98 Cast(*MakeDecoder<float>(inputTensorInfo, inputs[0]->
Map()),
99 *MakeEncoder<double_t>(outputTensorInfo, outputs[0]->
Map()),
100 inputTensorInfo.GetNumElements(),
101 outputTensorInfo.GetDataType());
105 Cast(*MakeDecoder<float>(inputTensorInfo, inputs[0]->
Map()),
106 *MakeEncoder<float>(outputTensorInfo, outputs[0]->
Map()),
107 inputTensorInfo.GetNumElements(),
108 outputTensorInfo.GetDataType());
#define ARMNN_SCOPED_PROFILING_EVENT_REF_NAME_GUID(label)
Creates a profiling event that uses GetGuid() and GetName() from the calling class.
virtual IType Get() const =0
virtual void Set(IType right)=0
void Execute() const override
Copyright (c) 2021 ARM Limited and Contributors.
const TensorInfo & GetTensorInfo(const ITensorHandle *tensorHandle)
float32 helpers
std::vector< ITensorHandle * > m_Inputs
std::vector< ITensorHandle * > m_Outputs