- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 171 for getElementDtype (0.26 sec)
-
tensorflow/compiler/mlir/tfr/passes/rewrite_quantized_io.cc
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 08 01:19:25 UTC 2023 - 4.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/ir/QuantOps.cc
return quantizedType.isCompatibleExpressedType(expressed); if (auto tensorType = mlir::dyn_cast<TensorType>(expressed)) return spec == tensorType.getElementType(); if (auto vectorType = mlir::dyn_cast<VectorType>(expressed)) return spec == vectorType.getElementType(); } return false; } LogicalResult QuantizeRegionOp::verify() { // There are specifications for both inputs and outputs.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/quantization/ir/QuantOps.cc
return quantizedType.isCompatibleExpressedType(expressed); if (auto tensorType = mlir::dyn_cast<TensorType>(expressed)) return spec == tensorType.getElementType(); if (auto vectorType = mlir::dyn_cast<VectorType>(expressed)) return spec == vectorType.getElementType(); } return false; } LogicalResult QuantizeRegionOp::verify() { // There are specifications for both inputs and outputs.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/utils/constant_utils.cc
#include "tsl/platform/statusor.h" namespace mlir { namespace TFL { absl::StatusOr<TypedAttr> CreateTypedAttr(ShapedType shaped_type, int value) { Type element_type = shaped_type.getElementType(); if (element_type.isF16()) { auto floatType = mlir::FloatType::getF16(element_type.getContext()); auto floatAttr = mlir::FloatAttr::get(floatType, static_cast<float>(value));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 6.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/reduce_type_precision.cc
auto const_type = mlir::dyn_cast<ShapedType>(op.getOperand(0).getType()); auto result_type = mlir::dyn_cast<ShapedType>(op.getResult().getType()); if (!const_type || !const_type.getElementType().isSignlessInteger(4) || !result_type || !result_type.getElementType().isSignlessInteger(8)) { return failure(); } auto input_op = dyn_cast<arith::ConstantOp>(op.getOperand(0).getDefiningOp()); if (!input_op) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/dense_to_sparse.cc
int num_elements = type.getNumElements(); int num_zeros = 0; if (mlir::isa<FloatType>(type.getElementType())) { for (const auto val : attr.getValues<APFloat>()) { if (val.isZero()) { num_zeros++; } } } else if (mlir::isa<quant::QuantizedType>(type.getElementType())) { for (const auto val : attr.getValues<int8_t>()) { if (val == 0) { num_zeros++; }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 16.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/uniform_quantized_stablehlo_to_tfl_pass.cc
return failure(); } if (!IsI8F32UniformQuantizedPerAxisType(filter_type.getElementType())) { LLVM_DEBUG(llvm::dbgs() << "Expected a per-channel uniform quantized " "(i8->f32) type filter. Got: " << filter_type.getElementType() << "\n"); return failure(); }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Apr 22 09:00:19 UTC 2024 - 99.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/unroll_batch_matmul.cc
// Skip int8 x int8 => int32. if (lhs_type.getElementType().isInteger(8) && rhs_type.getElementType().isInteger(8)) { return rewriter.notifyMatchFailure(op, "skip unrolling for int8 BatchMatMulV3"); } auto element_type = lhs_type.getElementType(); if (element_type != rhs_type.getElementType()) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 11.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/utils/side_effect_analysis_util.cc
return device_attr.str(); } void MarkResourceAsReadAndWrite( Value value, SmallVectorImpl<SideEffects::EffectInstance<MemoryEffects::Effect>>& effects) { if (value.getType().cast<TensorType>().getElementType().isa<ResourceType>()) { effects.emplace_back(MemoryEffects::Read::get(), value, ResourceEffects::Variable::get()); effects.emplace_back(MemoryEffects::Write::get(), value,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Nov 16 00:33:17 UTC 2023 - 2.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/constant_fold.cc
// Ignore types with undefined bit widths. if (!tensor_type.getElementType().isIntOrFloat()) continue; if (!tensor_type.hasStaticShape()) { has_unknown_shape = true; return size; } size += tensor_type.getNumElements() * tensor_type.getElementType().getIntOrFloatBitWidth(); } return size; };
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.3K bytes - Viewed (0)