- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for getElementDtype (0.2 sec)
-
tensorflow/compiler/mlir/lite/transforms/lower_static_tensor_list.cc
return UnrankedTensorType::get( variant_ty.getSubtypes()[0].getElementType()); } Type value_type = value.getType(); Type element_type; variant_ty = value_type.dyn_cast<TF::VariantType>(); if (variant_ty && !variant_ty.getSubtypes().empty()) { element_type = variant_ty.getSubtypes()[0].getElementType(); } else { element_type = getElementTypeOrSelf(value_type); }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Jun 11 20:00:43 UTC 2024 - 70.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/quantize_composite_functions.cc
if (mlir::isa<QuantizedType>(type.getElementType())) { has_quantized_types = true; } } } for (Value output : call_op.getOutput()) { if (auto type = mlir::dyn_cast<TensorType>(output.getType())) { if (mlir::isa<QuantizedType>(type.getElementType())) { has_quantized_types = true; } } }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 54.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/compose_uniform_quantized_type_pass.cc
bool IsI8ToF32Cast(stablehlo::ConvertOp convert_op) { const bool is_i8_operand = convert_op.getOperand().getType().getElementType().isInteger(/*width=*/8); const bool is_f32_result = mlir::isa<Float32Type>(convert_op.getResult().getType().getElementType()); return is_i8_operand && is_f32_result; } // Tests whether a `stablehlo::ConvertOp` is a i8 -> i32 cast.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 64.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/lower_tf.cc
.getElementType() .isF32()) { return failure(); } MLIRContext *context = rewriter.getContext(); llvm::SmallVector<Value, 2> operands{op.getA(), op.getB()}; for (Value &operand : operands) { TensorType tensor_type = mlir::cast<TensorType>(operand.getType()); Type element_type = tensor_type.getElementType();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 74.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/prepare_tf.cc
// TODO(antiagainst): also handle the case of tf.Add(tf.[op], <bias>) // Get a splat zero tensor with the expected dimension for the bias tensor auto elem_type = filter_type.getElementType(); auto bias_dim = static_cast<const ConcreteType *>(this)->getBiasDim( filter_type.getShape()); auto bias_type = tensorflow::GetTypeFromTFTensorShape({bias_dim}, elem_type);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 28 21:49:50 UTC 2024 - 64.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/optimize_patterns.td
CPred<"$_self.isa<ElementsAttr>() && $_self.cast<ElementsAttr>().getShapedType().getElementType().isF32()">, "32 bit float constant tensor">; // Checks if the param passed is a float ElementsAttr. def FloatElementsAttr : ElementsAttrBase< CPred<"$_self.isa<ElementsAttr>() && $_self.cast<ElementsAttr>().getShapedType().getElementType().isa<FloatType>()">, "float constant tensor">;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 16 20:31:41 UTC 2024 - 66.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/flatbuffer_import.cc
bool truncate = shaped_type.getElementType().getIntOrFloatBitWidth() == 64; TF_ASSIGN_OR_RETURN(value, tfl::ConvertIntBuffer(shaped_type, buffer, truncate)); TF_ASSIGN_OR_RETURN( mlir::quant::QuantizedType type, tfl::GetQuantizedType(tensor, builder, /*is_constant=*/true, /*storage_type=*/value.getElementType())); shaped_type = shaped_type.clone(type);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 21 18:21:50 UTC 2024 - 66.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/sparsecore/embedding_pipelining.cc
namespace mlir { namespace TFDevice { namespace { bool IsResourceType(Type val_type) { if (auto tensor_type = mlir::dyn_cast<mlir::TensorType>(val_type)) { if (mlir::isa<TF::ResourceType>(tensor_type.getElementType())) { return true; } } return false; } struct EmbeddingPipeliningPass : public ::impl::EmbeddingPipeliningPassBase<EmbeddingPipeliningPass> {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 92.9K bytes - Viewed (0)