From cb0630959aeae05bc2ae9f6d80cf5f5983a8fb77 Mon Sep 17 00:00:00 2001 From: Nikhil Raj Date: Wed, 23 Nov 2022 11:05:29 +0000 Subject: IVGCVSW-7075 Update Doxygen for 22.11 Release Signed-off-by: Nikhil Raj Change-Id: Ib5669e8fd3739d1b10f5dd694d020d51799896dc --- 22.11/_neon_concat_workload_8cpp_source.xhtml | 140 ++++++++++++++++++++++++++ 1 file changed, 140 insertions(+) create mode 100644 22.11/_neon_concat_workload_8cpp_source.xhtml (limited to '22.11/_neon_concat_workload_8cpp_source.xhtml') diff --git a/22.11/_neon_concat_workload_8cpp_source.xhtml b/22.11/_neon_concat_workload_8cpp_source.xhtml new file mode 100644 index 0000000000..498da5c4ac --- /dev/null +++ b/22.11/_neon_concat_workload_8cpp_source.xhtml @@ -0,0 +1,140 @@ + + + + + + + + + + + + + +ArmNN: src/backends/neon/workloads/NeonConcatWorkload.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  22.11 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+
+
NeonConcatWorkload.cpp
+
+
+Go to the documentation of this file.
1 //
2 // Copyright © 2017 Arm Ltd and Contributors. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
6 #include "NeonConcatWorkload.hpp"
7 
8 #include "NeonWorkloadUtils.hpp"
9 
14 
15 namespace armnn
16 {
17 using namespace armcomputetensorutils;
18 
19 namespace
20 {
21 size_t CalcAxis(const armnn::OriginsDescriptor& descriptor)
22 {
23  return (descriptor.GetNumDimensions() - descriptor.GetConcatAxis()) - 1;
24 }
25 } //namespace
26 
27 arm_compute::Status NeonConcatWorkloadValidate(const std::vector<const TensorInfo*>& inputs,
28  const TensorInfo& output,
29  const OriginsDescriptor& descriptor)
30 
31 {
32  std::vector<arm_compute::TensorInfo> aclInputs;
33  for (const TensorInfo* input : inputs)
34  {
35  arm_compute::TensorInfo aclInputInfo = BuildArmComputeTensorInfo(*input, armnn::DataLayout::NCHW);
36  aclInputs.emplace_back(aclInputInfo);
37  }
38  const arm_compute::TensorInfo aclOutputInfo = BuildArmComputeTensorInfo(output);
39  std::vector<const arm_compute::ITensorInfo*> aclInputPtrs;
40  for (arm_compute::ITensorInfo& input : aclInputs)
41  {
42  aclInputPtrs.emplace_back(&input);
43  }
44 
45  size_t aclAxis = CalcAxis(descriptor);
46  return arm_compute::NEConcatenateLayer::validate(aclInputPtrs, &aclOutputInfo, aclAxis);
47 }
48 
50 const ConcatQueueDescriptor& descriptor, const WorkloadInfo& info)
51  : NeonBaseWorkload<ConcatQueueDescriptor>(descriptor, info)
52 {
53  // Report Profiling Details
54  ARMNN_REPORT_PROFILING_WORKLOAD_DESC("NeonConcatWorkload_Construct",
55  descriptor.m_Parameters,
56  info,
57  this->GetGuid());
58 
59  bool allInputsAreSubtensors = true;
60 
61  // Check that all inputs are sub-tensors
62  for (auto input : descriptor.m_Inputs)
63  {
64  if (!input->GetParent())
65  {
66  // Non sub-tensor input found so we need to execute the concat function
67  allInputsAreSubtensors = false;
68  break;
69  }
70  }
71 
72  if (allInputsAreSubtensors)
73  {
74  // Can skip configuring the concat function since it's not executed
75  return;
76  }
77 
78  std::vector<const arm_compute::ITensor *> aclInputs;
79  for (auto input : m_Data.m_Inputs)
80  {
81  arm_compute::ITensor& aclInput = armnn::PolymorphicPointerDowncast<IAclTensorHandle>(input)->GetTensor();
82  aclInputs.emplace_back(&aclInput);
83  }
84  arm_compute::ITensor& output = armnn::PolymorphicPointerDowncast<IAclTensorHandle>(
85  m_Data.m_Outputs[0])->GetTensor();
86 
87  // Create the layer function
88  m_Layer.reset(new arm_compute::NEConcatenateLayer());
89 
90  // Configure input and output tensors
91  size_t aclAxis = CalcAxis(descriptor.m_Parameters);
92  m_Layer->configure(aclInputs, &output, aclAxis);
93 
94  // Prepare
95  m_Layer->prepare();
96 }
97 
99 {
100  if (m_Layer)
101  {
102  ARMNN_SCOPED_PROFILING_EVENT_NEON_GUID("NeonConcatWorkload_Execute", this->GetGuid());
103  m_Layer->run();
104  }
105 }
106 
107 } //namespace armnn
108 
+ + +
NeonConcatWorkload(const ConcatQueueDescriptor &descriptor, const WorkloadInfo &info)
+ +
arm::pipe::ProfilingGuid GetGuid() const final
Definition: Workload.hpp:61
+ +
Copyright (c) 2021 ARM Limited and Contributors.
+ + + + + +
An OriginsDescriptor for the ConcatLayer.
+
void Execute() const override
+
Status
enumeration
Definition: Types.hpp:42
+
arm_compute::Status NeonConcatWorkloadValidate(const std::vector< const TensorInfo *> &inputs, const TensorInfo &output, const OriginsDescriptor &descriptor)
+ +
std::vector< ITensorHandle * > m_Outputs
+ +
uint32_t GetNumDimensions() const
Get the number of dimensions.
+
#define ARMNN_REPORT_PROFILING_WORKLOAD_DESC(name, desc, infos, guid)
Definition: Profiling.hpp:227
+
Contains information about TensorInfos of a layer.
+
std::vector< ITensorHandle * > m_Inputs
+ +
unsigned int GetConcatAxis() const
Get the concatenation axis value.
+
#define ARMNN_SCOPED_PROFILING_EVENT_NEON_GUID(name, guid)
+
+
+ + + + -- cgit v1.2.1