- Sort Score
- Result 10 results
- Languages All
Results 41 - 50 of 53 for ShapedType (0.25 sec)
-
tensorflow/compiler/mlir/lite/flatbuffer_operator.h
static inline std::vector<T> GetVector( vhlo::TensorV1Attr elements, mlir::vhlo::VhloTypeConverter &vhlo_type_converter) { return GetOptionalVector<T>(mlir::DenseIntElementsAttr::getFromRawBuffer( mlir::cast<mlir::ShapedType>( vhlo_type_converter.convertType(elements.getType())), elements.getData())); } } // namespace mlir
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 16 21:00:09 UTC 2024 - 11.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/tpu_dynamic_layout_pass.cc
OpBuilder* builder) { return builder->create<TF::TPUGetLayoutOp>( compile_launch.getLoc(), llvm::ArrayRef<Type>{RankedTensorType::get({ShapedType::kDynamic}, builder->getIntegerType(64))}, llvm::ArrayRef<Value>{compilation_key}, llvm::ArrayRef<NamedAttribute>{ builder->getNamedAttr("index",
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 12.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/decompose_reduce_dataset.cc
llvm::SmallVector<Attribute, 2> shape_attrs; llvm::SmallVector<Attribute, 2> type_attrs; for (Type type : dataset_types) { shape_attrs.push_back( TF::ShapeAttr::get(builder.getContext(), mlir::cast<ShapedType>(type))); type_attrs.push_back(TypeAttr::get(getElementTypeOrSelf(type))); } auto anonymous_iterator = builder.create<AnonymousIteratorV3Op>( reduce_dataset.getLoc(),
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 14K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_utils.h
LogicalResult matchAndRewrite(quantfork::StatisticsOp op, PatternRewriter& rewriter) const override { Type expressed = op.getType().cast<ShapedType>().getElementType(); quant::QuantizedType quant_type; SmallVector<double, 4> mins, maxs; if (op.getAxisStats().has_value()) { // Per axis quantization (or per channel quantization)
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Apr 24 20:30:06 UTC 2024 - 41.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/translate/tf_mlir_translate.cc
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 07 11:51:44 UTC 2024 - 14.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/bridge/convert_tf_quant_types.cc
// If input is not TF qint types, returns the original type. Type ToLegalType(Type type) { if (IsTFQintType(type)) return GetIntTypeFromTFQint(type); if (auto shaped = mlir::dyn_cast<ShapedType>(type)) { Type elem = shaped.getElementType(); if (IsTFQintType(elem)) return shaped.clone(ToLegalType(elem)); } return type; } bool IsQintToIntCast(Operation *op) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 12.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/einsum.cc
int64_t prod_shape = 1; for (auto index_tuple : index_tuples) { const int64_t shape_i = shape[std::get<I>(index_tuple)]; if (ShapedType::isDynamic(shape_i)) return ShapedType::kDynamic; prod_shape *= shape_i; } return prod_shape; } // Reshapes LHS and RHS to have B0,...,Bn,L,C and B0,...,Bn,C,R shape
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 33.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/lift_as_function_call.cc
SmallVector<Attribute> shape_attrs; for (const Type result_type : output_types) { shape_attrs.push_back( tf_type::ShapeAttr::get(ctx, mlir::cast<ShapedType>(result_type))); } auto empty_array_attr = ArrayAttr::get(ctx, {}); auto platforms = ArrayAttr::get(ctx, {StringAttr::get(ctx, kPlatformCpu)}); auto call_op = builder.create<TF::XlaCallModuleOp>(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 17 17:58:54 UTC 2024 - 21.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/replace_stablehlo_ops_in_main_function_with_xla_call_module_ops.cc
// Create attributes used for creating an XlaCallModuleOp. SmallVector<Attribute> shape_attrs; for (const Type result_type : result_types) { shape_attrs.push_back( tf_type::ShapeAttr::get(ctx, mlir::cast<ShapedType>(result_type))); } const auto empty_array_attr = ArrayAttr::get(ctx, {}); // TODO: b/310291615 - find a better way for platform support. const auto platforms = ArrayAttr::get( ctx,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 21K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/legalize_patterns.td
(TFL_TopKV2Op $input, $k)>; def ReductionDimensionIsLastDim : Constraint<CPred<"($0.cast<IntegerAttr>().getInt() == " "$1.getType().cast<ShapedType>().getRank() - 1 || $0.cast<IntegerAttr>().getInt() == -1)">>; // Legalizes TF_ApproxTopKOp to TFL_TopKV2Op with the following constraints: // 1. It computes max k
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Jun 04 13:30:42 UTC 2024 - 28.5K bytes - Viewed (0)