24.08
|
Go to the documentation of this file.
23 const arm_compute::TensorInfo aclInput = armcomputetensorutils::BuildArmComputeTensorInfo(input,
25 const arm_compute::TensorInfo aclOutput = armcomputetensorutils::BuildArmComputeTensorInfo(output,
41 return arm_compute::NEStridedSlice::validate(&aclInput,
63 arm_compute::ITensor& input = PolymorphicDowncast<IAclTensorHandle*>(
m_Data.
m_Inputs[0])->GetTensor();
64 arm_compute::ITensor& output = PolymorphicDowncast<IAclTensorHandle*>(
m_Data.
m_Outputs[0])->GetTensor();
74 auto numDimensions = armnn::numeric_cast<int>(
info.m_InputTensorInfos[0].GetNumDimensions());
80 input.info()->set_data_layout(aclDataLayout);
81 output.info()->set_data_layout(aclDataLayout);
83 auto layer = std::make_unique<arm_compute::NEStridedSlice>();
85 layer->configure(&input,
93 m_Layer.reset(layer.release());
std::vector< int > m_Begin
Begin values for the input that will be sliced.
void ValidateInputsOutputs(const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const
auto SetNeonStridedSliceData(const std::vector< int > &m_begin, const std::vector< int > &m_end, const std::vector< int > &m_stride)
unsigned int GetNumDimensions() const
int32_t m_BeginMask
Begin mask value.
std::array< unsigned int, MaxNumOfTensorDimensions > Coordinates
DataLayout m_DataLayout
The data layout to be used (NCHW, NHWC).
LayerDescriptor m_Parameters
Contains information about TensorInfos of a layer.
virtual void Execute() const override
NeonStridedSliceWorkload(const StridedSliceQueueDescriptor &descriptor, const WorkloadInfo &info)
int32_t m_EndMask
End mask value.
std::vector< ITensorHandle * > m_Outputs
int32_t m_ShrinkAxisMask
Shrink axis mask value. If set, the nth specification shrinks the dimensionality by 1.
#define ARMNN_REPORT_PROFILING_WORKLOAD_DESC(name, desc, infos, guid)
std::vector< int > m_Stride
Stride values for the input that will be sliced.
A StridedSliceDescriptor for the StridedSliceLayer.
StridedSliceQueueDescriptor m_Data
int32_t ConvertMaskToACLFormat(int32_t mask, int32_t numDim)
arm_compute::Status NeonStridedSliceWorkloadValidate(const TensorInfo &input, const TensorInfo &output, const StridedSliceDescriptor &descriptor)
Copyright (c) 2021 ARM Limited and Contributors.
std::vector< int > m_End
End values for the input that will be sliced.
#define ARMNN_SCOPED_PROFILING_EVENT_NEON_NAME_GUID(label)
Creates a profiling event that uses GetGuid() and GetName() from the calling class.
std::vector< ITensorHandle * > m_Inputs