Home
last modified time | relevance | path

Searched refs:tolerance (Results 1 – 25 of 166) sorted by relevance

1234567

/external/eigen/Eigen/src/SparseCore/
DSparseSparseProductWithPruning.h20 …(const Lhs& lhs, const Rhs& rhs, ResultType& res, const typename ResultType::RealScalar& tolerance) in sparse_sparse_product_with_pruning_impl() argument
73 for (typename AmbiVector<Scalar,StorageIndex>::Iterator it(tempVector,tolerance); it; ++it) in sparse_sparse_product_with_pruning_impl()
91 static void run(const Lhs& lhs, const Rhs& rhs, ResultType& res, const RealScalar& tolerance)
94 … internal::sparse_sparse_product_with_pruning_impl<Lhs,Rhs,ResultType>(lhs, rhs, _res, tolerance);
103 static void run(const Lhs& lhs, const Rhs& rhs, ResultType& res, const RealScalar& tolerance)
108 …l::sparse_sparse_product_with_pruning_impl<Lhs,Rhs,SparseTemporaryType>(lhs, rhs, _res, tolerance);
117 static void run(const Lhs& lhs, const Rhs& rhs, ResultType& res, const RealScalar& tolerance)
121 … internal::sparse_sparse_product_with_pruning_impl<Rhs,Lhs,ResultType>(rhs, lhs, _res, tolerance);
130 static void run(const Lhs& lhs, const Rhs& rhs, ResultType& res, const RealScalar& tolerance)
136 …_with_pruning_impl<ColMajorMatrixLhs,ColMajorMatrixRhs,ResultType>(colLhs, colRhs, res, tolerance);
[all …]
/external/tensorflow/tensorflow/lite/kernels/internal/
Dlog_quantized_test.cc74 int output_integer_bits, int tolerance) { in CheckOutputData() argument
86 ? tolerance in CheckOutputData()
87 : std::max(tolerance, static_cast<int>(std::ceil( in CheckOutputData()
105 << "; tolerance=" << tolerance in CheckOutputData()
121 const string& check_label, int tolerance) { in RunSingleTest() argument
148 InputIntegerBits, OutputIntegerBits, tolerance); in RunSingleTest()
154 const string& check_label, int tolerance) { in RunSingleTest() argument
158 tolerance) in RunSingleTest()
199 int tolerance) { in RunSingleTest() argument
203 tolerance) in RunSingleTest()
[all …]
/external/fonttools/Lib/fontTools/varLib/
Diup.py94 def can_iup_in_between(deltas, coords, i, j, tolerance): argument
101 return all(abs(complex(x-p, y-q)) <= tolerance for (x,y),(p,q) in zip(deltas, interp))
103 def _iup_contour_bound_forced_set(delta, coords, tolerance=0): argument
143 if not (min(d1,d2)-tolerance <= dj <= max(d1,d2)+tolerance):
148 if abs(dj - d1) > tolerance:
151 if abs(dj) > tolerance:
157 if dj != d1 and ((dj-tolerance < d1) != (d1 < d2)):
160 if d2 != dj and ((d2 < dj+tolerance) != (d1 < d2)):
171 def _iup_contour_optimize_dp(delta, coords, forced={}, tolerance=0, lookback=None): argument
199 if cost < best_cost and can_iup_in_between(delta, coords, j, i, tolerance):
[all …]
/external/webrtc/webrtc/modules/audio_coding/neteq/
Daudio_decoder_unittest.cc49 int tolerance, in CompareInputOutput() argument
54 ASSERT_NEAR(input[n], output[channels * n + delay], tolerance) in CompareInputOutput()
67 int tolerance) { in CompareTwoChannels() argument
71 ASSERT_NEAR(output[channels * n], output[channels * n + 1], tolerance) in CompareTwoChannels()
176 void EncodeDecodeTest(size_t expected_bytes, int tolerance, double mse, in EncodeDecodeTest() argument
178 ASSERT_GE(tolerance, 0) << "Test must define a tolerance >= 0"; in EncodeDecodeTest()
213 input, decoded, processed_samples, channels_, tolerance, delay); in EncodeDecodeTest()
479 int tolerance = 251; in TEST_F() local
481 EncodeDecodeTest(data_length_, tolerance, mse); in TEST_F()
505 int tolerance = 308; in TEST_F() local
[all …]
/external/fonttools/Lib/fontTools/pens/
Dt2CharStringPen.py12 def t2c_round(number, tolerance=0.5): argument
13 if tolerance == 0:
19 if tolerance >= .5 or abs(rounded - number) <= tolerance:
25 def makeRoundFunc(tolerance): argument
26 if tolerance < 0:
31 return t2c_round(x, tolerance), t2c_round(y, tolerance)
DperimeterPen.py19 def __init__(self, glyphset=None, tolerance=0.005): argument
22 self.tolerance = tolerance
27 self._addCubic = self._addCubicQuadrature if tolerance >= 0.0015 else self._addCubicRecursive
28 …self._addQuadratic = self._addQuadraticQuadrature if tolerance >= 0.00075 else self._addQuadraticE…
53 self.value += calcCubicArcLengthC(c0, c1, c2, c3, self.tolerance)
/external/opencensus-java/impl_core/src/test/java/io/opencensus/implcore/stats/
DStatsTestUtil.java88 double tolerance) { in assertAggregationMapEquals() argument
92 assertAggregationDataEquals(expected.get(entry.getKey()), entry.getValue(), tolerance); in assertAggregationMapEquals() local
104 AggregationData expected, final AggregationData actual, final double tolerance) { in assertAggregationDataEquals() argument
110 assertThat(((SumDataDouble) actual).getSum()).isWithin(tolerance).of(arg.getSum()); in assertAggregationDataEquals()
134 assertDistributionDataEquals(arg, (DistributionData) actual, tolerance); in assertAggregationDataEquals()
143 .isWithin(tolerance) in assertAggregationDataEquals()
162 .isWithin(tolerance) in assertAggregationDataEquals()
187 DistributionData expected, DistributionData actual, double tolerance) { in assertDistributionDataEquals() argument
188 assertThat(actual.getMean()).isWithin(tolerance).of(expected.getMean()); in assertDistributionDataEquals()
190 assertThat(actual.getMean()).isWithin(tolerance).of(expected.getMean()); in assertDistributionDataEquals()
[all …]
/external/tensorflow/tensorflow/core/kernels/
Dquantized_resize_bilinear_op_test.cc149 const float max, const float tolerance, in CheckTensorValue() argument
170 const int q_tolerance = std::round(tolerance); in CheckTensorValue()
177 const float rel_tolerance = std::max(ref_val, 1.0f) * tolerance; in CheckTensorValue()
298 float tolerance, bool relative, in RunTestResizeBilinearTwoDims() argument
315 /*half_pixel_centers=*/half_pixel_centers, min, max, tolerance, relative); in RunTestResizeBilinearTwoDims()
338 void TestResizeBilinearTwoDimsType(const float tolerance, const bool relative, in TestResizeBilinearTwoDimsType() argument
340 RunTestResizeBilinearTwoDims<T>(1, 1, 1, 1, 1, 1, tolerance, relative, in TestResizeBilinearTwoDimsType()
342 RunTestResizeBilinearTwoDims<T>(1, 1, 128, 1, 256, 1, tolerance, relative, in TestResizeBilinearTwoDimsType()
344 RunTestResizeBilinearTwoDims<T>(1, 128, 1, 256, 1, 1, tolerance, relative, in TestResizeBilinearTwoDimsType()
346 RunTestResizeBilinearTwoDims<T>(1, 128, 128, 256, 256, 1, tolerance, relative, in TestResizeBilinearTwoDimsType()
[all …]
/external/guava/guava-tests/test/com/google/common/math/
DDoubleMathTest.java549 for (double tolerance : FINITE_TOLERANCE_CANDIDATES) { in testFuzzyEqualsFinite()
551 Math.abs(a - b) <= tolerance, in testFuzzyEqualsFinite()
552 DoubleMath.fuzzyEquals(a, b, tolerance)); in testFuzzyEqualsFinite()
561 for (double tolerance : FINITE_TOLERANCE_CANDIDATES) { in testFuzzyInfiniteVersusFiniteWithFiniteTolerance()
562 assertFalse(DoubleMath.fuzzyEquals(a, inf, tolerance)); in testFuzzyInfiniteVersusFiniteWithFiniteTolerance()
563 assertFalse(DoubleMath.fuzzyEquals(inf, a, tolerance)); in testFuzzyInfiniteVersusFiniteWithFiniteTolerance()
571 for (double tolerance : FINITE_TOLERANCE_CANDIDATES) { in testFuzzyInfiniteVersusInfiniteWithFiniteTolerance()
572 assertTrue(DoubleMath.fuzzyEquals(inf, inf, tolerance)); in testFuzzyInfiniteVersusInfiniteWithFiniteTolerance()
573 assertFalse(DoubleMath.fuzzyEquals(inf, -inf, tolerance)); in testFuzzyInfiniteVersusInfiniteWithFiniteTolerance()
588 for (double tolerance : TOLERANCE_CANDIDATES) { in testFuzzyEqualsOneNaN()
[all …]
/external/guava/guava-gwt/src-super/com/google/common/math/super/com/google/common/math/
DDoubleMath.java136 public static boolean fuzzyEquals(double a, double b, double tolerance) { in fuzzyEquals() argument
137 MathPreconditions.checkNonNegative("tolerance", tolerance); in fuzzyEquals()
139 Math.copySign(a - b, 1.0) <= tolerance in fuzzyEquals()
159 public static int fuzzyCompare(double a, double b, double tolerance) { in fuzzyCompare() argument
160 if (fuzzyEquals(a, b, tolerance)) { in fuzzyCompare()
/external/protobuf/src/google/protobuf/util/
Dfield_comparator.cc184 Tolerance* tolerance = FindOrNull(map_tolerance_, &field); in CompareDoubleOrFloat() local
185 if (tolerance == NULL && has_default_tolerance_) { in CompareDoubleOrFloat()
186 tolerance = &default_tolerance_; in CompareDoubleOrFloat()
188 if (tolerance == NULL) { in CompareDoubleOrFloat()
195 value_1, value_2, static_cast<T>(tolerance->fraction), in CompareDoubleOrFloat()
196 static_cast<T>(tolerance->margin)); in CompareDoubleOrFloat()
/external/droiddriver/src/io/appium/droiddriver/helpers/
DBaseDroidDriverTest.java232 int tolerance = 1; in runTest() local
234 tolerance = method.getAnnotation(FlakyTest.class).tolerance(); in runTest()
237 for (int runCount = 0; runCount < tolerance; runCount++) { in runTest()
239 Logs.logfmt(Log.INFO, "Running %s round %d of %d attempts", fName, runCount + 1, tolerance); in runTest()
251 if (shouldSkipRemainingTests(exception) || runCount >= tolerance - 1) { in runTest()
/external/skqp/tests/
DColorMatrixTest.cpp21 SkColor expected, SkColor actual, int tolerance) { in assert_color() argument
22 REPORTER_ASSERT(reporter, abs((int)(SkColorGetA(expected) - SkColorGetA(actual))) <= tolerance); in assert_color()
23 REPORTER_ASSERT(reporter, abs((int)(SkColorGetR(expected) - SkColorGetR(actual))) <= tolerance); in assert_color()
24 REPORTER_ASSERT(reporter, abs((int)(SkColorGetG(expected) - SkColorGetG(actual))) <= tolerance); in assert_color()
25 REPORTER_ASSERT(reporter, abs((int)(SkColorGetB(expected) - SkColorGetB(actual))) <= tolerance); in assert_color()
DEncodeTest.cpp97 static inline bool almost_equals(SkPMColor a, SkPMColor b, int tolerance) { in almost_equals() argument
98 if (SkTAbs((int)SkGetPackedR32(a) - (int)SkGetPackedR32(b)) > tolerance) { in almost_equals()
102 if (SkTAbs((int)SkGetPackedG32(a) - (int)SkGetPackedG32(b)) > tolerance) { in almost_equals()
106 if (SkTAbs((int)SkGetPackedB32(a) - (int)SkGetPackedB32(b)) > tolerance) { in almost_equals()
110 if (SkTAbs((int)SkGetPackedA32(a) - (int)SkGetPackedA32(b)) > tolerance) { in almost_equals()
117 static inline bool almost_equals(const SkBitmap& a, const SkBitmap& b, int tolerance) { in almost_equals() argument
125 if (!almost_equals(*a.getAddr32(x, y), *b.getAddr32(x, y), tolerance)) { in almost_equals()
/external/skia/tests/
DColorMatrixTest.cpp21 SkColor expected, SkColor actual, int tolerance) { in assert_color() argument
22 REPORTER_ASSERT(reporter, abs((int)(SkColorGetA(expected) - SkColorGetA(actual))) <= tolerance); in assert_color()
23 REPORTER_ASSERT(reporter, abs((int)(SkColorGetR(expected) - SkColorGetR(actual))) <= tolerance); in assert_color()
24 REPORTER_ASSERT(reporter, abs((int)(SkColorGetG(expected) - SkColorGetG(actual))) <= tolerance); in assert_color()
25 REPORTER_ASSERT(reporter, abs((int)(SkColorGetB(expected) - SkColorGetB(actual))) <= tolerance); in assert_color()
/external/skia/src/gpu/
DGrDistanceFieldGenFromVector.cpp151 double tolerance = 0.0, in between_closed_open() argument
153 SkASSERT(tolerance >= 0.0); in between_closed_open()
154 double tolB = tolerance; in between_closed_open()
155 double tolC = tolerance; in between_closed_open()
165 tolB = tolerance / sqrt(4.0 * b * b + 1.0); in between_closed_open()
166 tolC = tolerance / sqrt(4.0 * c * c + 1.0); in between_closed_open()
173 double tolerance = 0.0, in between_closed() argument
175 SkASSERT(tolerance >= 0.0); in between_closed()
176 double tolB = tolerance; in between_closed()
177 double tolC = tolerance; in between_closed()
[all …]
/external/skqp/src/gpu/
DGrDistanceFieldGenFromVector.cpp151 double tolerance = 0.0, in between_closed_open() argument
153 SkASSERT(tolerance >= 0.0); in between_closed_open()
154 double tolB = tolerance; in between_closed_open()
155 double tolC = tolerance; in between_closed_open()
165 tolB = tolerance / sqrt(4.0 * b * b + 1.0); in between_closed_open()
166 tolC = tolerance / sqrt(4.0 * c * c + 1.0); in between_closed_open()
173 double tolerance = 0.0, in between_closed() argument
175 SkASSERT(tolerance >= 0.0); in between_closed()
176 double tolB = tolerance; in between_closed()
177 double tolC = tolerance; in between_closed()
[all …]
/external/apache-commons-math/src/main/java/org/apache/commons/math/analysis/solvers/
DBrentSolver.java331 double tolerance = in solve() local
333 if (FastMath.abs(dx) <= tolerance) { in solve()
337 if ((FastMath.abs(oldDelta) < tolerance) || in solve()
365 if (2.0 * p >= 1.5 * dx * p1 - FastMath.abs(tolerance * p1) || in solve()
381 if (FastMath.abs(delta) > tolerance) { in solve()
384 x1 = x1 + 0.5 * tolerance; in solve()
386 x1 = x1 - 0.5 * tolerance; in solve()
/external/skia/include/core/
DSkScalar.h157 SkScalar tolerance = SK_ScalarNearlyZero) {
158 SkASSERT(tolerance >= 0);
159 return SkScalarAbs(x) <= tolerance;
163 SkScalar tolerance = SK_ScalarNearlyZero) {
164 SkASSERT(tolerance >= 0);
165 return SkScalarAbs(x-y) <= tolerance;
/external/skqp/include/core/
DSkScalar.h157 SkScalar tolerance = SK_ScalarNearlyZero) {
158 SkASSERT(tolerance >= 0);
159 return SkScalarAbs(x) <= tolerance;
163 SkScalar tolerance = SK_ScalarNearlyZero) {
164 SkASSERT(tolerance >= 0);
165 return SkScalarAbs(x-y) <= tolerance;
/external/deqp/external/openglcts/modules/common/
DglcTextureRepeatModeTests.cpp514 bool isEqual(const GLubyte* color1, const GLubyte* color2, GLubyte tolerance) const;
576 …deForInternalFormat::isEqual(const GLubyte* color1, const GLubyte* color2, GLubyte tolerance) const in isEqual()
580 if (de::abs((int)color1[i] - (int)color2[i]) > tolerance) in isEqual()
849 const GLubyte tolerance = 0; in verifyRepeat() local
872 if (!isEqual(buf, red, tolerance)) in verifyRepeat()
879 if (!isEqual(buf, green, tolerance)) in verifyRepeat()
892 if (!isEqual(buf, blue, tolerance)) in verifyRepeat()
899 if (!isEqual(buf, white, tolerance)) in verifyRepeat()
933 const GLubyte tolerance = 0; in verifyMirroredRepeat() local
962 if (!isEqual(buf, white, tolerance)) in verifyMirroredRepeat()
[all …]
/external/autotest/server/site_tests/firmware_TypeCCharging/
Dfirmware_TypeCCharging.py55 tolerance = self.VBUS_TOLERANCE * expected_vbus_voltage
61 if math.fabs(expected_vbus_voltage - vbus_voltage) > tolerance:
64 (vbus_voltage, expected_vbus_voltage, tolerance))
/external/libcxx/test/libcxx/numerics/complex.number/
D__sqr.pass.cpp23 const T tolerance = std::is_same<T, float>::value ? 1.e-6 : 1.e-14; in test() local
51 assert(std::abs(actual.real() - test.expected.real()) < tolerance); in test()
52 assert(std::abs(actual.imag() - test.expected.imag()) < tolerance); in test()
/external/guava/guava/src/com/google/common/math/
DDoubleMath.java351 public static boolean fuzzyEquals(double a, double b, double tolerance) { in fuzzyEquals() argument
352 MathPreconditions.checkNonNegative("tolerance", tolerance); in fuzzyEquals()
354 Math.copySign(a - b, 1.0) <= tolerance in fuzzyEquals()
374 public static int fuzzyCompare(double a, double b, double tolerance) { in fuzzyCompare() argument
375 if (fuzzyEquals(a, b, tolerance)) { in fuzzyCompare()
/external/libxcam/xcore/base/
Dxcam_defs.h86 #define XCAM_DOUBLE_EQUAL(a, b, tolerance) \ argument
87 (((a) >= ((b) - (tolerance))) && ((a) <= ((b) + (tolerance))))

1234567