- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 49 for set_type (0.34 sec)
-
tensorflow/compiler/mlir/tensorflow/utils/export_utils.cc
AttrValue attr_val; // For type attributes, we only propagate the element type. mlir::Type elt_type = attr.getValue(); if (auto shaped_type = mlir::dyn_cast<mlir::ShapedType>(elt_type)) { elt_type = shaped_type.getElementType(); } TF_RETURN_IF_ERROR( ConvertAttribute(elt_type, remove_ref_type, &attr_val)); list->add_type(attr_val.type());
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/translate/export_graphdef.cc
node_def->set_op(FunctionLibraryDefinition::kRetOp); DataType dtype; TF_RETURN_IF_ERROR(ConvertToDataType( mlir::cast<mlir::TensorType>(operand.getType()).getElementType(), &dtype)); AttrValue type_attr; type_attr.set_type(dtype); (*node_def->mutable_attr())["T"] = type_attr; AttrValue index_attr; index_attr.set_i(index); (*node_def->mutable_attr())["index"] = index_attr;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 01 11:17:36 UTC 2024 - 35.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tf2xla/api/v2/tf_executor_to_graph.cc
node_def->set_op(FunctionLibraryDefinition::kRetOp); DataType dtype; TF_RETURN_IF_ERROR(ConvertToDataType( mlir::cast<mlir::TensorType>(operand.getType()).getElementType(), &dtype)); AttrValue type_attr; type_attr.set_type(dtype); (*node_def->mutable_attr())["T"] = type_attr; AttrValue index_attr; index_attr.set_i(index); (*node_def->mutable_attr())["index"] = index_attr;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 06 23:04:51 UTC 2024 - 35.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/utils/convert_tensor.cc
const auto& input_dtype = input_tensor.dtype(); const auto& input_shape = input_tensor.shape(); Type elt_type; TF_RETURN_IF_ERROR(ConvertDataType(input_dtype, *builder, &elt_type)); SmallVector<int64_t, 4> shape; ConvertToMlirShape(input_shape, &shape); auto type = RankedTensorType::get(shape, elt_type); #define CONVERT_FLAT(DTYPE, CTYPE) \ case 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/tensorflow/c/c_api_unified_experimental_mlir.cc
return absl::OkStatus(); } Status MlirAbstractOp::AddRef(Type type, Type* output_type) { Type elt_type = getElementTypeOrSelf(type); if (mlir::isa<mlir::TF::TensorFlowRefType>(elt_type)) { return InvalidArgument("Requested reference to a reference type"); } elt_type = TensorFlowRefType::get(elt_type); if (RankedTensorType tensor_type = mlir::dyn_cast<RankedTensorType>(type)) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 28.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/decompose_optionals.cc
for (auto [call_arg, body_arg] : llvm::zip(call.getOperation()->getOperands(), f.getBody().front().getArguments())) { if (call_arg.getType() != body_arg.getType()) { body_arg.setType(call_arg.getType()); changed = true; } } if (changed) { rewriter.finalizeOpModification(f); return success(); } else {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Jun 12 21:18:05 UTC 2024 - 9.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/quantization_patterns.cc
arg.setType(ReplaceElementType(arg.getType(), element_type)); } for (Operation& op : region.getOps()) { for (Value operand : op.getOperands()) { operand.setType(ReplaceElementType(operand.getType(), element_type)); } for (Value result : op.getResults()) { result.setType(ReplaceElementType(result.getType(), element_type)); } } }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 03 06:04:36 UTC 2024 - 41.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/dilated_conv.h
op.getResult().setType(conv_result_type); squeeze_op.getResult().setType(bts_op.getOutput().getType()); // Connect `biasadd_op` with the output of `squeeze_op`. if (biasadd_op) { biasadd_op.setOperand(0, squeeze_op.getOutput()); biasadd_op.getOutput().setType(squeeze_op.getOutput().getType()); } } else { if (biasadd_op) biasadd_op.setOperand(0, op.getOutput());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 20K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/tpu_space_to_depth_pass.cc
auto ranked_type = mlir::dyn_cast<RankedTensorType>(input.getType()); if (!ranked_type) return false; auto input_shape = ranked_type.getShape(); auto space_to_depth = BuildSpaceToDepth(cluster_func, input, block_size, input_shape); entry.value().set(space_to_depth); block_arg.setType(space_to_depth.getType()); } return true; }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 29.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/lift_tflite_flex_ops.cc
Value handle = tensor_array_v3_op.getHandle(); auto handle_type = mlir::cast<TensorType>(handle.getType()); if (handle_type.getElementType().isInteger(/*width=*/32)) { Type resource_tensor_type = handle_type.clone(TF::ResourceType::get(rewriter.getContext())); handle.setType(resource_tensor_type); } } // Special type fixes for scalar tensor types.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 10.9K bytes - Viewed (0)