/external/XNNPACK/eval/ |
D | f32-roundd.cc | 32 const uint32_t reference_output = fp32_to_bits(std::floor(inputs[0])); in TEST() local 33 ASSERT_EQ(reference_output, fp32_to_bits(outputs[0])) in TEST() 35 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 44 const uint32_t reference_output = fp32_to_bits(std::floor(inputs[0])); in TEST() local 45 ASSERT_EQ(reference_output, fp32_to_bits(outputs[0])) in TEST() 47 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 60 const uint32_t reference_output = fp32_to_bits(std::floor(inputs[i])); in TEST() local 61 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 63 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 78 const uint32_t reference_output = fp32_to_bits(std::floor(inputs[i])); in TEST() local [all …]
|
D | f32-roundu.cc | 32 const uint32_t reference_output = fp32_to_bits(std::ceil(inputs[0])); in TEST() local 33 ASSERT_EQ(reference_output, fp32_to_bits(outputs[0])) in TEST() 35 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 44 const uint32_t reference_output = fp32_to_bits(std::ceil(inputs[0])); in TEST() local 45 ASSERT_EQ(reference_output, fp32_to_bits(outputs[0])) in TEST() 47 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 60 const uint32_t reference_output = fp32_to_bits(std::ceil(inputs[i])); in TEST() local 61 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 63 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 78 const uint32_t reference_output = fp32_to_bits(std::ceil(inputs[i])); in TEST() local [all …]
|
D | f32-roundne.cc | 36 const uint32_t reference_output = fp32_to_bits(std::nearbyint(inputs[i])); in TEST() local 37 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 39 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 54 const uint32_t reference_output = fp32_to_bits(std::nearbyint(inputs[i])); in TEST() local 55 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 57 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 72 const uint32_t reference_output = fp32_to_bits(std::nearbyint(inputs[i])); in TEST() local 73 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 75 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 90 const uint32_t reference_output = fp32_to_bits(std::nearbyint(inputs[i])); in TEST() local [all …]
|
D | f32-roundz.cc | 36 const uint32_t reference_output = fp32_to_bits(std::trunc(inputs[i])); in TEST() local 37 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 39 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 54 const uint32_t reference_output = fp32_to_bits(std::trunc(inputs[i])); in TEST() local 55 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 57 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 72 const uint32_t reference_output = fp32_to_bits(std::trunc(inputs[i])); in TEST() local 73 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 75 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 90 const uint32_t reference_output = fp32_to_bits(std::trunc(inputs[i])); in TEST() local [all …]
|
D | f32-exp.cc | 36 const float reference_output = 1.0f; in TEST() local 37 ASSERT_EQ(reference_output, outputs[0]) in TEST() 39 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 50 const float reference_output = 1.0f; in TEST() local 51 ASSERT_EQ(reference_output, outputs[0]) in TEST() 53 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 68 const uint32_t reference_output = UINT32_C(0x00000000); in TEST() local 69 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 71 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 88 const uint32_t reference_output = UINT32_C(0x7F800000); in TEST() local [all …]
|
D | f32-expminus.cc | 36 const float reference_output = 1.0f; in TEST() local 37 ASSERT_EQ(reference_output, outputs[0]) in TEST() 39 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 50 const float reference_output = 1.0f; in TEST() local 51 ASSERT_EQ(reference_output, outputs[0]) in TEST() 53 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 68 const uint32_t reference_output = UINT32_C(0x00000000); in TEST() local 69 ASSERT_EQ(reference_output, fp32_to_bits(outputs[i])) in TEST() 71 << ", reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << reference_output in TEST() 123 const float reference_output = 1.0f; in TEST() local [all …]
|
D | f32-expm1minus.cc | 36 const float reference_output = 0.0f; in TEST() local 37 ASSERT_EQ(reference_output, outputs[0]) in TEST() 39 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 54 const float reference_output = -1.0f; in TEST() local 55 ASSERT_EQ(reference_output, outputs[i]) in TEST() 57 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 109 const float reference_output = 0.0f; in TEST() local 110 ASSERT_EQ(reference_output, outputs[0]) in TEST() 112 … reference = 0x" << std::hex << std::setw(8) << std::setfill('0') << fp32_to_bits(reference_output) in TEST() 127 const float reference_output = -1.0f; in TEST() local [all …]
|
/external/tensorflow/tensorflow/lite/delegates/hexagon/builders/tests/ |
D | matmul_test.cc | 130 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST_P() local 135 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST_P() 158 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST_P() local 163 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST_P() 185 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST_P() local 190 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST_P() 212 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST_P() local 217 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST_P() 240 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST_P() local 245 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST_P() [all …]
|
D | slice_test.cc | 76 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 81 ElementsAreArray(ArrayFloatNear(reference_output, 0.1))); in TEST() 91 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 96 ElementsAreArray(ArrayFloatNear(reference_output, 0.1))); in TEST() 107 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 112 ElementsAreArray(ArrayFloatNear(reference_output, 0.1))); in TEST() 123 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 128 ElementsAreArray(ArrayFloatNear(reference_output, 0.1))); in TEST() 139 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 144 ElementsAreArray(ArrayFloatNear(reference_output, 0.1))); in TEST() [all …]
|
D | arithmetic_test.cc | 114 auto reference_output = m.GetDequantizedOutput<integer_dtype>(); in QuantizedTestsNoActivation() local 118 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))) in QuantizedTestsNoActivation() 143 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 147 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))); in TEST() 159 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 163 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))); in TEST() 175 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST() local 179 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))); in TEST()
|
D | conv_test.cc | 421 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 425 ElementsAreArray(ArrayFloatNear(reference_output, 1e-5))); in TEST() 461 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 465 ElementsAreArray(ArrayFloatNear(reference_output, 1e-5))); in TEST() 503 auto reference_output = m.GetDequantizedOutput<uint8_t>(); in TEST() local 507 ElementsAreArray(ArrayFloatNear(reference_output, 1e-5))); in TEST() 591 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST() local 596 ElementsAreArray(ArrayFloatNear(reference_output, 1e-2))); in TEST()
|
D | reduce_test.cc | 60 auto reference_output = m.GetDequantizedOutput<input_type>(); in TestMeanImpl() local 65 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))); in TestMeanImpl() 84 auto reference_output = m.GetDequantizedOutput<input_type>(); in TestMeanKeppDimsImpl() local 89 ElementsAreArray(ArrayFloatNear(reference_output, kQuantizedTolerance))); in TestMeanKeppDimsImpl()
|
D | min_max_builder_test.cc | 90 const auto reference_output = m->GetOutput(); in TestModel() local 94 EXPECT_THAT(m->GetOutput(), ElementsAreArray(reference_output)); in TestModel() 110 const auto reference_output = m->GetOutput(); in TestModelConstInput() local 114 EXPECT_THAT(m->GetOutput(), ElementsAreArray(reference_output)); in TestModelConstInput()
|
D | pool_test.cc | 109 auto reference_output = m.GetDequantizedOutput<int8_t>(); in TEST() local 113 ElementsAreArray(ArrayFloatNear(reference_output))); in TEST()
|
D | concat_test.cc | 232 std::vector<float> reference_output = m0.GetDequantizedOutput<uint8_t>(); in TEST() local 236 ElementsAreArray(ArrayFloatNear(reference_output, in TEST()
|
/external/tensorflow/tensorflow/lite/kernels/internal/ |
D | log_quantized_test.cc | 71 const std::vector<int32>& reference_output, in CheckOutputData() argument 81 ASSERT_EQ(n, reference_output.size()); in CheckOutputData() 90 ASSERT_LE(std::abs(test_output[i] - reference_output[i]), in CheckOutputData() 98 << ", reference_output[i]=" << reference_output[i] << "=" in CheckOutputData() 99 << static_cast<double>(reference_output[i]) / in CheckOutputData() 101 << ", difference[i]=" << std::abs(reference_output[i] - test_output[i]) in CheckOutputData() 103 << static_cast<double>(std::abs(reference_output[i] - test_output[i])) / in CheckOutputData()
|
D | softmax_quantized_test.cc | 65 void CheckOutputData(const T* test_output, const T* reference_output, in CheckOutputData() argument 75 diff[i] = static_cast<int>(test_output[i]) - reference_output[i]; in CheckOutputData()
|
D | logsoftmax_quantized_test.cc | 101 void CheckOutputData(const T* test_output, const T* reference_output, in CheckOutputData() argument 111 diff[i] = static_cast<int>(test_output[i]) - reference_output[i]; in CheckOutputData()
|
/external/XNNPACK/test/ |
D | requantization-tester.h | 525 const uint8_t reference_output = in TestRandomCasesPrecise() local 527 ASSERT_EQ(uint32_t(reference_output), uint32_t(outputs[i])); in TestRandomCasesPrecise() 568 const int8_t reference_output = in TestRandomCasesPrecise() local 570 ASSERT_EQ(int32_t(reference_output), int32_t(outputs[i])); in TestRandomCasesPrecise() 611 const double reference_output = RequantizationTester::RequantizeApproximate( in TestRandomCasesApproximate() local 613 ASSERT_LE(std::abs(reference_output - double(outputs[i])), 0.55) in TestRandomCasesApproximate() 615 << ", reference output = " << reference_output; in TestRandomCasesApproximate() 656 const double reference_output = RequantizationTester::RequantizeApproximate( in TestRandomCasesApproximate() local 658 ASSERT_LE(std::abs(reference_output - double(outputs[i])), 0.55) in TestRandomCasesApproximate() 660 << ", reference output = " << reference_output; in TestRandomCasesApproximate()
|