- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for AsProtoTensorContent (0.2 sec)
-
tensorflow/cc/saved_model/util_test.cc
TensorProto tensor_proto; tensor.AsProtoTensorContent(&tensor_proto); return tensor_proto; } void ConvertOutputTensorToProto( std::vector<std::pair<string, Tensor>>& inputs, std::vector<std::pair<string, TensorProto>>& protos) { for (const auto& input : inputs) { TensorProto tensor_proto; input.second.AsProtoTensorContent(&tensor_proto);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Sep 06 19:12:29 UTC 2023 - 5.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/utils/tf_type_utils_test.cc
tensor.matrix<tsl::qint8>()(0, 1) = tsl::qint8(2); tensor.matrix<tsl::qint8>()(1, 0) = tsl::qint8(3); tensor.matrix<tsl::qint8>()(1, 1) = tsl::qint8(4); ::tensorflow::TensorProto tensor_proto; tensor.AsProtoTensorContent(&tensor_proto); return ::tensorflow::mangling_util::MangleTensor(tensor_proto); } std::string GetQint16Tensor() { ::tensorflow::Tensor tensor(::tensorflow::DT_QINT16, {2, 2});
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 9K bytes - Viewed (0) -
tensorflow/c/experimental/saved_model/core/constant_loading_test.cc
expected.data(), 42); // Serialize it to a Tensorproto TensorProto proto; if (tensorproto_use_tensor_content) { expected.AsProtoTensorContent(&proto); } else { expected.AsProtoField(&proto); } // Revival should succeed w/o errors std::unique_ptr<Constant> revived;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Aug 11 01:20:50 UTC 2021 - 4.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/debugging/dump_tensor_op.cc
} void Compute(OpKernelContext* ctx) override { if (!enabled_) return; const Tensor& tensor_data = ctx->input(0); TensorProto tensor_proto; tensor_data.AsProtoTensorContent(&tensor_proto); OP_REQUIRES_OK(ctx, tensor_data_writer_->WriteRecord( tensor_proto.SerializeAsString())); } private: bool enabled_;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Feb 22 03:12:17 UTC 2024 - 4.8K bytes - Viewed (0) -
tensorflow/cc/tools/freeze_saved_model.cc
const_node->set_name(variable_node.name()); const_node->set_op("Const"); (*const_node->mutable_attr())["dtype"] = variable_node.attr().at("dtype"); variable_value.AsProtoTensorContent( (*const_node->mutable_attr())["value"].mutable_tensor()); } // Converts a ReadVariableOp NodeDef to an Identity NodeDef. void ConvertReadVariableOpToIdentity(const NodeDef& node,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 11 08:05:36 UTC 2023 - 11.9K bytes - Viewed (0) -
tensorflow/cc/framework/ops.h
typedef T type; }; // END_SKIP_DOXYGEN TensorProto AsTensorProto() { TensorProto tensor_proto; if (tensor.NumElements() > 1) { tensor.AsProtoTensorContent(&tensor_proto); } else { tensor.AsProtoField(&tensor_proto); } return tensor_proto; } Status status; Tensor tensor; };
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Apr 13 05:57:22 UTC 2024 - 10.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/utils/convert_tensor.cc
// representation. // * For scalars and short strings it may be marginally worse and a more // intelligent decision could be made by caller. if (use_tensor_content) input_tensor.AsProtoTensorContent(&tensor_proto); else input_tensor.AsProtoField(&tensor_proto); return tensor_proto; } static std::string MangleTensor(const Tensor& tensor) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Apr 26 09:37:10 UTC 2024 - 20.5K bytes - Viewed (0)