aboutsummaryrefslogtreecommitdiff
path: root/src/graph/nodes/DepthwiseConvolutionLayerNode.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/graph/nodes/DepthwiseConvolutionLayerNode.cpp')
-rw-r--r--src/graph/nodes/DepthwiseConvolutionLayerNode.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/graph/nodes/DepthwiseConvolutionLayerNode.cpp b/src/graph/nodes/DepthwiseConvolutionLayerNode.cpp
index 935902d3fd..cdd9e7b601 100644
--- a/src/graph/nodes/DepthwiseConvolutionLayerNode.cpp
+++ b/src/graph/nodes/DepthwiseConvolutionLayerNode.cpp
@@ -86,10 +86,11 @@ TensorDescriptor DepthwiseConvolutionLayerNode::compute_output_descriptor(const
std::tie(output_width, output_height) = scaled_dimensions(input_width, input_height, kernel_width, kernel_height, info);
+ const DataLayout data_layout = input_descriptor.layout;
TensorDescriptor output_descriptor = input_descriptor;
- output_descriptor.shape.set(get_dimension_idx(output_descriptor, DataLayoutDimension::WIDTH), output_width);
- output_descriptor.shape.set(get_dimension_idx(output_descriptor, DataLayoutDimension::HEIGHT), output_height);
- output_descriptor.shape.set(get_dimension_idx(output_descriptor, DataLayoutDimension::CHANNEL), input_channels * depth_multiplier);
+ output_descriptor.shape.set(get_dimension_idx(data_layout, DataLayoutDimension::WIDTH), output_width);
+ output_descriptor.shape.set(get_dimension_idx(data_layout, DataLayoutDimension::HEIGHT), output_height);
+ output_descriptor.shape.set(get_dimension_idx(data_layout, DataLayoutDimension::CHANNEL), input_channels * depth_multiplier);
return output_descriptor;
}