aboutsummaryrefslogtreecommitdiff
path: root/tests/Utils.h
diff options
context:
space:
mode:
authorIoan-Cristian Szabo <ioan-cristian.szabo@arm.com>2017-10-27 17:35:40 +0100
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:47:18 +0000
commit9414f64c231a013664102e2c284b10266c6b4d4e (patch)
tree5a5ad6a525004634fe6b78cdfc8da71aae762d33 /tests/Utils.h
parent6acc6add8412c6d3841a49684610fc5a6526312e (diff)
downloadComputeLibrary-9414f64c231a013664102e2c284b10266c6b4d4e.tar.gz
COMPMID-582: Add validation to channel_extract kernels.
Change-Id: I5022d02f06f9d849dad76e3d9b8e48632c236429 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/121191 Reviewed-by: Anthony Barbier <anthony.barbier@arm.com> Tested-by: Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'tests/Utils.h')
-rw-r--r--tests/Utils.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/Utils.h b/tests/Utils.h
index 893cb3ebb4..27e0397b6b 100644
--- a/tests/Utils.h
+++ b/tests/Utils.h
@@ -500,6 +500,22 @@ inline T create_tensor(const TensorShape &shape, Format format)
return tensor;
}
+/** Create and initialize a multi-image of the given type.
+ *
+ * @param[in] shape Tensor shape.
+ * @param[in] format Format type.
+ *
+ * @return Initialized tensor of given type.
+ */
+template <typename T>
+inline T create_multi_image(const TensorShape &shape, Format format)
+{
+ T multi_image;
+ multi_image.init(shape.x(), shape.y(), format);
+
+ return multi_image;
+}
+
/** Create and initialize a HOG (Histogram of Oriented Gradients) of the given type.
*
* @param[in] cell_size Cell size in pixels