ArmNN
 21.08
RefDepthToSpaceWorkload.cpp
Go to the documentation of this file.
1 //
2 // Copyright © 2019 Arm Ltd. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
7 
8 #include "DepthToSpace.hpp"
9 #include "RefWorkloadUtils.hpp"
10 
11 namespace armnn
12 {
13 
15 {
17 }
18 
20 {
21  Execute(workingMemDescriptor.m_Inputs, workingMemDescriptor.m_Outputs);
22 }
23 
24 void RefDepthToSpaceWorkload::Execute(std::vector<ITensorHandle*> inputs, std::vector<ITensorHandle*> outputs) const
25 {
26  ARMNN_SCOPED_PROFILING_EVENT(Compute::CpuRef, "RefDepthToSpaceWorkload_Execute");
27 
28  const TensorInfo inputInfo = GetTensorInfo(inputs[0]);
29 
30  DepthToSpace(inputInfo,
32  inputs[0]->Map(),
33  outputs[0]->Map(),
34  GetDataTypeSize(inputInfo.GetDataType()));
35 }
36 
37 } // namespace armnn
CPU Execution: Reference C++ kernels.
Copyright (c) 2021 ARM Limited and Contributors.
void ExecuteAsync(WorkingMemDescriptor &workingMemDescriptor) override
#define ARMNN_SCOPED_PROFILING_EVENT(backendId, name)
Definition: Profiling.hpp:219
DataType GetDataType() const
Definition: Tensor.hpp:198
std::vector< ITensorHandle * > m_Outputs
std::vector< ITensorHandle * > m_Inputs
const TensorInfo & GetTensorInfo(const ITensorHandle *tensorHandle)
float32 helpers
constexpr unsigned int GetDataTypeSize(DataType dataType)
Definition: TypesUtils.hpp:139