diff options
Diffstat (limited to 'src/backends/gpuFsa/GpuFsaBackend.cpp')
-rw-r--r-- | src/backends/gpuFsa/GpuFsaBackend.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/backends/gpuFsa/GpuFsaBackend.cpp b/src/backends/gpuFsa/GpuFsaBackend.cpp index 9886a6e187..e80369965b 100644 --- a/src/backends/gpuFsa/GpuFsaBackend.cpp +++ b/src/backends/gpuFsa/GpuFsaBackend.cpp @@ -21,6 +21,7 @@ #include <arm_compute/runtime/CL/CLBufferAllocator.h> #include "layers/GpuFsaConvolution2d.hpp" +#include "layers/GpuFsaDepthwiseConvolution2d.hpp" namespace armnn { @@ -268,6 +269,31 @@ OptimizationViews GpuFsaBackend::OptimizeSubgraphView(const SubgraphView& subgra } break; } + case (LayerType::DepthwiseConvolution2d): + { + auto input = base.GetInputSlot(0).GetConnectedOutputSlot()->GetTensorInfo(); + auto weights = base.GetInputSlot(1).GetConnectedOutputSlot()->GetTensorInfo(); + + auto desc = PolymorphicDowncast<const DepthwiseConvolution2dDescriptor*>(&base.GetParameters()); + if (desc->m_BiasEnabled) + { + auto bias = base.GetInputSlot(2).GetConnectedOutputSlot()->GetTensorInfo(); + GpuFsaDepthwiseConvolution2dCreateOp(preCompiledBlobPtr, + input, + *desc, + weights, + bias); + } + else + { + GpuFsaDepthwiseConvolution2dCreateOp(preCompiledBlobPtr, + input, + *desc, + weights, + EmptyOptional()); + } + break; + } default: // unsupported layer for GpuFsa backend continue; |