| 106 | } |
| 107 | |
| 108 | bool verify_args_with_tolerance(const std::string& name, |
| 109 | const argument& target_arg, |
| 110 | const verify::expected<argument>& ref_arg, |
| 111 | std::size_t tolerance) |
| 112 | { |
| 113 | double rms_tol = 0.001; |
| 114 | argument t_arg = target_arg; |
| 115 | if(not t_arg.get_shape().computable()) |
| 116 | { |
| 117 | shape o_t_shape = t_arg.get_shape(); |
| 118 | t_arg = t_arg.reshape(shape{shape::uint8_type, o_t_shape.lens(), o_t_shape.strides()}); |
| 119 | } |
| 120 | t_arg.visit([&](auto ta) { rms_tol = verify::get_rms_tol(ta, tolerance); }); |
| 121 | verify::tolerance tols{rms_tol}; |
| 122 | return verify_args(name, target_arg, ref_arg, tols); |
| 123 | } |
| 124 | |
| 125 | } // namespace MIGRAPHX_INLINE_NS |
| 126 | } // namespace migraphx |
no test coverage detected