From 9aed8fb43441228343b925b42464a55042c47ca0 Mon Sep 17 00:00:00 2001 From: Nikhil Raj Date: Wed, 17 Nov 2021 13:16:45 +0000 Subject: IVGCVSW-6040 Update 21.11 Doxygen Documents Signed-off-by: Nikhil Raj Change-Id: Ia36ec98c4bebc27a69103911ea3409cd7db587a5 --- 21.11/_cl_subtraction_workload_8cpp_source.xhtml | 143 +++++++++++++++++++++++ 1 file changed, 143 insertions(+) create mode 100644 21.11/_cl_subtraction_workload_8cpp_source.xhtml (limited to '21.11/_cl_subtraction_workload_8cpp_source.xhtml') diff --git a/21.11/_cl_subtraction_workload_8cpp_source.xhtml b/21.11/_cl_subtraction_workload_8cpp_source.xhtml new file mode 100644 index 0000000000..946f4b3663 --- /dev/null +++ b/21.11/_cl_subtraction_workload_8cpp_source.xhtml @@ -0,0 +1,143 @@ + + + + + + + + + + + + + +ArmNN: src/backends/cl/workloads/ClSubtractionWorkload.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + ArmNN + + + +
+
+  21.11 +
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+ +
+ +
+
+
ClSubtractionWorkload.cpp
+
+
+Go to the documentation of this file.
1 //
2 // Copyright © 2017 Arm Ltd. All rights reserved.
3 // SPDX-License-Identifier: MIT
4 //
5 
7 
8 #include <cl/ClTensorHandle.hpp>
12 
13 #include "ClWorkloadUtils.hpp"
14 
15 namespace armnn
16 {
17 using namespace armcomputetensorutils;
18 
19 static constexpr arm_compute::ConvertPolicy g_AclConvertPolicy = arm_compute::ConvertPolicy::SATURATE;
20 
22  const WorkloadInfo& info,
23  const arm_compute::CLCompileContext& clCompileContext)
24  : BaseWorkload<SubtractionQueueDescriptor>(descriptor, info)
25 {
26  this->m_Data.ValidateInputsOutputs("ClSubtractionWorkload", 2, 1);
27 
28  arm_compute::ICLTensor& input0 = static_cast<IClTensorHandle*>(this->m_Data.m_Inputs[0])->GetTensor();
29  arm_compute::ICLTensor& input1 = static_cast<IClTensorHandle*>(this->m_Data.m_Inputs[1])->GetTensor();
30  arm_compute::ICLTensor& output = static_cast<IClTensorHandle*>(this->m_Data.m_Outputs[0])->GetTensor();
31 
32  const arm_compute::ActivationLayerInfo activationInfo = ConvertAdditionalInfoToAclActivationLayerInfo(descriptor);
33 
34  {
35  ARMNN_SCOPED_PROFILING_EVENT(Compute::Undefined, "ClSubtractionWorkload_configure");
36  m_Layer.configure(clCompileContext, &input0, &input1, &output, g_AclConvertPolicy, activationInfo);
37  }
38 }
39 
41 {
42  ARMNN_SCOPED_PROFILING_EVENT_CL_GUID("ClSubtractionWorkload_Execute", this->GetGuid());
43  RunClFunction(m_Layer, CHECK_LOCATION());
44 }
45 
47  const TensorInfo& input1,
48  const TensorInfo& output,
49  const ActivationDescriptor* activationDescriptor)
50 {
51  const arm_compute::TensorInfo aclInput0Info = BuildArmComputeTensorInfo(input0);
52  const arm_compute::TensorInfo aclInput1Info = BuildArmComputeTensorInfo(input1);
53  const arm_compute::TensorInfo aclOutputInfo = BuildArmComputeTensorInfo(output);
54 
55  const arm_compute::ActivationLayerInfo activationInfo = ConvertActivationDescriptorToAclActivationLayerInfo(
56  activationDescriptor);
57 
58  const arm_compute::Status aclStatus = arm_compute::CLArithmeticSubtraction::validate(&aclInput0Info,
59  &aclInput1Info,
60  &aclOutputInfo,
61  g_AclConvertPolicy,
62  activationInfo);
63 
64  return aclStatus;
65 }
66 
67 } //namespace armnn
#define ARMNN_SCOPED_PROFILING_EVENT_CL_GUID(name, guid)
+ + + + +
void RunClFunction(arm_compute::IFunction &function, const CheckLocation &location)
+
arm_compute::Status ClSubtractionValidate(const TensorInfo &input0, const TensorInfo &input1, const TensorInfo &output, const ActivationDescriptor *activationDescriptor)
+
arm_compute::ActivationLayerInfo ConvertAdditionalInfoToAclActivationLayerInfo(const QueueDescriptor &queueDescriptor)
+ +
void ValidateInputsOutputs(const std::string &descName, unsigned int numExpectedIn, unsigned int numExpectedOut) const
+
Copyright (c) 2021 ARM Limited and Contributors.
+ +
#define ARMNN_SCOPED_PROFILING_EVENT(backendId, name)
Definition: Profiling.hpp:220
+ + + + +
Status
enumeration
Definition: Types.hpp:29
+
An ActivationDescriptor for the ActivationLayer.
Definition: Descriptors.hpp:25
+
#define CHECK_LOCATION()
Definition: Exceptions.hpp:209
+
profiling::ProfilingGuid GetGuid() const final
Definition: Workload.hpp:55
+ +
std::vector< ITensorHandle * > m_Outputs
+ + +
Contains information about TensorInfos of a layer.
+
std::vector< ITensorHandle * > m_Inputs
+ +
arm_compute::ActivationLayerInfo ConvertActivationDescriptorToAclActivationLayerInfo(const ActivationDescriptor &actDesc)
+
ClSubtractionWorkload(const SubtractionQueueDescriptor &descriptor, const WorkloadInfo &info, const arm_compute::CLCompileContext &clCompileContext)
+
+
+ + + + -- cgit v1.2.1