blob: bc3b1654904ebddda7e8065e0b92e19d8abfe6b3 [file] [log] [blame]
//
// Copyright © 2017 Arm Ltd. All rights reserved.
// SPDX-License-Identifier: MIT
//
#include "ClDepthwiseConvolutionFloatWorkload.hpp"
#include "backends/CpuTensorHandle.hpp"
#include "ClWorkloadUtils.hpp"
namespace armnn
{
ClDepthwiseConvolutionFloatWorkload::ClDepthwiseConvolutionFloatWorkload(
const DepthwiseConvolution2dQueueDescriptor& descriptor,
const WorkloadInfo& info)
: ClDepthwiseConvolutionBaseWorkload(descriptor, info)
{
InitializeArmComputeClTensorData(*m_KernelTensor, m_Data.m_Weight);
if (m_BiasTensor)
{
InitializeArmComputeClTensorData(*m_BiasTensor, m_Data.m_Bias);
}
m_DepthwiseConvolutionLayer->prepare();
FreeUnusedTensors();
}
void ClDepthwiseConvolutionFloatWorkload::Execute() const
{
ARMNN_SCOPED_PROFILING_EVENT_CL("ClDepthwiseConvolutionFloatWorkload_Execute");
BOOST_ASSERT(m_DepthwiseConvolutionLayer);
m_DepthwiseConvolutionLayer->run();
}
} //namespace armnn