Home
last modified time | relevance | path

Searched refs:CreateR0 (Results 1 – 25 of 121) sorted by relevance

12345

/external/tensorflow/tensorflow/compiler/xla/
Dliteral_util.cc128 return LiteralUtil::CreateR0<uint8>(0); in Zero()
130 return LiteralUtil::CreateR0<uint16>(0); in Zero()
132 return LiteralUtil::CreateR0<uint32>(0); in Zero()
134 return LiteralUtil::CreateR0<uint64>(0); in Zero()
136 return LiteralUtil::CreateR0<int8>(0); in Zero()
138 return LiteralUtil::CreateR0<int16>(0); in Zero()
140 return LiteralUtil::CreateR0<int32>(0); in Zero()
142 return LiteralUtil::CreateR0<int64>(0); in Zero()
144 return LiteralUtil::CreateR0<half>(static_cast<half>(0.0f)); in Zero()
146 return LiteralUtil::CreateR0<bfloat16>(static_cast<bfloat16>(0.0f)); in Zero()
[all …]
Dliteral_test.cc100 auto true_lit = LiteralUtil::CreateR0<bool>(true); in TEST_F()
103 auto false_lit = LiteralUtil::CreateR0<bool>(false); in TEST_F()
106 auto u32_lit = LiteralUtil::CreateR0<uint32>(42); in TEST_F()
109 auto s32_lit = LiteralUtil::CreateR0<int32>(-999); in TEST_F()
112 auto f32_lit = LiteralUtil::CreateR0<float>(3.14f); in TEST_F()
115 auto f16_lit = LiteralUtil::CreateR0<half>(static_cast<half>(0.5f)); in TEST_F()
118 auto c64_lit = LiteralUtil::CreateR0<complex64>({3.14f, 2.78f}); in TEST_F()
121 auto c128_lit = LiteralUtil::CreateR0<complex128>({3.14, 2.78}); in TEST_F()
124 auto bf16_lit = LiteralUtil::CreateR0<bfloat16>(static_cast<bfloat16>(0.5f)); in TEST_F()
129 LiteralUtil::CreateR0<bfloat16>(static_cast<bfloat16>(3.14f)); in TEST_F()
[all …]
/external/tensorflow/tensorflow/compiler/xla/tests/
Dliteral_test_util_test.cc36 LiteralUtil::CreateR0<int32>(42), in TEST()
37 LiteralUtil::CreateR0<int32>(64), in TEST()
44 LiteralUtil::CreateR0<complex64>({42.0, 64.0}), in TEST()
45 LiteralUtil::CreateR0<complex64>({64.0, 42.0}), in TEST()
52 LiteralUtil::CreateR0<complex128>({42.0, 64.0}), in TEST()
53 LiteralUtil::CreateR0<complex128>({64.0, 42.0}), in TEST()
60 LiteralUtil::CreateR0<complex64>({42.0, 64.0}), in TEST()
61 LiteralUtil::CreateR0<complex64>({64.0, 42.0}), in TEST()
64 LiteralUtil::CreateR0<complex64>({64.0, 42.0}), in TEST()
65 LiteralUtil::CreateR0<complex64>({42.0, 64.0}), in TEST()
[all …]
Dbuffer_donation_test.cc179 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int>(4))); in BuildWhileConditionComputation()
205 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int>(1))); in BuildWhileBodyComputation()
259 {LiteralUtil::CreateR0<int>(0), LiteralUtil::CreateR1<float>({1.1f})})); in TEST_F()
261 {LiteralUtil::CreateR0<int>(4), LiteralUtil::CreateR1<float>({5.5f})}); in TEST_F()
276 {LiteralUtil::CreateR0<int>(0), LiteralUtil::CreateR1<float>({1.1f})})); in TEST_F()
278 {LiteralUtil::CreateR0<int>(4), LiteralUtil::CreateR1<float>({5.5f})}); in TEST_F()
302 args.push_back(LiteralUtil::CreateR0<float>(0.1)); in TEST_F()
303 args.push_back(LiteralUtil::CreateR0<float>(0.2)); in TEST_F()
305 {LiteralUtil::CreateR0<float>(0.1), LiteralUtil::CreateR0<float>(0.2)}); in TEST_F()
333 args.push_back(LiteralUtil::CreateR0<float>(0.1)); in TEST_F()
[all …]
Dpad_test.cc97 AddParam(LiteralUtil::CreateR0<float>(0.1), &b), padding_config); in XLA_TEST_P()
112 AddParam(LiteralUtil::CreateR0<float>(0.1), &b), padding_config); in XLA_TEST_P()
127 AddParam(LiteralUtil::CreateR0<float>(0.1), &b), padding_config); in XLA_TEST_P()
135 AddParam(LiteralUtil::CreateR0<float>(1.5), &b), in XLA_TEST_P()
151 Pad(AddParam(*input, &b), AddParam(LiteralUtil::CreateR0<float>(1.5), &b), in TEST_P()
171 AddParam(LiteralUtil::CreateR0<float>(pad_value), &b), in TEST_P()
214 AddParam(LiteralUtil::CreateR0<float>(pad_value), &b), padding_config); in TEST_P()
260 AddParam(LiteralUtil::CreateR0<float>(pad_value), &b), padding_config); in XLA_TEST_P()
334 Pad(input, AddParam(LiteralUtil::CreateR0<float>(0.0f), &b), padding_config); in XLA_TEST_P()
356 Pad(input, AddParam(LiteralUtil::CreateR0<float>(3.14f), &b), padding_config); in XLA_TEST_P()
[all …]
Dtoken_hlo_test.cc78 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int32>(42))); in XLA_TEST_F()
187 auto arg = LiteralUtil::CreateR0<bool>(true); in XLA_TEST_F()
197 auto arg = LiteralUtil::CreateR0<bool>(false); in XLA_TEST_F()
225 auto p0 = LiteralUtil::CreateR0<float>(10.0); in XLA_TEST_F()
226 auto p1 = LiteralUtil::CreateR0<float>(3.0); in XLA_TEST_F()
227 auto expected = LiteralUtil::CreateR0<float>(-156.0); in XLA_TEST_F()
246 auto p0 = LiteralUtil::CreateR0<float>(10.0); in XLA_TEST_F()
247 auto expected = LiteralUtil::CreateR0<float>(420.0); in XLA_TEST_F()
Dtuple_test.cc55 {LiteralUtil::CreateR0<float>(constant_scalar), in XLA_TEST_F()
70 {LiteralUtil::CreateR0<float>(constant_scalar1), in XLA_TEST_F()
71 LiteralUtil::CreateR0<float>(constant_scalar2)}); in XLA_TEST_F()
92 {LiteralUtil::CreateR0<float>(constant_scalar), in XLA_TEST_F()
106 {LiteralUtil::CreateR0<float>(7.0), LiteralUtil::CreateR1<float>({})}); in XLA_TEST_F()
222 {LiteralUtil::CreateR0<bool>(direction), in XLA_TEST_F()
223 LiteralUtil::CreateR0<bool>(!direction)}); in XLA_TEST_F()
421 auto expected_s = LiteralUtil::CreateR0<float>(42.0); in XLA_TEST_F()
482 {LiteralUtil::CreateR0<complex64>({1, 2}), in XLA_TEST_F()
509 LiteralUtil::CreateR0<complex64>({123, 456})}); in XLA_TEST_F()
[all …]
Dmultioutput_fusion_test.cc72 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(8.0f))); in RunTest2D()
117 Literal literal_r0 = LiteralUtil::CreateR0<float>(-9.0f); in RunTest2D()
216 LiteralUtil::MakeTupleOwned(LiteralUtil::CreateR0<int32>(42)), in XLA_TEST_F()
217 LiteralUtil::CreateR0<float>(1.0)), in XLA_TEST_F()
218 LiteralUtil::MakeTupleOwned(LiteralUtil::CreateR0<float>(3.0), in XLA_TEST_F()
219 LiteralUtil::CreateR0<int32>(4))); in XLA_TEST_F()
222 LiteralUtil::MakeTupleOwned(LiteralUtil::CreateR0<int32>(42)), result)); in XLA_TEST_F()
Dcompilation_cache_test.cc52 LiteralUtil::CreateR0<float>(expected_result), result, error_spec_)); in ExecuteComputationR0F32()
90 client_->TransferToServer(LiteralUtil::CreateR0<float>(42.0f)) in XLA_TEST_F()
93 client_->TransferToServer(LiteralUtil::CreateR0<float>(123.0f)) in XLA_TEST_F()
96 client_->TransferToServer(LiteralUtil::CreateR0<float>(456.0f)) in XLA_TEST_F()
/external/tensorflow/tensorflow/compiler/tf2xla/lib/
Dutil.cc70 literal = xla::LiteralUtil::CreateR0<uint8>(value); in IntegerLiteral()
73 literal = xla::LiteralUtil::CreateR0<uint16>(value); in IntegerLiteral()
76 literal = xla::LiteralUtil::CreateR0<uint32>(value); in IntegerLiteral()
79 literal = xla::LiteralUtil::CreateR0<uint64>(value); in IntegerLiteral()
82 literal = xla::LiteralUtil::CreateR0<int8>(value); in IntegerLiteral()
85 literal = xla::LiteralUtil::CreateR0<int16>(value); in IntegerLiteral()
88 literal = xla::LiteralUtil::CreateR0<int32>(value); in IntegerLiteral()
91 literal = xla::LiteralUtil::CreateR0<int64>(value); in IntegerLiteral()
94 literal = xla::LiteralUtil::CreateR0<float>(value); in IntegerLiteral()
97 literal = xla::LiteralUtil::CreateR0<double>(value); in IntegerLiteral()
[all …]
/external/tensorflow/tensorflow/compiler/xla/service/cpu/tests/
Dcpu_infeed_test.cc61 TestInfeedRoundTrip(LiteralUtil::CreateR0<bool>(true)); in TEST_F()
102 LiteralUtil::CreateR0<bool>(false)})); in TEST_F()
254 LiteralUtil::CreateR0<bool>(true)}))); in TEST_F()
257 LiteralUtil::CreateR0<bool>(true)}))); in TEST_F()
260 LiteralUtil::CreateR0<bool>(true)}))); in TEST_F()
263 LiteralUtil::CreateR0<bool>(false)}))); in TEST_F()
279 LiteralUtil::CreateR0<bool>(true)}))); in TEST_F()
282 LiteralUtil::CreateR0<bool>(false)}))); in TEST_F()
285 LiteralUtil::CreateR0<bool>(true)}))); in TEST_F()
/external/tensorflow/tensorflow/compiler/xla/service/
Dtuple_points_to_analysis_test.cc128 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
130 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
181 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
183 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
188 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(3.0))); in TEST_F()
242 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
244 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
249 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(3.0))); in TEST_F()
273 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
290 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
[all …]
Dcall_inliner_test.cc50 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(24.0f))); in TEST_F()
52 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
89 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
103 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
129 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
153 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int32>(0))); in TEST_F()
160 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int32>(0))); in TEST_F()
166 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int32>(0))); in TEST_F()
191 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0))); in TEST_F()
Dhlo_alias_analysis_test.cc121 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
123 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
351 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
417 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
419 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
457 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
459 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
537 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
543 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_F()
545 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_F()
[all …]
Dhlo_computation_test.cc127 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
138 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
153 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
172 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
174 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
176 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
178 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
190 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
192 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
194 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
[all …]
Dhlo_cse_test.cc56 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
58 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
75 auto expected = LiteralUtil::CreateR0<float>(84.0); in TEST_F()
147 HloInstruction::CreateConstant(LiteralUtil::CreateR0<uint32>(42)))); in TEST_F()
149 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int32>(42)))); in TEST_F()
151 HloInstruction::CreateConstant(LiteralUtil::CreateR0<uint64>(42.0)))); in TEST_F()
153 HloInstruction::CreateConstant(LiteralUtil::CreateR0<int64>(42.0)))); in TEST_F()
155 HloInstruction::CreateConstant(LiteralUtil::CreateR0<double>(42.0)))); in TEST_F()
157 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f)))); in TEST_F()
160 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f)))); in TEST_F()
[all …]
Dhlo_dataflow_analysis_test.cc108 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_P()
110 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_P()
207 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_P()
209 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_P()
269 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_P()
271 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_P()
343 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_P()
345 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0))); in TEST_P()
411 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_P()
417 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0))); in TEST_P()
[all …]
Dhlo_dce_test.cc56 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
58 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(123.0f))); in TEST_F()
77 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
166 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
168 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(123.0f))); in TEST_F()
263 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(42.0f))); in TEST_F()
385 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0))), in TEST_F()
390 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0))); in TEST_F()
426 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0))), in TEST_F()
436 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0))), in TEST_F()
Ddynamic_padder_test.cc127 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0))); in TEST_F()
354 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0))); in TEST_F()
430 Literal dynamic_size = LiteralUtil::CreateR0<int32>(2); in XLA_TEST_F()
494 Literal dynamic_size = LiteralUtil::CreateR0<int32>(1); in XLA_TEST_F()
564 Literal expected = LiteralUtil::CreateR0<int32>(3); in XLA_TEST_F()
595 Literal dynamic_size = LiteralUtil::CreateR0<int32>(2); in XLA_TEST_F()
651 Literal expected = LiteralUtil::CreateR0<int32>(6); in XLA_TEST_F()
719 Literal expected = LiteralUtil::CreateR0<int32>(6); in XLA_TEST_F()
754 Literal expected = LiteralUtil::CreateR0<int32>(18); in XLA_TEST_F()
1015 Literal expected = LiteralUtil::CreateR0<int32>(0); in XLA_TEST_F()
[all …]
Dhlo_reachability_test.cc42 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in TEST_F()
44 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in TEST_F()
46 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in TEST_F()
48 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in TEST_F()
50 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in TEST_F()
104 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(1.0f))); in TEST_F()
106 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(2.0f))); in TEST_F()
Dflatten_call_graph_test.cc83 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(0.0f))); in MakeConditionComputation()
161 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
172 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(false))); in TEST_F()
236 HloInstruction::CreateConstant(LiteralUtil::CreateR0<bool>(true))); in TEST_F()
238 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(56.0f))); in TEST_F()
240 HloInstruction::CreateConstant(LiteralUtil::CreateR0<float>(12.0f))); in TEST_F()
Dhlo_creation_utils_test.cc156 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<int32>(9)})); in TEST_F()
216 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<int32>(0)})); in TEST_F()
235 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<float>(0.0f)})); in TEST_F()
277 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<int32>(0.0)})); in TEST_F()
296 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<float>(0.0f)})); in TEST_F()
316 evaluator.Evaluate(*module, {LiteralUtil::CreateR0<int32>(0.0)})); in TEST_F()
/external/tensorflow/tensorflow/compiler/xla/service/gpu/
Dcudnn_batchnorm_rewriter.cc87 LiteralUtil::CreateR0(batch_norm->epsilon()))); in HandleBatchNormInference()
90 LiteralUtil::CreateR0(batch_norm->feature_index()))); in HandleBatchNormInference()
139 LiteralUtil::CreateR0(batch_norm->epsilon()))); in HandleBatchNormTraining()
142 LiteralUtil::CreateR0(batch_norm->feature_index()))); in HandleBatchNormTraining()
180 LiteralUtil::CreateR0<float>(-2))), in HandleBatchNormTraining()
228 LiteralUtil::CreateR0(batch_norm->epsilon()))); in HandleBatchNormGrad()
231 LiteralUtil::CreateR0(batch_norm->feature_index()))); in HandleBatchNormGrad()
/external/tensorflow/tensorflow/compiler/xla/service/gpu/tests/
Dinfeed_test.cc55 TestInfeedRoundTrip(LiteralUtil::CreateR0<bool>(true)); in TEST_F()
103 LiteralUtil::CreateR0<bool>(false)})); in TEST_F()
116 LiteralUtil::CreateR0<int32>(5)})); in TEST_F()
/external/tensorflow/tensorflow/compiler/tf2xla/
Dtf2xla_test.cc78 auto x_literal = xla::LiteralUtil::CreateR0<int32>(10); in TEST()
79 auto y_literal = xla::LiteralUtil::CreateR0<int32>(32); in TEST()
116 auto x_literal = xla::LiteralUtil::CreateR0<int32>(10); in TEST()
117 auto y_literal = xla::LiteralUtil::CreateR0<int32>(32); in TEST()

12345