From e2220551b7a64b929650ba9a60529c31e70c13c5 Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Fri, 20 Jul 2018 13:23:44 +0100 Subject: COMPMID-1367: Enable NHWC in graph examples Change-Id: Iabc54a3a1bdcd46a9a921cda39c7c85fef672b72 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/141449 Reviewed-by: Giorgio Arena Reviewed-by: Anthony Barbier Tested-by: Jenkins --- utils/TypePrinter.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) (limited to 'utils/TypePrinter.h') diff --git a/utils/TypePrinter.h b/utils/TypePrinter.h index eb03ff9b96..8bfdba9725 100644 --- a/utils/TypePrinter.h +++ b/utils/TypePrinter.h @@ -475,6 +475,35 @@ inline std::string to_string(const arm_compute::DataLayout &data_layout) return str.str(); } +/** Formatted output of the DataLayoutDimension type. + * + * @param[out] os Output stream. + * @param[in] data_layout_dim Data layout dimension to print. + * + * @return Modified output stream. + */ +inline ::std::ostream &operator<<(::std::ostream &os, const DataLayoutDimension &data_layout_dim) +{ + switch(data_layout_dim) + { + case DataLayoutDimension::WIDTH: + os << "WIDTH"; + break; + case DataLayoutDimension::HEIGHT: + os << "HEIGHT"; + break; + case DataLayoutDimension::CHANNEL: + os << "CHANNEL"; + break; + case DataLayoutDimension::BATCHES: + os << "BATCHES"; + break; + default: + ARM_COMPUTE_ERROR("NOT_SUPPORTED!"); + } + return os; +} + /** Formatted output of the DataType type. * * @param[out] os Output stream. -- cgit v1.2.1