/external/tensorflow/tensorflow/compiler/tf2xla/ |
D | literal_util.cc | 25 Status HostTensorToBorrowingLiteral(const Tensor& host_tensor, in HostTensorToBorrowingLiteral() argument 28 TF_RETURN_IF_ERROR(TensorShapeToXLAShape(host_tensor.dtype(), in HostTensorToBorrowingLiteral() 29 host_tensor.shape(), &xla_shape)); in HostTensorToBorrowingLiteral() 30 return HostTensorToBorrowingLiteral(xla_shape, host_tensor, literal); in HostTensorToBorrowingLiteral() 34 const Tensor& host_tensor, in HostTensorToBorrowingLiteral() argument 36 const auto& tshape = host_tensor.shape(); in HostTensorToBorrowingLiteral() 42 static_cast<const char*>(DMAHelper::base(&host_tensor)), xla_shape); in HostTensorToBorrowingLiteral() 46 StatusOr<xla::Literal> HostTensorToLiteral(const Tensor& host_tensor) { in HostTensorToLiteral() argument 48 TF_RETURN_IF_ERROR(HostTensorToBorrowingLiteral(host_tensor, &literal)); in HostTensorToLiteral() 53 Tensor* host_tensor, xla::MutableBorrowingLiteral* literal) { in HostTensorToMutableBorrowingLiteral() argument [all …]
|
D | literal_util_test.cc | 32 Tensor host_tensor; in TEST() local 34 LiteralToHostTensor(int64_values_literal, DT_INT32, &host_tensor) in TEST() 37 LiteralToHostTensor(int64_values_literal, DT_QINT32, &host_tensor) in TEST() 40 LiteralToHostTensor(int64_values_literal, DT_INT64, &host_tensor).ok()); in TEST() 41 test::ExpectTensorEqual<int64_t>(host_tensor, in TEST() 58 Tensor host_tensor; in TYPED_TEST() local 63 DataTypeToEnum<int_type>::value, &host_tensor) in TYPED_TEST() 65 test::ExpectTensorEqual<int_type>(host_tensor, in TYPED_TEST() 70 &host_tensor) in TYPED_TEST() 73 test::ExpectTensorEqual<qint_type>(host_tensor, in TYPED_TEST() [all …]
|
D | literal_util.h | 31 Status HostTensorToBorrowingLiteral(const Tensor& host_tensor, 37 const Tensor& host_tensor, 42 StatusOr<xla::Literal> HostTensorToLiteral(const Tensor& host_tensor); 47 Tensor* host_tensor, xla::MutableBorrowingLiteral* literal); 52 const xla::Shape& xla_shape, Tensor* host_tensor, 68 DataType target_type, Tensor* host_tensor); 74 Tensor* host_tensor);
|
D | xla_op_kernel.h | 240 void SetConstantOutput(int index, const Tensor& host_tensor);
|
/external/tensorflow/tensorflow/core/tfrt/utils/ |
D | tensor_util.cc | 180 const auto& host_tensor = tensor_handle.GetAsyncTensor()->get<HostTensor>(); in CreateTFTensorFromTensorHandle() local 183 llvm::dyn_cast<tensorflow::KernelFallbackTensor>(&host_tensor)) { in CreateTFTensorFromTensorHandle() 187 if (llvm::isa<StringHostTensor>(host_tensor)) { in CreateTFTensorFromTensorHandle() 189 const auto& sht = llvm::cast<StringHostTensor>(host_tensor); in CreateTFTensorFromTensorHandle() 202 if (llvm::isa<DenseHostTensor>(host_tensor)) { in CreateTFTensorFromTensorHandle() 203 const auto& dht = llvm::cast<DenseHostTensor>(host_tensor); in CreateTFTensorFromTensorHandle()
|
/external/tensorflow/tensorflow/cc/experimental/libtf/tests/ |
D | runtime_test.cc | 63 TF_ASSERT_OK_AND_ASSIGN(Tensor host_tensor, in TEST_P() 66 TF_ASSERT_OK_AND_ASSIGN(Tensor tensor, fn.Call<Tensor>(Tensor(host_tensor))); in TEST_P()
|
/external/tensorflow/tensorflow/compiler/mlir/tfrt/runtime_fallback/ |
D | runtime_fallback_ops.td | 134 : (!tfd.tf_tensor, !tfrt.chain) -> (!dht.host_tensor, !tfrt.chain) 153 : (!tfd.tf_tensor, !tfrt.chain) -> (!dht.host_tensor, !tfrt.chain)
|
/external/tensorflow/tensorflow/core/tfrt/graph_executor/ |
D | graph_executor.cc | 255 const auto& host_tensor = result->get<FallbackTensor>().tensor(); in GraphExecutionRunOnFunction() local 258 outputs->push_back(host_tensor); in GraphExecutionRunOnFunction()
|
/external/tensorflow/tensorflow/core/kernels/ |
D | resource_variable_ops.cc | 942 Tensor* host_tensor) { in CopyTensorToHost() argument 948 device_tensor.dtype(), device_tensor.shape(), host_tensor, alloc_attr)); in CopyTensorToHost() 952 stream->ThenMemcpy(host_tensor->flat<T>().data(), device_ptr, in CopyTensorToHost()
|
/external/tensorflow/tensorflow/core/common_runtime/gpu/ |
D | gpu_device.cc | 590 Tensor host_tensor(gpu_tensor.dtype(), gpu_tensor.shape()); in CopyGpuTensorToHostDebugOnly() local 592 ->ThenMemcpy(host_tensor.data(), in CopyGpuTensorToHostDebugOnly() 598 return host_tensor; in CopyGpuTensorToHostDebugOnly()
|
/external/tensorflow/tensorflow/core/common_runtime/ |
D | direct_session_test.cc | 2475 Tensor host_tensor(dtype, {3}); in TestFeedAndFetchTensorsInDeviceMemory() local 2485 TF_ASSERT_OK(session->RunCallable(handle, {host_tensor}, &outputs, nullptr)) in TestFeedAndFetchTensorsInDeviceMemory() 2506 const StringPiece expected_data = host_tensor.tensor_data(); in TestFeedAndFetchTensorsInDeviceMemory()
|