From c04a0e8f93c620d05444251e1ae55dcf8c660a1b Mon Sep 17 00:00:00 2001 From: giuros01 Date: Wed, 3 Oct 2018 12:44:35 +0100 Subject: COMPMID-1327: Add support for BBoxTransform operator in CL Change-Id: I91865506166951b3bf7f06a0b2d4cde925cfefb6 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/153447 Tested-by: bsgcomp Reviewed-by: Pablo Tello --- utils/TypePrinter.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'utils') diff --git a/utils/TypePrinter.h b/utils/TypePrinter.h index b868aa94a1..571de9a4ef 100644 --- a/utils/TypePrinter.h +++ b/utils/TypePrinter.h @@ -233,6 +233,34 @@ inline std::string to_string(const ROIPoolingLayerInfo &pool_info) return str.str(); } +/** Formatted output of the BoundingBoxTransformInfo type. + * + * @param[out] os Output stream. + * @param[in] bbox_info Type to output. + * + * @return Modified output stream. + */ +inline ::std::ostream &operator<<(::std::ostream &os, const BoundingBoxTransformInfo &bbox_info) +{ + auto weights = bbox_info.weights(); + os << "(" << bbox_info.img_width() << "x" << bbox_info.img_height() << ")~" << bbox_info.scale() << "(weights = {" << weights[0] << ", " << weights[1] << ", " << weights[2] << ", " << weights[3] << + "})"; + return os; +} + +/** Formatted output of the BoundingBoxTransformInfo type. + * + * @param[in] bbox_info Type to output. + * + * @return Formatted string. + */ +inline std::string to_string(const BoundingBoxTransformInfo &bbox_info) +{ + std::stringstream str; + str << bbox_info; + return str.str(); +} + /** Formatted output of the QuantizationInfo type. * * @param[out] os Output stream. -- cgit v1.2.1