From 404462af4ca002ece819161a03a4bdb19a87abf2 Mon Sep 17 00:00:00 2001 From: Ramy Elgammal Date: Tue, 8 Nov 2022 02:14:46 +0000 Subject: Adding GpuAdd to dynamic fusion operators - Provide support for Add operator - Auto initialize the destination tensor before testing fusion in conv2d and elementwise binary ops. Resolves: COMPMID-5518 Signed-off-by: Ramy Elgammal Change-Id: Ibd815020f02b57f88eea7c2921bdcf98605d99c5 Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/8617 Comments-Addressed: Arm Jenkins Tested-by: Arm Jenkins Reviewed-by: Gunes Bayir Benchmark: Arm Jenkins --- tests/datasets/ShapeDatasets.h | 70 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) (limited to 'tests/datasets/ShapeDatasets.h') diff --git a/tests/datasets/ShapeDatasets.h b/tests/datasets/ShapeDatasets.h index e4277a981e..047457c99e 100644 --- a/tests/datasets/ShapeDatasets.h +++ b/tests/datasets/ShapeDatasets.h @@ -212,6 +212,25 @@ public: } }; +/** Data set containing small tensor shapes. */ +class SmallShapesNoBatches final : public ShapeDataset +{ +public: + SmallShapesNoBatches() + : ShapeDataset("Shape", + { + // Batch size 1 + TensorShape{ 3U, 11U }, + TensorShape{ 1U, 16U }, + TensorShape{ 27U, 13U, 7U }, + TensorShape{ 7U, 7U, 17U }, + TensorShape{ 33U, 13U, 2U }, + TensorShape{ 11U, 11U, 3U } + }) + { + } +}; + /** Data set containing pairs of tiny tensor shapes that are broadcast compatible. */ class TinyShapesBroadcast final : public framework::dataset::ZipDataset { @@ -282,6 +301,44 @@ public: } }; +class TemporaryLimitedSmallShapesBroadcast final : public framework::dataset::ZipDataset +{ +public: + TemporaryLimitedSmallShapesBroadcast() + : ZipDataset( + ShapeDataset("Shape0", + { + TensorShape{ 9U, 9U, 5U }, + TensorShape{ 27U, 13U, 2U }, + }), + ShapeDataset("Shape1", + { + TensorShape{ 1U, 1U, 1U }, // Broadcast in X, Y, Z + TensorShape{ 27U, 1U, 1U }, // Broadcast in Y and Z + })) + { + } +}; + +class TemporaryLimitedLargeShapesBroadcast final : public framework::dataset::ZipDataset +{ +public: + TemporaryLimitedLargeShapesBroadcast() + : ZipDataset( + ShapeDataset("Shape0", + { + TensorShape{ 127U, 25U, 5U }, + TensorShape{ 485, 40U, 10U } + }), + ShapeDataset("Shape1", + { + TensorShape{ 1U, 1U, 1U }, // Broadcast in X, Y, Z + TensorShape{ 485U, 1U, 1U }, // Broadcast in Y, Z + })) + { + } +}; + /** Data set containing medium tensor shapes. */ class MediumShapes final : public ShapeDataset { @@ -359,6 +416,19 @@ public: } }; +/** Data set containing large tensor shapes. */ +class LargeShapesNoBatches final : public ShapeDataset +{ +public: + LargeShapesNoBatches() + : ShapeDataset("Shape", + { + TensorShape{ 582U, 131U, 2U }, + }) + { + } +}; + /** Data set containing pairs of large tensor shapes that are broadcast compatible. */ class LargeShapesBroadcast final : public framework::dataset::ZipDataset { -- cgit v1.2.1