/external/tensorflow/tensorflow/python/framework/ |
D | fast_tensor_util.pyx | 10 tensor_proto, np.ndarray[np.uint16_t, ndim=1] nparray): argument 14 tensor_proto.half_val.append(nparray[i]) 22 tensor_proto, np.ndarray[np.uint16_t, ndim=1] nparray): argument 26 tensor_proto.half_val.append(nparray[i]) 30 tensor_proto, np.ndarray[np.float32_t, ndim=1] nparray): argument 34 tensor_proto.float_val.append(nparray[i]) 38 tensor_proto, np.ndarray[np.float64_t, ndim=1] nparray): argument 42 tensor_proto.double_val.append(nparray[i]) 46 tensor_proto, np.ndarray[np.int32_t, ndim=1] nparray): argument 50 tensor_proto.int_val.append(nparray[i]) [all …]
|
D | tensor_util.py | 49 def SlowAppendFloat16ArrayToTensorProto(tensor_proto, proto_values): argument 50 tensor_proto.half_val.extend( 54 def _MediumAppendFloat16ArrayToTensorProto(tensor_proto, proto_values): argument 57 tensor_proto, 66 def SlowAppendBFloat16ArrayToTensorProto(tensor_proto, proto_values): argument 67 tensor_proto.half_val.extend( 71 def FastAppendBFloat16ArrayToTensorProto(tensor_proto, proto_values): argument 73 tensor_proto, np.asarray( 125 def SlowAppendFloat32ArrayToTensorProto(tensor_proto, proto_values): argument 126 tensor_proto.float_val.extend([x.item() for x in proto_values]) [all …]
|
/external/tensorflow/tensorflow/core/kernels/ |
D | unique_op_test.cc | 39 TensorProto tensor_proto; in GetRandomInt32TensorProto() local 40 tensor_proto.set_dtype(DT_INT32); in GetRandomInt32TensorProto() 41 tensor_proto.mutable_tensor_shape()->add_dim()->set_size(dim); in GetRandomInt32TensorProto() 42 tensor_proto.mutable_tensor_shape()->set_unknown_rank(false); in GetRandomInt32TensorProto() 45 tensor_proto.add_int_val(int_val); in GetRandomInt32TensorProto() 47 return tensor_proto; in GetRandomInt32TensorProto() 52 TensorProto tensor_proto; in GetRandomInt32TensorProtoWithRepeat() local 53 tensor_proto.set_dtype(DT_INT32); in GetRandomInt32TensorProtoWithRepeat() 54 tensor_proto.mutable_tensor_shape()->add_dim()->set_size(dim); in GetRandomInt32TensorProtoWithRepeat() 55 tensor_proto.mutable_tensor_shape()->set_unknown_rank(false); in GetRandomInt32TensorProtoWithRepeat() [all …]
|
/external/tensorflow/tensorflow/core/framework/ |
D | tensor_util_test.cc | 437 TensorProto tensor_proto = in TEST() local 439 EXPECT_FALSE(tensor::CompressTensorProtoInPlace(&tensor_proto)); in TEST() 440 tensor_proto = in TEST() 442 EXPECT_FALSE(tensor::CompressTensorProtoInPlace(&tensor_proto)); in TEST() 443 tensor_proto = in TEST() 445 EXPECT_FALSE(tensor::CompressTensorProtoInPlace(&tensor_proto)); in TEST() 446 tensor_proto = in TEST() 448 EXPECT_FALSE(tensor::CompressTensorProtoInPlace(&tensor_proto)); in TEST() 449 tensor_proto = in TEST() 451 EXPECT_FALSE(tensor::CompressTensorProtoInPlace(&tensor_proto)); in TEST() [all …]
|
/external/tensorflow/tensorflow/core/common_runtime/ |
D | threadpool_device.cc | 92 const TensorProto& tensor_proto, const AllocatorAttributes alloc_attrs, in MakeTensorFromProto() argument 94 if (tensor_proto.dtype() > 0 && tensor_proto.dtype() <= DataType_MAX) { in MakeTensorFromProto() 95 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 96 if (parsed.FromProto(allocator_, tensor_proto)) { in MakeTensorFromProto() 102 ProtoDebugString(tensor_proto)); in MakeTensorFromProto()
|
D | single_threaded_cpu_device.cc | 65 Status MakeTensorFromProto(const TensorProto& tensor_proto, in MakeTensorFromProto() argument 68 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 69 if (!parsed.FromProto(cpu_allocator(), tensor_proto)) { in MakeTensorFromProto()
|
D | renamed_device.h | 91 Status MakeTensorFromProto(const TensorProto& tensor_proto, in MakeTensorFromProto() argument 94 return underlying_->MakeTensorFromProto(tensor_proto, alloc_attrs, tensor); in MakeTensorFromProto()
|
D | threadpool_device.h | 38 Status MakeTensorFromProto(const TensorProto& tensor_proto,
|
D | constant_folding_test.cc | 54 const TensorProto* tensor_proto; in ExpectNodeClose() local 55 TF_EXPECT_OK(GetNodeAttr(n->attrs(), "value", &tensor_proto)); in ExpectNodeClose() 59 EXPECT_TRUE(t.FromProto(*tensor_proto)); in ExpectNodeClose() 67 const TensorProto* tensor_proto; in ExpectNodeEqual() local 68 TF_EXPECT_OK(GetNodeAttr(n->attrs(), "value", &tensor_proto)); in ExpectNodeEqual() 72 EXPECT_TRUE(t.FromProto(*tensor_proto)); in ExpectNodeEqual()
|
/external/tensorflow/tensorflow/contrib/util/ |
D | convert_graphdef_memmapped_format_lib.cc | 45 const TensorProto& tensor_proto = value.tensor(); in ConvertConstantsToImmutable() local 50 const DataType tensor_data_type = tensor_proto.dtype(); in ConvertConstantsToImmutable() 51 const TensorShapeProto tensor_shape = tensor_proto.tensor_shape(); in ConvertConstantsToImmutable() 68 Tensor parsed(tensor_proto.dtype()); in ConvertConstantsToImmutable() 69 if (!parsed.FromProto(cpu_allocator(), tensor_proto)) { in ConvertConstantsToImmutable() 71 tensor_proto.DebugString()); in ConvertConstantsToImmutable()
|
/external/tensorflow/tensorflow/core/common_runtime/sycl/ |
D | sycl_device.cc | 45 Status SYCLDevice::MakeTensorFromProto(const TensorProto& tensor_proto, in MakeTensorFromProto() argument 52 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 53 if (!parsed.FromProto(host_alloc, tensor_proto)) { in MakeTensorFromProto() 55 tensor_proto.DebugString()); in MakeTensorFromProto()
|
/external/tensorflow/tensorflow/core/grappler/costs/ |
D | op_level_cost_estimator_test.cc | 338 TensorProto* tensor_proto) { in GetTensorProto() argument 339 tensor_proto->Clear(); in GetTensorProto() 362 tensor.AsProtoTensorContent(tensor_proto); in GetTensorProto() 364 tensor.AsProtoField(tensor_proto); in GetTensorProto() 386 auto* tensor_proto = op_info.mutable_inputs(0)->mutable_value(); in DescribePoolingOp() local 388 /*tensor_content=*/false, tensor_proto); in DescribePoolingOp() 936 TensorProto tensor_proto; in TEST_F() local 941 tensor_proto.mutable_tensor_shape()->add_dim()->set_size(255); in TEST_F() 943 GetTensorShapeProtoFromTensorProto(tensor_proto, &tensor_shape_proto)); in TEST_F() 945 tensor_proto.Clear(); in TEST_F() [all …]
|
D | graph_properties.cc | 372 TensorProto tensor_proto; in MakeTensorProtoFromShape() local 373 tensor_proto.set_dtype(dtype); in MakeTensorProtoFromShape() 374 auto* shape_proto = tensor_proto.mutable_tensor_shape(); in MakeTensorProtoFromShape() 382 tensor_proto.add_int_val(value); in MakeTensorProtoFromShape() 384 tensor_proto.add_int64_val(value); in MakeTensorProtoFromShape() 387 return tensor_proto; in MakeTensorProtoFromShape() 392 const TensorProto& tensor_proto, in MakeConstNodeDefFromTensorProto() argument 400 *tensor = tensor_proto; in MakeConstNodeDefFromTensorProto() 791 auto* tensor_proto = src_ctx->output_tensor_protos[src_output]; in UpdateNode() local 792 if (tensor_proto != nullptr && in UpdateNode() [all …]
|
/external/tensorflow/tensorflow/core/debug/ |
D | debug_io_utils.cc | 129 TensorProto* tensor_proto, in WrapStringTensorAsEvents() argument 131 const protobuf::RepeatedPtrField<string>& strs = tensor_proto->string_val(); in WrapStringTensorAsEvents() 160 num_chunks, i, tensor_proto->dtype(), in WrapStringTensorAsEvents() 161 tensor_proto->tensor_shape()); in WrapStringTensorAsEvents() 166 tensor_proto->mutable_string_val()); in WrapStringTensorAsEvents() 190 TensorProto tensor_proto; in WrapTensorAsEvents() local 195 tensor.AsProtoField(&tensor_proto); in WrapTensorAsEvents() 198 debug_node_key, wall_time_us, chunk_size_limit, &tensor_proto, events)); in WrapTensorAsEvents() 200 tensor.AsProtoTensorContent(&tensor_proto); in WrapTensorAsEvents() 202 const size_t total_length = tensor_proto.tensor_content().size(); in WrapTensorAsEvents() [all …]
|
D | debug_grpc_testlib.cc | 54 const TensorProto& tensor_proto = val.tensor(); in SendEvents() local 55 Tensor tensor(tensor_proto.dtype()); in SendEvents() 56 if (!tensor.FromProto(tensor_proto)) { in SendEvents()
|
/external/tensorflow/tensorflow/core/grappler/optimizers/ |
D | evaluation_utils.cc | 71 Status DeviceSimple::MakeTensorFromProto(const TensorProto& tensor_proto, in MakeTensorFromProto() argument 74 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 75 if (!parsed.FromProto(cpu_allocator(), tensor_proto)) { in MakeTensorFromProto()
|
D | evaluation_utils.h | 40 Status MakeTensorFromProto(const TensorProto& tensor_proto,
|
/external/tensorflow/tensorflow/python/debug/lib/ |
D | debug_data.py | 62 def __init__(self, tensor_proto, initialized=True): argument 70 self._tensor_proto = tensor_proto 121 tensor_proto = event.summary.value[0].tensor 122 shape = tensor_util.TensorShapeProtoToList(tensor_proto.tensor_shape) 127 if tensor_proto.tensor_content or tensor_proto.string_val or not num_elements: 129 if tensor_proto.dtype == types_pb2.DT_RESOURCE: 130 tensor_value = InconvertibleTensorProto(tensor_proto) 133 tensor_value = tensor_util.MakeNdarray(tensor_proto) 135 tensor_value = InconvertibleTensorProto(tensor_proto) 138 tensor_value = InconvertibleTensorProto(tensor_proto, False)
|
/external/tensorflow/tensorflow/contrib/gdr/ |
D | gdr_worker.cc | 98 TensorProto* tensor_proto = proto->mutable_tensor(); in GrpcRecvTensorAsync() local 99 tensor_proto->set_dtype(val.dtype()); in GrpcRecvTensorAsync() 100 val.shape().AsProto(tensor_proto->mutable_tensor_shape()); in GrpcRecvTensorAsync()
|
/external/tensorflow/tensorflow/cc/framework/ |
D | ops.h | 183 TensorProto tensor_proto; 185 tensor.AsProtoTensorContent(&tensor_proto); 187 tensor.AsProtoField(&tensor_proto); 189 return tensor_proto;
|
/external/tensorflow/tensorflow/python/debug/cli/ |
D | tensor_format_test.py | 342 tensor_proto = tensor_pb2.TensorProto( 347 debug_data.InconvertibleTensorProto(tensor_proto, False), "a") 351 self.assertEqual(str(tensor_proto).split("\n"), out.lines[3:]) 354 tensor_proto = tensor_pb2.TensorProto( 359 debug_data.InconvertibleTensorProto(tensor_proto), "a") 362 self.assertEqual(str(tensor_proto).split("\n"), out.lines[2:]) 626 tensor_proto = tensor_pb2.TensorProto( 631 debug_data.InconvertibleTensorProto(tensor_proto, False), "a")
|
/external/tensorflow/tensorflow/tools/graph_transforms/ |
D | transform_utils.h | 86 TensorProto tensor_proto; in SetNodeTensorAttr() local 87 tensor.AsProtoTensorContent(&tensor_proto); in SetNodeTensorAttr() 88 SetNodeAttr(key, tensor_proto, node); in SetNodeTensorAttr()
|
/external/tensorflow/tensorflow/compiler/jit/ |
D | xla_device.cc | 440 Status XlaDevice::MakeTensorFromProto(const TensorProto& tensor_proto, in MakeTensorFromProto() argument 445 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 446 if (!parsed.FromProto(cpu_allocator(), tensor_proto)) { in MakeTensorFromProto() 448 tensor_proto.DebugString()); in MakeTensorFromProto()
|
/external/tensorflow/tensorflow/core/kernels/hexagon/ |
D | graph_transferer.cc | 737 const TensorProto* tensor_proto = nullptr; in RegisterPadNode() local 738 TF_CHECK_OK(GetNodeAttr(input_node->attrs(), "value", &tensor_proto)); in RegisterPadNode() 739 CHECK_NOTNULL(tensor_proto); in RegisterPadNode() 741 TF_CHECK_OK(MakeTensorFromProto(*tensor_proto, &const_tensor)); in RegisterPadNode() 1101 const TensorProto& tensor_proto, Tensor* tensor) { in MakeTensorFromProto() argument 1102 if (tensor_proto.dtype() > 0 && tensor_proto.dtype() <= DataType_MAX) { in MakeTensorFromProto() 1103 Tensor parsed(tensor_proto.dtype()); in MakeTensorFromProto() 1104 if (parsed.FromProto(cpu_allocator(), tensor_proto)) { in MakeTensorFromProto() 1110 tensor_proto.DebugString()); in MakeTensorFromProto()
|
/external/tensorflow/tensorflow/compiler/tf2xla/ |
D | xla_compilation_device.h | 59 Status MakeTensorFromProto(const TensorProto& tensor_proto,
|