ArmNN
 25.11
Loading...
Searching...
No Matches
RefStridedSliceWorkload.cpp
Go to the documentation of this file.
1//
2// Copyright © 2018-2024 Arm Ltd and Contributors. All rights reserved.
3// SPDX-License-Identifier: MIT
4//
5
8#include "StridedSlice.hpp"
9
10namespace armnn
11{
12
17
19{
20 Execute(m_Data.m_Inputs, m_Data.m_Outputs);
21}
22
23void RefStridedSliceWorkload::Execute(std::vector<ITensorHandle*> inputs, std::vector<ITensorHandle*> outputs) const
24{
25 ARMNN_SCOPED_PROFILING_EVENT_REF_NAME_GUID("RefStridedSliceWorkload_Execute");
26
27 const TensorInfo& inputInfo = GetTensorInfo(inputs[0]);
28
29 DataType inputDataType = inputInfo.GetDataType();
30
31 StridedSlice(inputInfo,
33 inputs[0]->Map(),
34 outputs[0]->Map(),
35 GetDataTypeSize(inputDataType));
36}
37
38} // namespace armnn
#define ARMNN_SCOPED_PROFILING_EVENT_REF_NAME_GUID(label)
Creates a profiling event that uses GetGuid() and GetName() from the calling class.
RefBaseWorkload(const StridedSliceQueueDescriptor &descriptor, const WorkloadInfo &info)
RefStridedSliceWorkload(const StridedSliceQueueDescriptor &descriptor, const WorkloadInfo &info)
DataType GetDataType() const
Definition Tensor.hpp:200
Copyright (c) 2021 ARM Limited and Contributors.
constexpr unsigned int GetDataTypeSize(DataType dataType)
DataType
Definition Types.hpp:49
armnn::TensorInfo GetTensorInfo(unsigned int numberOfBatches, unsigned int numberOfChannels, unsigned int height, unsigned int width, const armnn::DataLayout dataLayout, const armnn::DataType dataType)
Contains information about TensorInfos of a layer.