- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 43 for DenseFPElementsAttr (0.25 sec)
-
tensorflow/compiler/mlir/lite/quantization/ir/QuantizeUtils.cc
} return nullptr; } /// Converts a real expressed DenseFPElementsAttr to a corresponding /// DenseElementsAttr (typically DenseIntElementsAttr) containing quantized /// storage values assuming the given quantizedElementType and converter. static DenseElementsAttr convertDenseFPElementsAttr( DenseFPElementsAttr realFPElementsAttr, quant::QuantizedType quantizedElementType,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 6.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/prepare_quantize_dynamic_range.cc
op->getOperand(qi).getDefiningOp()); if (!const_op) { continue; } DenseFPElementsAttr attr; if (!matchPattern(const_op->getResult(0), m_Constant(&attr))) { continue; } if (mlir::dyn_cast<DenseFPElementsAttr>(attr).size() >= quant_specs_.minimum_elements_for_weights) { continue; }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 20.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/ir/UniformSupport.cc
} ElementsAttr UniformQuantizedPerAxisValueConverter::convert( Attribute real_value) { if (auto attr = dyn_cast<DenseFPElementsAttr>(real_value)) { return convert(attr); } return nullptr; } DenseElementsAttr UniformQuantizedPerAxisValueConverter::convert( DenseFPElementsAttr attr) { // Creates the converter for each chunk. Normally the size of the
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 08 02:10:16 UTC 2024 - 4.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/quantize_weight.cc
if (!new_result_type.getElementType().isF16()) continue; // Convert values. std::vector<Eigen::half> new_values; const DenseFPElementsAttr value_attr = mlir::cast<DenseFPElementsAttr>(op.getValue()); new_values.reserve(value_attr.getNumElements()); for (const float value : value_attr.getValues<float>()) { new_values.push_back(Eigen::half(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 9.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/fold_constant_transpose.cc
return success( mlir::isa_and_nonnull<DenseFPElementsAttr>(const_op.getValue())); } void rewrite(mlir::stablehlo::TransposeOp op, PatternRewriter& rewriter) const override { auto const_op = cast<mlir::stablehlo::ConstantOp>(op.getOperand().getDefiningOp()); const auto value_attr = mlir::cast<DenseFPElementsAttr>(const_op.getValue());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/ops/tf_quantize_op.cc
// Currently, support symmetric, per-tensor, signed int8 const bool kIsNarrowRange = true; const bool kIsSigned = true; const int kBitWidth = 8; DenseFPElementsAttr attr; if (!matchPattern(op->getResult(0), m_Constant(&attr))) return nullptr; QuantizedType quant_type = mlir::dyn_cast<quant::QuantizedType>( quant::GetUniformQuantizedTypeForWeight(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 11K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/composite_avg_pool.h
// Get dense attr for a matrix that corrects the over counting of divisors when // casting an average pool with ceil mode on in terms of average pool with it // off. DenseFPElementsAttr GetCorrectionMatrix(Builder& builder, mhlo::CompositeOp op); } // namespace odml } // namespace mlir
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 28 23:16:05 UTC 2024 - 2.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/quantization_lib/quantization_utils.cc
const bool use_fake_quant_num_bits) { SmallVector<double, 4> min_value, max_value; const auto mins = dyn_cast<DenseFPElementsAttr>(min); const auto maxs = dyn_cast<DenseFPElementsAttr>(max); if (mins && maxs) { min_value.reserve(mins.getNumElements()); max_value.reserve(maxs.getNumElements()); for (auto it = mins.begin(); it != mins.end(); ++it) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 08 02:10:16 UTC 2024 - 43.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/prepare_quantize_helper.h
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 03 18:01:23 UTC 2024 - 28K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/quantization/import_quant_stats_pass.cc
ElementsAttr layer_stats = DenseFPElementsAttr::get( RankedTensorType::get({2}, b.getF32Type()), {min_maxs[0], min_maxs[1]}); ElementsAttr axis_stats; IntegerAttr axis; if (info.params_size() > 1) { SmallVector<int64_t, 4> axis_stats_shape{info.params_size(), 2}; axis_stats = DenseFPElementsAttr::get( RankedTensorType::get(axis_stats_shape, b.getF32Type()), min_maxs);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Mar 08 10:41:08 UTC 2024 - 9.9K bytes - Viewed (0)