- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for ConvertToTensorProto (0.3 sec)
-
tensorflow/compiler/mlir/tensorflow/utils/convert_tensor.h
absl::StatusOr<mlir::Attribute> ConvertTensorShapeProto( const TensorShapeProto& shape, mlir::MLIRContext* context); // Converts an MLIR elements attribute to a TensorFlow tensor proto. Status ConvertToTensorProto(mlir::ElementsAttr attr, TensorProto* output_tensor); // Converts an MLIR elements attribute to a TensorFlow tensor. Status ConvertToTensor(mlir::ElementsAttr attr, Tensor* output_tensor);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Apr 26 09:37:10 UTC 2024 - 2.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/utils/export_utils.cc
value->set_f(attr.getValueAsDouble()); return absl::OkStatus(); } Status ConvertAttribute(const mlir::ElementsAttr& attr, AttrValue* value) { return ConvertToTensorProto(attr, value->mutable_tensor()); } Status ConvertAttribute(const mlir::TF::PlaceholderAttr& attr, AttrValue* value) { value->set_placeholder(attr.getValue().str());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 17 17:58:54 UTC 2024 - 19.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/utils/convert_tensor.cc
} else { output->reserve(attr.getNumElements()); for (const T value : attr.getValues<T>()) output->push_back(Eigen::numext::bit_cast<uint8_t>(value)); } } Status ConvertToTensorProto(const ElementsAttr attr, TensorProto* output) { auto type = attr.getShapedType(); auto shape = type.getShape(); DataType output_dtype; TF_RETURN_IF_ERROR(ConvertToDataType(type, &output_dtype));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Apr 26 09:37:10 UTC 2024 - 20.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/quantize_composite_functions.cc
// TODO(b/225793355): It adds TensorProtoAttr to the constant as a // workaround. tensorflow::TensorProto tensor_proto; if (!mlir::tfg::ConvertToTensorProto( mlir::cast<ElementsAttr>(tensor_proto_attr), &tensor_proto) .ok()) { return failure(); } const int bit_width =
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 54.5K bytes - Viewed (0)