Home
last modified time | relevance | path

Searched refs:ErrorSpec (Results 1 – 25 of 107) sorted by relevance

12345

/external/tensorflow/tensorflow/compiler/xla/
Dreference_util_test.cc58 actual_literal, ErrorSpec(0.0001)); in TEST_F()
70 actual_literal, ErrorSpec(0.0001)); in TEST_F()
78 ErrorSpec(0.0001)); in TEST_F()
86 ErrorSpec(0.0001)); in TEST_F()
101 ErrorSpec(0.0001)); in TEST_F()
111 actual_literal, ErrorSpec(0.0001)); in TEST_F()
125 ErrorSpec(0.0001)); in TEST_F()
142 ErrorSpec(0.0001)); in TEST_F()
150 ErrorSpec(0.0001)); in TEST_F()
158 ErrorSpec(0.0001)); in TEST_F()
[all …]
/external/tensorflow/tensorflow/compiler/xla/tests/
Dliteral_test_util.h95 const ErrorSpec& error_spec,
102 const ErrorSpec& error);
106 const LiteralSlice& actual, const ErrorSpec& error);
111 const LiteralSlice& actual, const ErrorSpec& error);
118 const LiteralSlice& actual, const ErrorSpec& error);
125 const LiteralSlice& actual, const ErrorSpec& error);
132 const ErrorSpec& error);
137 const ErrorSpec& error);
142 const ErrorSpec& error);
149 const absl::optional<ErrorSpec>& error) TF_MUST_USE_RESULT;
[all …]
Dbroadcast_simple_test.cc111 ComputeAndCompareR0<float>(&b, 1.5, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
118 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
131 ErrorSpec(0.0001)); in XLA_TEST_F()
138 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
145 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
159 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001));
172 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001));
185 ComputeAndCompareR2<float>(&b, expected, {}, ErrorSpec(0.0001));
203 ComputeAndCompareR3<float>(&b, expected, {}, ErrorSpec(0.0001));
221 ComputeAndCompareR3<float>(&b, expected, {}, ErrorSpec(0.0001));
[all …]
Dliteral_test_util_test.cc126 ErrorSpec error(0.001); in TEST()
185 EXPECT_TRUE(LiteralTestUtil::Near(a, b, ErrorSpec{0.0001})); in TEST()
225 EXPECT_TRUE(LiteralTestUtil::Near(a, b, ErrorSpec{0.0001})); in TEST()
226 EXPECT_FALSE(LiteralTestUtil::Near(a, c, ErrorSpec{0.0001})); in TEST()
227 EXPECT_FALSE(LiteralTestUtil::Near(a, d, ErrorSpec{0.0001})); in TEST()
228 EXPECT_FALSE(LiteralTestUtil::Near(c, d, ErrorSpec{0.0001})); in TEST()
268 EXPECT_TRUE(LiteralTestUtil::Near(a, b, ErrorSpec{0.0001})); in TEST()
269 EXPECT_FALSE(LiteralTestUtil::Near(a, c, ErrorSpec{0.0001})); in TEST()
270 EXPECT_FALSE(LiteralTestUtil::Near(a, d, ErrorSpec{0.0001})); in TEST()
271 EXPECT_FALSE(LiteralTestUtil::Near(c, d, ErrorSpec{0.0001})); in TEST()
[all …]
Dconcat_test.cc59 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
68 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
91 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
101 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
111 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
121 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
140 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
151 ErrorSpec(0.0001)); in XLA_TEST_F()
167 ComputeAndCompareR2<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
181 ComputeAndCompareR2<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
[all …]
Dtriangular_solve_test.cc138 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
159 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
180 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
201 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
223 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
245 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
264 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
286 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
308 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
330 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
[all …]
Dhlo_test_base.h193 const absl::optional<ErrorSpec>& error,
202 const absl::optional<ErrorSpec>& error,
208 std::unique_ptr<HloModule> module, const absl::optional<ErrorSpec>& error,
215 std::unique_ptr<HloModule> module, const absl::optional<ErrorSpec>& error,
229 const absl::optional<ErrorSpec>& error,
249 const string& filename, const absl::optional<ErrorSpec>& error,
254 const absl::optional<ErrorSpec>& error,
258 const string& filename, const absl::optional<ErrorSpec>& error,
321 ErrorSpec error_spec_{0.0001};
337 const absl::optional<ErrorSpec>& error, bool run_hlo_passes,
Dexhaustive_op_test_utils.h34 struct ErrorSpec { struct
44 ErrorSpec(float a, float r) : abs_err(a), rel_err(r) {} in ErrorSpec() argument
83 using type = ErrorSpec (*)(NativeT);
88 using type = ErrorSpec (*)(NativeT, NativeT);
457 bool IsClose(NativeRefT expected, NativeRefT actual, ErrorSpec spec) {
940 inline ErrorSpec DefaultSpecGenerator(
946 inline ErrorSpec DefaultSpecGenerator(
953 inline ErrorSpec DefaultSpecGenerator<C128, 1>(complex128) {
954 return ErrorSpec{0.0001, 0.0001};
958 inline ErrorSpec DefaultSpecGenerator<C64, 1>(complex64) {
[all …]
Dbinop_scaling_test.cc44 ComputeAndCompareR2<float>(&builder, *aexpected, {}, ErrorSpec(0.0001)); in TEST_F()
60 ComputeAndCompareR2<float>(&builder, *aexpected, {}, ErrorSpec(0.0001)); in TEST_F()
76 ComputeAndCompareR2<float>(&builder, *aexpected, {}, ErrorSpec(0.0001)); in TEST_F()
92 ComputeAndCompareR2<float>(&builder, *aexpected, {}, ErrorSpec(0.0001)); in TEST_F()
109 ComputeAndCompareR2<float>(&builder, expected, {}, ErrorSpec(0.0001)); in TEST_F()
Dexhaustive_unary_test_f32_or_smaller.cc256 error_spec_gen = +[](NativeT x) { return ErrorSpec{0.001, 0.001}; }; in __anon1843a2950202()
264 error_spec_gen = +[](NativeT x) { return ErrorSpec{0.001, 0.001}; }; in __anon1843a2950302()
278 return ErrorSpec{0, 0}; in __anon1843a2950402()
303 error_spec_gen = +[](NativeT x) { return ErrorSpec{0, 0.00015}; }; in __anon1843a2950602()
361 return ErrorSpec{0.01, 0.01}; in __anon1843a2950d02()
374 error_spec_gen = +[](float x) { return ErrorSpec{0.001, 0.001}; }; in XLA_TEST_P()
392 error_spec_gen = +[](float x) { return ErrorSpec{0.001, 0.001}; }; in XLA_TEST_P()
457 ? ErrorSpec{0, 0} in __anon1843a2951202()
523 return ErrorSpec{0.001, 0.001}; in __anon1843a2951902()
541 return ErrorSpec{0.001, 0.001}; in __anon1843a2951a02()
[all …]
Dcholesky_test.cc61 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
99 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
125 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
151 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
174 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
213 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_F()
258 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_P()
307 ErrorSpec(1e-4, 1e-4)); in XLA_TEST_P()
Dreduce_test.cc117 ErrorSpec(0.001)); in RunR1ToR0Test()
226 ErrorSpec(0.01, 1e-4)); in RunR2ToR0Test()
255 ErrorSpec(0.01, 1e-4)); in RunR2ToR1Test()
265 ErrorSpec(0.01, 1e-4)); in ComputeAndCompareGeneric()
465 ErrorSpec(0.01, 1e-4)); in XLA_TEST_F()
496 ErrorSpec(0.01, 1e-4)); in XLA_TEST_F()
512 ComputeAndCompare(&builder, {std::move(input_data)}, ErrorSpec(0.01, 1e-4)); in XLA_TEST_F()
544 ErrorSpec(0.01, 1e-4)); in XLA_TEST_F()
570 ComputeAndCompareR0<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
582 ComputeAndCompareR0<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
[all …]
Dselect_and_scatter_test.cc87 ComputeAndCompare(&builder_, {}, ErrorSpec(1e-5, 1e-5)); in XLA_TEST_P()
222 ComputeAndCompareR1<float>(&builder_, {}, {}, ErrorSpec(1e-7)); in XLA_TEST_F()
234 ComputeAndCompareR1<float>(&builder_, expected, {}, ErrorSpec(1e-7)); in XLA_TEST_F()
283 ComputeAndCompareR2<float>(&builder_, expected, {}, ErrorSpec(1e-7)); in XLA_TEST_F()
348 ComputeAndCompareR2<float>(&builder_, expected, {}, ErrorSpec(1e-7)); in XLA_TEST_F()
373 ComputeAndCompareR4<float>(&builder_, e, {}, ErrorSpec(1e-7)); in TEST_F()
398 ComputeAndCompareR4<float>(&builder_, e, {}, ErrorSpec(1e-7)); in TEST_F()
423 ComputeAndCompareR4<float>(&builder_, e, {}, ErrorSpec(1e-7)); in TEST_F()
446 ComputeAndCompareR4<float>(&builder_, *e, {}, ErrorSpec(1e-7)); in TEST_F()
456 ComputeAndCompareR1<float>(&builder_, expected, {}, ErrorSpec(1e-7)); in XLA_TEST_F()
[all …]
Dparams_test.cc52 ErrorSpec(0.0001f)); in XLA_TEST_F()
64 ErrorSpec(0.01f)); in XLA_TEST_F()
76 ErrorSpec(0.01f)); in XLA_TEST_F()
103 {param0_data.get()}, ErrorSpec(0.01f)); in XLA_TEST_F()
118 ErrorSpec(0.01f)); in XLA_TEST_F()
149 ErrorSpec(0.0001f)); in XLA_TEST_F()
181 ErrorSpec(0.0001f)); in XLA_TEST_F()
209 ErrorSpec(0.0001f)); in XLA_TEST_F()
246 ComputeAndCompareR1<float>(&builder, sum, param_data, ErrorSpec(0.0001f)); in XLA_TEST_F()
281 ComputeAndCompareR0<float>(&builder, target, param_data, ErrorSpec(0.0001f)); in XLA_TEST_F()
[all …]
Dmultioutput_fusion_test.cc52 MultiOutputFusionTest() { error_spec_ = ErrorSpec{0.0001, 1e-2}; } in MultiOutputFusionTest()
315 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
337 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
360 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
383 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
406 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
437 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
460 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
484 EXPECT_TRUE(RunAndCompareNoHloPasses(std::move(module), ErrorSpec(1e-5))); in XLA_TEST_F()
Dcall_test.cc83 ComputeAndCompareR0<float>(&builder, 42.0, {}, ErrorSpec(0.01f)); in XLA_TEST_F()
93 ComputeAndCompareR1<float>(&builder, {}, {}, ErrorSpec(0.01f)); in XLA_TEST_F()
105 ComputeAndCompareR1<float>(&builder, {3.0f, 5.0f}, {}, ErrorSpec(0.01f)); in XLA_TEST_F()
136 ComputeAndCompareR0<float>(&builder3, 10.0f, {start.get()}, ErrorSpec(0.0f)); in XLA_TEST_F()
146 ComputeAndCompareTuple(&builder, tuple, {}, ErrorSpec(0.01f)); in XLA_TEST_F()
Daxpy_simple_test.cc40 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in TEST_F()
52 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in XLA_TEST_F()
72 ComputeAndCompareR1<float>(&builder, expected, {}, ErrorSpec(0.0001)); in TEST_F()
/external/tensorflow/tensorflow/compiler/xla/service/gpu/tests/
Dgpu_kernel_tiling_test.cc82 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
127 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
163 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
203 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
310 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
350 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.0})); in TEST_F()
401 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{1.0e-5, 1.0e-5})); in TEST_F()
459 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{1.0e-5, 1.0e-5})); in TEST_F()
537 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{1.0e-5, 1.0e-5})); in TEST_F()
577 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0.001})); in TEST_F()
[all …]
Dtree_reduction_rewriter_test.cc91 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
130 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
169 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
208 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
248 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
288 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
326 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
366 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
Dreduction_vectorization_test.cc82 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
130 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
183 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
212 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
262 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
293 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
366 EXPECT_TRUE(RunAndCompare(hlo_text, ErrorSpec{1e-5, 1e-5})); in TEST_F()
Dgpu_input_fusible_slice_test.cc79 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0, 0})); in TEST_F()
121 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0, 0})); in TEST_F()
168 EXPECT_TRUE(RunAndCompareNoHloPasses(kHloString, ErrorSpec{0, 0})); in TEST_F()
/external/tensorflow/tensorflow/compiler/xla/client/lib/
Dsvd_test.cc134 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
146 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
159 ErrorSpec(1e-2, 1e-2)); in XLA_TEST_F()
171 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
188 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
202 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
214 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
226 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
240 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
254 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
[all …]
Dself_adjoint_eig_test.cc154 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
167 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
180 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
192 {a_data.get()}, ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
204 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
220 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
237 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
260 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
273 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
286 ErrorSpec(1e-3, 1e-3)); in XLA_TEST_F()
[all …]
/external/tensorflow/tensorflow/compiler/xla/service/
Delemental_ir_emitter_test.cc47 EXPECT_TRUE(RunAndCompare(std::move(module), ErrorSpec{(0.)})); in RunTypeConversionTest()
129 EXPECT_TRUE(RunAndCompare(std::move(module), ErrorSpec{4e-3, 4e-3})); in XLA_TEST_F()
153 EXPECT_TRUE(RunAndCompare(std::move(module), ErrorSpec{(0.)})); in XLA_TEST_F()
176 EXPECT_TRUE(RunAndCompare(std::move(module), ErrorSpec{(0.)})); in XLA_TEST_F()
200 EXPECT_TRUE(RunAndCompare(std::move(module), ErrorSpec{(0.)})); in XLA_TEST_F()
/external/tensorflow/tensorflow/python/kernel_tests/distributions/
Dspecial_math_test.py82 ErrorSpec = collections.namedtuple("ErrorSpec", ["rtol", "atol"]) variable
156 _error32 = ErrorSpec(rtol=1e-4, atol=0.)
157 _error64 = ErrorSpec(rtol=1e-6, atol=0.)
230 _error32 = ErrorSpec(rtol=1e-4, atol=0.)
231 _error64 = ErrorSpec(rtol=1e-4, atol=0.)
245 _error32 = ErrorSpec(rtol=0.1, atol=1e-7)
246 _error64 = ErrorSpec(rtol=0.1, atol=1e-7)
259 _error32 = ErrorSpec(rtol=1e-6, atol=1e-14)
260 _error64 = ErrorSpec(rtol=1e-6, atol=1e-14)
266 _error32 = ErrorSpec(rtol=1e-4, atol=0)
[all …]

12345