/external/tensorflow/tensorflow/core/ops/ |
D | math_grad_test.cc | 439 auto x = test::AsTensor<float>({-3.f}); in TEST_F() 440 auto dx = test::AsTensor<float>({3.f}); in TEST_F() 447 auto x = test::AsTensor<float>({-3.f, -2.f, -1.f, 1.f, 2.f, 3.f}, in TEST_F() 450 auto dx = test::AsTensor<float>( in TEST_F() 457 auto x = test::AsTensor<float>({-3.f, -2.f, -1.f, 1.f, 2.f, 3.f}, in TEST_F() 460 auto dx = test::AsTensor<float>( in TEST_F() 467 auto x = test::AsTensor<float>({-3.f, -2.f, -1.f, 1.f, 2.f, 3.f}, in TEST_F() 470 auto dx = test::AsTensor<float>( in TEST_F() 477 auto x = test::AsTensor<float>({-3.f, -2.f, -1.f, 1.f, 2.f, 3.f}, in TEST_F() 480 auto dx = test::AsTensor<float>( in TEST_F() [all …]
|
D | array_grad_test.cc | 72 test::AsTensor<float>({0., 1., 2., 3., 4., 5.}, {2, 3})); in TEST() 74 test::AsTensor<float>({6., 7., 8., 9., 10., 11.}, {2, 3})); in TEST() 112 test::ExpectClose(dx[0], test::AsTensor<float>({0., 1., 2., 3., 4., 5., 100., in TEST() 178 test::AsTensor<float>({0., 1., 2., 3., 4., 5., 6., 7., 8., 9., in TEST() 182 test::ExpectClose(dx[2], test::AsTensor<float>({15., 16., 17., 18., 19., 35., in TEST() 191 test::AsTensor<float>({0., 1., 2., 3., 4., 5., 6., 7., 8., 9., in TEST() 195 test::ExpectClose(dx[1], test::AsTensor<float>({15., 16., 17., 18., 19., 35., in TEST() 204 test::AsTensor<float>({0., 1., 2., 3., 4., 5., 6., 7., 8., 9., in TEST() 208 test::ExpectClose(dx[1], test::AsTensor<float>({15., 16., 17., 18., 19., 35., in TEST() 281 auto expected_dx = test::AsTensor<float>( in TEST() [all …]
|
D | array_ops_test.cc | 315 Tensor in_t = test::AsTensor<int32>({1, 2, 3, 4}); in TEST() 681 dim_t = test::AsTensor<int32>(dims); in TEST() 687 dim_t = test::AsTensor<int32>(dims); in TEST() 903 Tensor new_shape = test::AsTensor<int32>({1, 2, 3}); in TEST() 915 new_shape = test::AsTensor<int32>({-1}); in TEST() 920 new_shape = test::AsTensor<int32>({2, -1}); in TEST() 927 new_shape = test::AsTensor<int32>({-1, -1, 2}); in TEST() 932 new_shape = test::AsTensor<int32>({-1, 2, 3}); in TEST() 936 new_shape = test::AsTensor<int32>({}); in TEST() 943 new_shape = test::AsTensor<int32>({-1}); in TEST() [all …]
|
D | spectral_ops_test.cc | 75 Tensor fft_length = test::AsTensor<int32>({10}); in TEST() 89 fft_length = test::AsTensor<int32>({11}); in TEST() 100 fft_length = test::AsTensor<int32>({12}); in TEST() 135 Tensor fft_length = test::AsTensor<int32>({9, 10}); in TEST() 149 fft_length = test::AsTensor<int32>({10, 11}); in TEST() 160 fft_length = test::AsTensor<int32>({11, 12}); in TEST() 195 Tensor fft_length = test::AsTensor<int32>({10, 11, 12}); in TEST() 209 fft_length = test::AsTensor<int32>({11, 12, 13}); in TEST() 220 fft_length = test::AsTensor<int32>({12, 13, 14}); in TEST()
|
D | image_ops_test.cc | 48 Tensor size_tensor = test::AsTensor<int32>({20, 30}); in TEST() 233 Tensor size_tensor = test::AsTensor<int32>({20, 30}); in TEST() 261 Tensor size_tensor = test::AsTensor<int32>({20, 30}); in TEST() 287 Tensor size_tensor = test::AsTensor<int32>({20, 30}); in TEST() 303 Tensor image_size = test::AsTensor<int32>({10, 20, 30, 40}); in TEST() 321 Tensor size = test::AsTensor<int64>({10, 20}); in TEST() 346 const Tensor size_tensor = test::AsTensor<int32>({20, 30}); in TEST()
|
D | random_ops_test.cc | 36 num_samples = test::AsTensor<int32>({1, 2, 3}); in TEST() 48 Tensor shape = test::AsTensor<int32>({1, 2, 3}); in TEST() 63 Tensor shape = test::AsTensor<int32>({1, 2, 3}); in TEST()
|
/external/tensorflow/tensorflow/core/kernels/ |
D | ragged_range_op_test.cc | 59 test::AsTensor<int64>({0, 4, 6, 6, 10})); in TEST_F() 62 test::AsTensor<int>({0, 2, 4, 6, 5, 6, 5, 4, 3, 2})); in TEST_F() 74 test::AsTensor<int64>({0, 4, 6, 6, 10})); in TEST_F() 77 test::AsTensor<float>({0, 2, 4, 6, 5, 6, 5, 4, 3, 2}), 0.1); in TEST_F() 89 test::AsTensor<int64>({0, 8, 10, 10})); in TEST_F() 92 test::AsTensor<int>({0, 1, 2, 3, 4, 5, 6, 7, 5, 6})); in TEST_F() 104 test::AsTensor<int64>({0, 3, 3, 5})); in TEST_F() 106 test::AsTensor<int>({0, 1, 2, 0, 1})); in TEST_F() 118 test::AsTensor<int64>({0, 4, 7, 10})); in TEST_F() 121 test::AsTensor<int>({0, 3, 6, 9, 0, 4, 8, 0, 5, 10})); in TEST_F() [all …]
|
D | ragged_tensor_to_sparse_kernel_test.cc | 68 test::AsTensor<int64>({0, 0, 0, 1, 0, 2, 2, 0, 2, 1, 3, 0}, {6, 2})); in TEST_F() 70 test::AsTensor<int>({1, 2, 3, 4, 5, 6})); in TEST_F() 72 test::AsTensor<int64>({4, 3})); in TEST_F() 84 test::AsTensor<int64>({1, 0, 1, 1, 1, 2, 1, 3, 3, 0, 3, 1}, {6, 2})); in TEST_F() 86 test::AsTensor<int>({1, 2, 3, 4, 5, 6})); in TEST_F() 88 test::AsTensor<int64>({5, 4})); in TEST_F() 104 test::AsTensor<int64>(expected_splits_12_3, {12, 3})); in TEST_F() 106 test::AsTensor<int>(expected_values)); in TEST_F() 108 test::AsTensor<int64>({4, 3, 2})); in TEST_F() 130 test::AsTensor<int>(expected_values)); in TEST_F() [all …]
|
D | ragged_gather_op_test.cc | 80 test::AsTensor<int64>({0, 4, 4, 7, 9})); in TEST_F() 83 test::AsTensor<float>({.4, .5, .6, .7, .1, .2, .3, .8, .9}), 0.1); in TEST_F() 102 test::AsTensor<int64>({0, 0, 2, 3, 3, 5})); in TEST_F() 104 test::AsTensor<int64>({0, 2, 3, 3, 5, 8})); in TEST_F() 106 *GetOutput(2), test::AsTensor<float>({.1, .2, .3, .4, .5, .6, .7, .8}), in TEST_F() 129 test::AsTensor<int64>({0, 0, 2, 3, 3})); in TEST_F() 131 test::AsTensor<int64>({0, 3, 4, 4})); in TEST_F() 134 test::AsTensor<int32>({1, 2, 3, 4, 5, 6, 7, 8}, TensorShape({4, 2}))); in TEST_F() 153 test::AsTensor<int64>({0, 2, 4})); in TEST_F() 155 test::AsTensor<int64>({0, 4, 4, 7, 9})); in TEST_F() [all …]
|
D | ragged_tensor_to_tensor_op_test.cc | 111 test::AsTensor<float>({.1, .2, .3, 1.5, 1.5, 1.5, 1.5, 1.5, .4, .5, .6, in TEST_F() 132 test::AsTensor<float>({.1, .2, .3, 1.5, 1.5, 1.5, 1.5, 1.5, .4, .5, .6, in TEST_F() 169 test::AsTensor<float>({1.5, 1.5, 1.5, 1.5, 1.5, 1.5, .1, .2, 1.5, .3, in TEST_F() 205 test::AsTensor<float>({1.5, 1.5, 1.5, 1.5, 1.5, 1.5, .1, .2, 1.5, .3, in TEST_F() 237 *GetOutput(0), test::AsTensor<int64>( in TEST_F() 282 test::AsTensor<int32>( in TEST_F() 328 test::AsTensor<int32>( in TEST_F() 350 test::AsTensor<float>({.1, .2, .3, 1.5, 1.5, // in TEST_F() 375 test::AsTensor<float>( in TEST_F() 401 test::AsTensor<float>( in TEST_F() [all …]
|
D | spectrogram_op_test.cc | 67 test::AsTensor<float>({0, 1, 2, 1, 0}, TensorShape({1, 1, 5})), 1e-3); in TEST() 101 test::AsTensor<float>({0, 1, 4, 1, 0}, TensorShape({1, 1, 5})), 1e-3); in TEST() 139 test::AsTensor<float>({0, 1, 2, 1, 0}, TensorShape({1, 5})), 1e-3); in TEST()
|
D | strided_slice_op_test.cc | 100 Tensor begin = test::AsTensor<int32>({10, 10}); in BM_ValidateStridedSliceOp() 101 Tensor end = test::AsTensor<int32>({10 + kDim, 10 + size}); in BM_ValidateStridedSliceOp() 102 Tensor strides = test::AsTensor<int32>({1, 1}); in BM_ValidateStridedSliceOp()
|
/external/tensorflow/tensorflow/core/framework/ |
D | dataset_test.cc | 68 return {test::AsTensor<int32>({1, 2, 3, 4, 5}), in tensor_tf_int_32s() 69 test::AsTensor<int32>({1, 2, 3, 4})}; in tensor_tf_int_32s() 73 return {test::AsTensor<int64>({1, 2, 3, 4, 5}), in tensor_tf_int_64s() 74 test::AsTensor<int64>({10, 12})}; in tensor_tf_int_64s() 78 return {test::AsTensor<float>({1.0, 2.0, 3.0, 4.0})}; in tensor_tf_float_s() 82 return {test::AsTensor<double>({100.0}), test::AsTensor<double>({200.0}), in tensor_tf_double_s() 83 test::AsTensor<double>({400.0}), test::AsTensor<double>({800.0})}; in tensor_tf_double_s() 87 std::vector<Tensor> tensor_strs() { return {test::AsTensor<tstring>({str})}; } in tensor_strs()
|
D | batch_util_test.cc | 49 auto src = test::AsTensor<float>({0, 1, 2, 3, 4, 5, 6, 7, 8, 9}, in TEST() 56 test::AsTensor<float>({2, 3, 4, 5, 6, 7}, TensorShape({3, 2, 1})), in TEST()
|
D | tensor_testutil.h | 39 Tensor AsTensor(gtl::ArraySlice<T> vals) { in AsTensor() function 47 Tensor AsTensor(gtl::ArraySlice<T> vals, const TensorShape& shape) { in AsTensor() function 49 CHECK(ret.CopyFrom(AsTensor(vals), shape)); in AsTensor()
|
D | extension_type_variant_test.cc | 49 components.push_back(test::AsTensor<int32>(values)); in Make2DRaggedTensor() 50 components.push_back(test::AsTensor<int64>(splits)); in Make2DRaggedTensor()
|
/external/tensorflow/tensorflow/core/kernels/sparse/ |
D | kernels_test.cc | 31 test::AsTensor<int64>({0, 0, 2, 3, 2, 4, 3, 0}, TensorShape({4, 2})); in TEST() 34 auto csr_row_ptr = test::AsTensor<int32>({0, 0, 0, 0, 0}); in TEST() 42 test::ExpectTensorEqual<int32>(batch_ptr, test::AsTensor<int32>({0, 4})); in TEST() 44 test::AsTensor<int32>({0, 1, 1, 3, 4})); in TEST() 46 test::AsTensor<int32>({0, 3, 4, 0})); in TEST() 51 const auto indices = test::AsTensor<int64>({0, 0, 0, // in TEST() 68 test::AsTensor<int32>({0, 2, 2, 3})); in TEST() 70 test::AsTensor<int32>({0, 1, 1, 2, // in TEST() 73 test::ExpectTensorEqual<int32>(csr_col_ind, test::AsTensor<int32>({0, 3, 1})); in TEST()
|
/external/tensorflow/tensorflow/cc/client/ |
D | client_session_test.cc | 84 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({1, 1}, {1, 2})); in TEST() 96 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({42}, {})); in TEST() 107 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({3, 3}, {2})); in TEST() 112 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({31, 42}, {2})); in TEST() 126 test::AsTensor<int>({4, 6}, {2})); in TEST() 132 test::AsTensor<int>({3, 8}, {2})); in TEST() 138 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({-1, 2}, {2})); in TEST() 167 test::AsTensor<int>({4, 6}, {2})); in TEST() 174 test::AsTensor<int>({3, 8}, {2})); in TEST() 181 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({-1, 2}, {2})); in TEST() [all …]
|
/external/tensorflow/tensorflow/core/common_runtime/ |
D | process_function_library_runtime_test.cc | 386 auto x = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() 390 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({2, 4, 6, 8})); in TEST_F() 403 y, test::AsTensor<tstring>({"/job:a/replica:0/task:0/device:CPU:0"}, in TEST_F() 412 auto x = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() 421 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({2, 4, 6, 8})); in TEST_F() 424 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({4, 8, 12, 16})); in TEST_F() 437 y, test::AsTensor<tstring>({"/job:a/replica:0/task:0/device:CPU:1"}, in TEST_F() 441 y, test::AsTensor<tstring>({"/job:a/replica:0/task:0/device:CPU:1"}, in TEST_F() 455 y, test::AsTensor<tstring>({"/job:a/replica:0/task:0/device:CPU:0"}, in TEST_F() 461 y, test::AsTensor<tstring>({"/job:a/replica:0/task:0/device:CPU:1"}, in TEST_F() [all …]
|
D | function_test.cc | 130 auto x = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() 133 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({2, 4, 6, 8})); in TEST_F() 138 auto w = test::AsTensor<float>({1., 2., 3., 4.}, {2, 2}); in TEST_F() 139 auto x = test::AsTensor<float>({1., 3., 2., 4.}, {2, 2}); in TEST_F() 140 auto b = test::AsTensor<float>({0.5, 2.5}, {2}); in TEST_F() 144 y, test::AsTensor<float>({5.5, 13.5, 11.5, 27.5}, {2, 2})); in TEST_F() 386 auto x = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() 390 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({2, 4, 6, 8})); in TEST_F() 393 test::ExpectTensorEqual<float>(y, test::AsTensor<float>({2, 4, 6, 8})); in TEST_F() 429 auto x = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() [all …]
|
/external/tensorflow/tensorflow/cc/framework/ |
D | cc_ops_test.cc | 54 test::ExpectTensorEqual<int>(out, test::AsTensor<int>({42}, {1, 1})); in TEST() 63 test::ExpectTensorEqual<int>(out, test::AsTensor<int>({42}, {1, 1})); in TEST() 73 test::ExpectTensorEqual<int>(out, test::AsTensor<int>({1, 2}, {2, 1})); in TEST() 84 test::ExpectClose(out, test::AsTensor<float>({-0.3, 34.2}, {1, 2})); in TEST() 92 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({1, 2, 4, 3})); in TEST() 94 test::AsTensor<int>({0, 1, 1, 2, 3, 1})); in TEST() 116 out, test::AsTensor<float>({0.98058069, -0.19611613}, {2, 1}), 1e-5); in TEST() 142 test::ExpectTensorNear<float>(out[0], test::AsTensor<float>({42.0f}, {}), in TEST() 150 test::ExpectTensorNear<float>(out[0], test::AsTensor<float>({1.0f}, {}), in TEST() 152 test::ExpectTensorEqual<bool>(out[1], test::AsTensor<bool>({false}, {})); in TEST() [all …]
|
D | gradients_test.cc | 341 test::ExpectTensorEqual<int>(outputs[0], test::AsTensor<int>({40}, {1, 1})); in TEST_F() 342 test::ExpectTensorEqual<int>(outputs[1], test::AsTensor<int>({20}, {1, 1})); in TEST_F() 369 test::AsTensor<int>({40, 41, 42, 43, 44, 45, 46, 47}, {4, 2})); in TEST_F() 372 test::AsTensor<int>({50, 51, 52, 53, 55, 55, 56, 57}, {4, 2})); in TEST_F() 375 test::AsTensor<int>({60, 61, 62, 63, 66, 66, 66, 67}, {4, 2})); in TEST_F() 404 outputs[0], test::AsTensor<double>({2.5, 3.5, 4.5}, {3, 1}), 1e-5); in TEST_F() 440 outputs[0], test::AsTensor<double>({17.5, 24.7, 26.8}, {3, 1}), 1e-5); in TEST_F() 537 test::ExpectTensorEqual<int>(in_grad[i], test::AsTensor<int>({i}, {1})); in TEST_F() 592 test::AsTensor<int>({15, 18, 21, 24}, {2, 2})); in TEST_F() 597 test::AsTensor<int>({14, 16, 18, 20}, {2, 2})); in TEST_F() [all …]
|
/external/tensorflow/tensorflow/cc/gradients/ |
D | nn_grad_test.cc | 135 test::AsTensor<float>({-0.9f, -0.7f, -0.5f, -0.3f, -0.1f, 0.1f, 0.3f, in TEST_F() 146 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 158 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 170 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 181 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 183 Tensor features = test::AsTensor<float>( in TEST_F() 194 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 204 Tensor x_init_value = test::AsTensor<float>( in TEST_F() 230 Tensor filter = test::AsTensor<float>({0.5f}, {1, 1, 1, 1}); in TEST_F() 254 Tensor ksize = test::AsTensor<int>({1, 2, 2, 1}, {4}); in TEST_F() [all …]
|
/external/tensorflow/tensorflow/compiler/tf2xla/ |
D | literal_util_test.cc | 42 test::AsTensor<int64>(int64_values)); in TEST() 66 test::AsTensor<int_type>(int_values)); in TYPED_TEST() 74 test::AsTensor<qint_type>(qint_values)); in TYPED_TEST()
|
/external/tensorflow/tensorflow/core/distributed_runtime/ |
D | cluster_function_library_runtime_test.cc | 387 auto x = test::AsTensor<int32>({1, 2, 3, 4}); in TEST_F() 390 test::ExpectTensorEqual<int32>(y, test::AsTensor<int32>({2, 4, 6, 8})); in TEST_F() 401 auto x1 = test::AsTensor<float>({1, 2, 3, 4}); in TEST_F() 402 auto x2 = test::AsTensor<float>({4, 3, 2, 1}); in TEST_F() 405 test::ExpectTensorEqual<float>(y1, test::AsTensor<float>({4, 3, 2, 1})); in TEST_F() 406 test::ExpectTensorEqual<float>(y2, test::AsTensor<float>({1, 2, 3, 4})); in TEST_F()
|