16 #include <boost/numeric/conversion/cast.hpp> 24 using namespace armcomputetensorutils;
30 const arm_compute::TensorInfo aclInputInfo = BuildArmComputeTensorInfo(input, descriptor.
m_DataLayout);
31 const arm_compute::TensorInfo aclOutputInfo = BuildArmComputeTensorInfo(output, descriptor.
m_DataLayout);
44 return arm_compute::CLStridedSlice::validate(&aclInputInfo,
77 input.info()->set_data_layout(aclDataLayout);
78 output.info()->set_data_layout(aclDataLayout);
80 m_StridedSliceLayer.configure(&input,
int32_t m_ShrinkAxisMask
Shrink axis mask value. If set, the nth specification shrinks the dimensionality by 1...
std::vector< int > m_Begin
Begin values for the input that will be sliced.
DataLayout m_DataLayout
The data layout to be used (NCHW, NHWC).
#define ARMNN_SCOPED_PROFILING_EVENT_CL(name)
void RunClFunction(arm_compute::IFunction &function, const CheckLocation &location)
std::array< unsigned int, MaxNumOfTensorDimensions > Coordinates
const StridedSliceQueueDescriptor m_Data
void ValidateInputsOutputs(const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const
Copyright (c) 2020 ARM Limited.
int32_t m_BeginMask
Begin mask value.
int32_t m_EndMask
End mask value.
LayerDescriptor m_Parameters
std::vector< TensorInfo > m_InputTensorInfos
arm_compute::Status ClStridedSliceWorkloadValidate(const TensorInfo &input, const TensorInfo &output, const StridedSliceDescriptor &descriptor)
std::enable_if_t< std::is_unsigned< Source >::value &&std::is_unsigned< Dest >::value, Dest > numeric_cast(Source source)
std::vector< int > m_Stride
Stride values for the input that will be sliced.
ClStridedSliceWorkload(const StridedSliceQueueDescriptor &descriptor, const WorkloadInfo &info)
std::vector< int > m_End
End values for the input that will be sliced.
int32_t ConvertMaskToACLFormat(int32_t mask, int32_t numDim)
std::vector< ITensorHandle * > m_Outputs
A StridedSliceDescriptor for the StridedSliceLayer.
Contains information about inputs and outputs to a layer.
void Execute() const override
std::vector< ITensorHandle * > m_Inputs
auto SetClStridedSliceData(const std::vector< int > &m_begin, const std::vector< int > &m_end, const std::vector< int > &m_stride)
unsigned int GetNumDimensions() const