ArmNN
 24.08
TransposeConvolution2dQueueDescriptor Struct Reference

#include <WorkloadData.hpp>

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

Public Member Functions

 TransposeConvolution2dQueueDescriptor ()
 
void Validate (const WorkloadInfo &workloadInfo) const
 
- Public Member Functions inherited from QueueDescriptorWithParameters< TransposeConvolution2dDescriptor >
virtual ~QueueDescriptorWithParameters ()=default
 
- Public Member Functions inherited from QueueDescriptor
virtual ~QueueDescriptor ()=default
 
void ValidateTensorNumDimensions (const TensorInfo &tensor, std::string const &descName, unsigned int numDimensions, std::string const &tensorName) const
 
void ValidateTensorNumDimNumElem (const TensorInfo &tensorInfo, unsigned int numDimension, unsigned int numElements, std::string const &tensorName) const
 
void ValidateInputsOutputs (const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const
 
template<typename T >
const T * GetAdditionalInformation () const
 

Public Attributes

const ConstTensorHandlem_Weight
 
const ConstTensorHandlem_Bias
 
- Public Attributes inherited from QueueDescriptorWithParameters< TransposeConvolution2dDescriptor >
TransposeConvolution2dDescriptor m_Parameters
 
- Public Attributes inherited from QueueDescriptor
std::vector< ITensorHandle * > m_Inputs
 
std::vector< ITensorHandle * > m_Outputs
 
void * m_AdditionalInfoObject
 
bool m_AllowExpandedDims = false
 

Additional Inherited Members

- Protected Member Functions inherited from QueueDescriptorWithParameters< TransposeConvolution2dDescriptor >
 QueueDescriptorWithParameters ()=default
 
 QueueDescriptorWithParameters (QueueDescriptorWithParameters const &)=default
 
QueueDescriptorWithParametersoperator= (QueueDescriptorWithParameters const &)=default
 
- Protected Member Functions inherited from QueueDescriptor
 QueueDescriptor ()
 
 QueueDescriptor (QueueDescriptor const &)=default
 
QueueDescriptoroperator= (QueueDescriptor const &)=default
 

Detailed Description

Definition at line 544 of file WorkloadData.hpp.

Constructor & Destructor Documentation

◆ TransposeConvolution2dQueueDescriptor()

Definition at line 546 of file WorkloadData.hpp.

546  :
547  m_Weight(nullptr),
548  m_Bias(nullptr)
549  {}

Member Function Documentation

◆ Validate()

void Validate ( const WorkloadInfo workloadInfo) const

Definition at line 3056 of file WorkloadData.cpp.

3057 {
3058  const std::string descriptorName{"TransposeConvolution2dQueueDescriptor"};
3059 
3060  ValidateNumInputs(workloadInfo, descriptorName, 1);
3061  ValidateNumOutputs(workloadInfo, descriptorName, 1);
3062 
3063  const TensorInfo& inputTensorInfo = workloadInfo.m_InputTensorInfos[0];
3064  const TensorInfo& outputTensorInfo = workloadInfo.m_OutputTensorInfos[0];
3065 
3066  ValidateTensorNumDimensions(inputTensorInfo, descriptorName, 4, "input");
3067  ValidateTensorNumDimensions(outputTensorInfo, descriptorName, 4, "output");
3068 
3069  ValidatePointer(m_Weight, descriptorName, "weight");
3070 
3071  const TensorInfo& weightTensorInfo = m_Weight->GetTensorInfo();
3072  ValidateTensorNumDimensions(weightTensorInfo, descriptorName, 4, "weight");
3073 
3074  ValidateWeightDataType(inputTensorInfo, weightTensorInfo, descriptorName);
3075 
3076  Optional<TensorInfo> optionalBiasTensorInfo;
3078  {
3079  ValidatePointer(m_Bias, descriptorName, "bias");
3080 
3081  optionalBiasTensorInfo = MakeOptional<TensorInfo>(m_Bias->GetTensorInfo());
3082  const TensorInfo& biasTensorInfo = optionalBiasTensorInfo.value();
3083 
3084  ValidateTensorDataType(biasTensorInfo, GetBiasDataType(inputTensorInfo.GetDataType()), descriptorName, "bias");
3085  ValidateBiasTensorQuantization(biasTensorInfo, weightTensorInfo, descriptorName);
3086  }
3087 
3088  ValidatePerAxisQuantization(inputTensorInfo,
3089  outputTensorInfo,
3090  weightTensorInfo,
3091  optionalBiasTensorInfo,
3092  descriptorName);
3093 
3094  std::vector<DataType> supportedTypes =
3095  {
3102  };
3103 
3104  ValidateDataTypes(inputTensorInfo, supportedTypes, descriptorName);
3105  ValidateTensorDataTypesMatch(inputTensorInfo, outputTensorInfo, descriptorName, "input", "output");
3106 }

References armnn::BFloat16, armnn::Float16, armnn::Float32, armnn::GetBiasDataType(), TensorInfo::GetDataType(), ConstTensorHandle::GetTensorInfo(), TransposeConvolution2dQueueDescriptor::m_Bias, TransposeConvolution2dDescriptor::m_BiasEnabled, WorkloadInfo::m_InputTensorInfos, WorkloadInfo::m_OutputTensorInfos, QueueDescriptorWithParameters< TransposeConvolution2dDescriptor >::m_Parameters, TransposeConvolution2dQueueDescriptor::m_Weight, armnn::QAsymmS8, armnn::QAsymmU8, armnn::QSymmS16, QueueDescriptor::ValidateTensorNumDimensions(), and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().

Member Data Documentation

◆ m_Bias

◆ m_Weight


The documentation for this struct was generated from the following files:
armnn::Optional
Definition: Optional.hpp:270
armnn::TensorInfo
Definition: Tensor.hpp:152
armnn::TransposeConvolution2dQueueDescriptor::m_Weight
const ConstTensorHandle * m_Weight
Definition: WorkloadData.hpp:551
armnn::DataType::Float32
@ Float32
armnn::DataType::QAsymmU8
@ QAsymmU8
armnn::ConstTensorHandle::GetTensorInfo
const TensorInfo & GetTensorInfo() const
Definition: TensorHandle.hpp:40
armnn::DataType::QSymmS16
@ QSymmS16
armnn::DataType::BFloat16
@ BFloat16
armnn::DataType::Float16
@ Float16
armnn::WorkloadInfo::m_OutputTensorInfos
std::vector< TensorInfo > m_OutputTensorInfos
Definition: WorkloadInfo.hpp:19
armnn::QueueDescriptorWithParameters< TransposeConvolution2dDescriptor >::m_Parameters
TransposeConvolution2dDescriptor m_Parameters
Definition: WorkloadData.hpp:66
armnn::TransposeConvolution2dQueueDescriptor::m_Bias
const ConstTensorHandle * m_Bias
Definition: WorkloadData.hpp:552
armnn::TensorInfo::GetDataType
DataType GetDataType() const
Definition: Tensor.hpp:200
armnn::DataType::QAsymmS8
@ QAsymmS8
armnn::GetBiasDataType
DataType GetBiasDataType(DataType inputDataType)
Definition: WorkloadData.cpp:28
armnn::WorkloadInfo::m_InputTensorInfos
std::vector< TensorInfo > m_InputTensorInfos
Definition: WorkloadInfo.hpp:18
armnn::QueueDescriptor::ValidateTensorNumDimensions
void ValidateTensorNumDimensions(const TensorInfo &tensor, std::string const &descName, unsigned int numDimensions, std::string const &tensorName) const
Definition: WorkloadData.cpp:398
armnn::TransposeConvolution2dDescriptor::m_BiasEnabled
bool m_BiasEnabled
Enable/disable bias.
Definition: Descriptors.hpp:1481
armnn::OptionalReferenceSwitch< std::is_reference< T >::value, T >::value
const T & value() const
Definition: Optional.hpp:146