diff options
author | Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> | 2019-11-14 16:21:38 +0000 |
---|---|---|
committer | Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> | 2019-11-14 16:41:45 +0000 |
commit | f4c502f54cc978c1b34f3beaf6b9cc0cd1ecc7e8 (patch) | |
tree | 83b603bd477d0a67bce81a5e8722952376ff62e9 /src/backends/cl/workloads | |
parent | 931389591fcf4f48745bec67bd7e59bb0319a403 (diff) | |
download | armnn-f4c502f54cc978c1b34f3beaf6b9cc0cd1ecc7e8.tar.gz |
Fix redundancy in call to configure() in ACL DepthwiseConvolution workloads
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com>
Change-Id: I8f698c6ec9826ce1188bc43bd59fbf7b83455c1a
Diffstat (limited to 'src/backends/cl/workloads')
-rw-r--r-- | src/backends/cl/workloads/ClDepthwiseConvolutionWorkload.cpp | 39 |
1 files changed, 10 insertions, 29 deletions
diff --git a/src/backends/cl/workloads/ClDepthwiseConvolutionWorkload.cpp b/src/backends/cl/workloads/ClDepthwiseConvolutionWorkload.cpp index eb837d74b9..858eab4e00 100644 --- a/src/backends/cl/workloads/ClDepthwiseConvolutionWorkload.cpp +++ b/src/backends/cl/workloads/ClDepthwiseConvolutionWorkload.cpp @@ -114,35 +114,16 @@ ClDepthwiseConvolutionWorkload::ClDepthwiseConvolutionWorkload( arm_compute::PadStrideInfo padStrideInfo = BuildArmComputePadStrideInfo(m_Data.m_Parameters); - // Check for optimisation opportunities. - bool use3x3Optimisation = (weightInfo.GetShape()[2] == 3) && (weightInfo.GetShape()[3] == 3); - if (use3x3Optimisation) - { - m_DepthwiseConvolutionLayer = std::make_unique<arm_compute::CLDepthwiseConvolutionLayer>(); - static_cast<arm_compute::CLDepthwiseConvolutionLayer*>(m_DepthwiseConvolutionLayer.get())->configure( - &input, - m_KernelTensor.get(), - m_BiasTensor.get(), - &output, - padStrideInfo, - depthMultiplier, - arm_compute::ActivationLayerInfo(), - aclDilationInfo); - } - else - { - m_DepthwiseConvolutionLayer = std::make_unique<arm_compute::CLDepthwiseConvolutionLayer>(); - static_cast<arm_compute::CLDepthwiseConvolutionLayer*>(m_DepthwiseConvolutionLayer.get())->configure( - &input, - m_KernelTensor.get(), - m_BiasTensor.get(), - &output, - padStrideInfo, - depthMultiplier, - arm_compute::ActivationLayerInfo(), - aclDilationInfo); - - } + m_DepthwiseConvolutionLayer = std::make_unique<arm_compute::CLDepthwiseConvolutionLayer>(); + static_cast<arm_compute::CLDepthwiseConvolutionLayer*>(m_DepthwiseConvolutionLayer.get())->configure( + &input, + m_KernelTensor.get(), + m_BiasTensor.get(), + &output, + padStrideInfo, + depthMultiplier, + arm_compute::ActivationLayerInfo(), + aclDilationInfo); BOOST_ASSERT(m_DepthwiseConvolutionLayer); |