aboutsummaryrefslogtreecommitdiff
path: root/tests/datasets/SmallConvolutionLayerDataset.h
diff options
context:
space:
mode:
authorGunes Bayir <gunes.bayir@arm.com>2021-09-13 13:38:29 +0100
committerGunes Bayir <gunes.bayir@arm.com>2021-09-15 19:13:17 +0000
commitcc171f9e4520e16b5e1b9c483562ed022d9151fa (patch)
treef364fb4dd1d8f775c21066ae53f61185257766cc /tests/datasets/SmallConvolutionLayerDataset.h
parent9d6ddfc8a0ea579fb2a46fab971f6827d93fc96b (diff)
downloadComputeLibrary-cc171f9e4520e16b5e1b9c483562ed022d9151fa.tar.gz
Provide tests for fusing pad layer in graph API
There are two tests: - A unit test that checks if certain padding configurations are to be fused or not - A fixture test that compares a reference implementation of pad+conv vs target implementation using the same fusing logic as graph API Tests are written for CL backend only to prevent code duplication. The code written in the graph API remains untested. Resolves: COMPMID-4702 Change-Id: Ie84d1cb910013033b46ac9d66cf5fc556d4963d2 Signed-off-by: Gunes Bayir <gunes.bayir@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/6252 Tested-by: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Sheri Zhang <sheri.zhang@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'tests/datasets/SmallConvolutionLayerDataset.h')
-rw-r--r--tests/datasets/SmallConvolutionLayerDataset.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/datasets/SmallConvolutionLayerDataset.h b/tests/datasets/SmallConvolutionLayerDataset.h
index 7d1db5a73e..67eade1e64 100644
--- a/tests/datasets/SmallConvolutionLayerDataset.h
+++ b/tests/datasets/SmallConvolutionLayerDataset.h
@@ -181,6 +181,17 @@ public:
}
};
+class SmallConvolutionLayerPrePaddingDataset final : public ConvolutionLayerDataset
+{
+public:
+ SmallConvolutionLayerPrePaddingDataset()
+ {
+ // output shape is calculated by accounting pre-padding layer as well -- all the data is in nchw
+ add_config(TensorShape(17U, 31U, 2U), TensorShape(5U, 5U, 2U, 19U), TensorShape(19U), TensorShape(17U, 16U, 19U), PadStrideInfo(1, 2, 1, 1));
+ add_config(TensorShape(33U, 27U, 7U), TensorShape(5U, 5U, 7U, 16U), TensorShape(16U), TensorShape(12U, 13U, 16U), PadStrideInfo(3, 2, 2, 0));
+ }
+};
+
class SmallConvolutionLayerReducedDataset final : public ConvolutionLayerDataset
{
public: