From bef7fa27b0d231a8649952f60808132d109b6345 Mon Sep 17 00:00:00 2001 From: Sang-Hoon Park Date: Wed, 21 Oct 2020 15:58:54 +0100 Subject: COMPMID-3639: (3RDPARTY_UPDATE) Move CL kernels to src Change-Id: I10d27db788e5086adae1841e3e2441cd9b76ef84 Signed-off-by: Sang-Hoon Park Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/4310 Reviewed-by: Georgios Pinitas Comments-Addressed: Arm Jenkins Tested-by: Arm Jenkins --- src/runtime/CL/functions/CLBatchNormalizationLayer.cpp | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'src/runtime/CL/functions/CLBatchNormalizationLayer.cpp') diff --git a/src/runtime/CL/functions/CLBatchNormalizationLayer.cpp b/src/runtime/CL/functions/CLBatchNormalizationLayer.cpp index 701add074e..77eed1140f 100644 --- a/src/runtime/CL/functions/CLBatchNormalizationLayer.cpp +++ b/src/runtime/CL/functions/CLBatchNormalizationLayer.cpp @@ -29,14 +29,19 @@ #include "arm_compute/core/Types.h" #include "arm_compute/core/Validate.h" #include "arm_compute/runtime/CL/CLScheduler.h" +#include "support/MemorySupport.h" -using namespace arm_compute; +#include "src/core/CL/kernels/CLBatchNormalizationLayerKernel.h" +namespace arm_compute +{ CLBatchNormalizationLayer::CLBatchNormalizationLayer() - : _norm_kernel() + : _norm_kernel(support::cpp14::make_unique()) { } +CLBatchNormalizationLayer::~CLBatchNormalizationLayer() = default; + void CLBatchNormalizationLayer::configure(ICLTensor *input, ICLTensor *output, const ICLTensor *mean, const ICLTensor *var, const ICLTensor *beta, const ICLTensor *gamma, float epsilon, ActivationLayerInfo act_info) { @@ -47,7 +52,7 @@ void CLBatchNormalizationLayer::configure(const CLCompileContext &compile_contex const ICLTensor *gamma, float epsilon, ActivationLayerInfo act_info) { - _norm_kernel.configure(compile_context, input, output, mean, var, beta, gamma, epsilon, act_info); + _norm_kernel->configure(compile_context, input, output, mean, var, beta, gamma, epsilon, act_info); } Status CLBatchNormalizationLayer::validate(const ITensorInfo *input, const ITensorInfo *output, @@ -60,5 +65,6 @@ Status CLBatchNormalizationLayer::validate(const ITensorInfo *input, const ITens void CLBatchNormalizationLayer::run() { - CLScheduler::get().enqueue(_norm_kernel, true); + CLScheduler::get().enqueue(*_norm_kernel, true); } +} // namespace arm_compute \ No newline at end of file -- cgit v1.2.1