aboutsummaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorJohn Richardson <john.richardson@arm.com>2018-02-22 14:09:31 +0000
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:49:16 +0000
commit8de92619e223225aabdca873c02f231d8e941fd1 (patch)
tree6b0c7a04e58e120fc9969270cb7ba432a31e1258 /utils
parent2abb216e1aaeefe65c8a7e6294b4735f0647c927 (diff)
downloadComputeLibrary-8de92619e223225aabdca873c02f231d8e941fd1.tar.gz
COMPMID-585: Port OpticalFlow to new validation
Change-Id: Ia36bd11ca27420d3059eea15df81b237900149ec Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/125175 Tested-by: Jenkins <bsgcomp@arm.com> Reviewed-by: John Richardson <john.richardson@arm.com> Reviewed-by: Anthony Barbier <anthony.barbier@arm.com>
Diffstat (limited to 'utils')
-rw-r--r--utils/TypePrinter.h70
1 files changed, 61 insertions, 9 deletions
diff --git a/utils/TypePrinter.h b/utils/TypePrinter.h
index e26b695809..c2de2a7e58 100644
--- a/utils/TypePrinter.h
+++ b/utils/TypePrinter.h
@@ -1458,7 +1458,13 @@ inline std::string to_string(const GPUTarget &gpu_target)
return str.str();
}
-/** Formatted output of the DetectionWindow type. */
+/** Formatted output of the DetectionWindow type.
+ *
+ * @param[out] os Output stream
+ * @param[in] detection_window Type to output
+ *
+ * @return Modified output stream.
+ */
inline ::std::ostream &operator<<(::std::ostream &os, const DetectionWindow &detection_window)
{
os << "{x=" << detection_window.x << ","
@@ -1471,6 +1477,59 @@ inline ::std::ostream &operator<<(::std::ostream &os, const DetectionWindow &det
return os;
}
+/** Formatted output of the DetectionWindow type.
+ *
+ * @param[in] detection_window Type to output
+ *
+ * @return Formatted string.
+ */
+inline std::string to_string(const DetectionWindow &detection_window)
+{
+ std::stringstream str;
+ str << detection_window;
+ return str.str();
+}
+
+/** Formatted output of the Termination type.
+ *
+ * @param[out] os Output stream
+ * @param[in] termination Type to output
+ *
+ * @return Modified output stream.
+ */
+inline ::std::ostream &operator<<(::std::ostream &os, const Termination &termination)
+{
+ switch(termination)
+ {
+ case Termination::TERM_CRITERIA_EPSILON:
+ os << "TERM_CRITERIA_EPSILON";
+ break;
+ case Termination::TERM_CRITERIA_ITERATIONS:
+ os << "TERM_CRITERIA_ITERATIONS";
+ break;
+ case Termination::TERM_CRITERIA_BOTH:
+ os << "TERM_CRITERIA_BOTH";
+ break;
+ default:
+ ARM_COMPUTE_ERROR("NOT_SUPPORTED!");
+ }
+
+ return os;
+}
+
+/** Formatted output of the Termination type.
+ *
+ * @param[in] termination Type to output
+ *
+ * @return Formatted string.
+ */
+inline std::string to_string(const Termination &termination)
+{
+ std::stringstream str;
+ str << termination;
+ return str.str();
+}
+
/** Formatted output of the WinogradInfo type. */
inline ::std::ostream &operator<<(::std::ostream &os, const WinogradInfo &info)
{
@@ -1482,13 +1541,6 @@ inline ::std::ostream &operator<<(::std::ostream &os, const WinogradInfo &info)
return os;
}
-inline std::string to_string(const DetectionWindow &type)
-{
- std::stringstream str;
- str << type;
- return str.str();
-}
-
inline std::string to_string(const WinogradInfo &type)
{
std::stringstream str;
@@ -1496,4 +1548,4 @@ inline std::string to_string(const WinogradInfo &type)
return str.str();
}
} // namespace arm_compute
-#endif /* __ARM_COMPUTE_TEST_TYPE_PRINTER_H__ */ \ No newline at end of file
+#endif /* __ARM_COMPUTE_TEST_TYPE_PRINTER_H__ */