- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 71 for FloatType (0.29 sec)
-
tensorflow/compiler/mlir/quantization/common/ir/UniformSupport.h
static_cast<double>(uniform_type.getStorageTypeMax()), uniform_type.getStorageTypeIntegralWidth(), uniform_type.isSigned()) { assert(isa<FloatType>(uniform_type.getExpressedType())); assert(uniform_type.getStorageType().isSignlessInteger()); } UniformQuantizedValueConverter(double scale, double zero_point,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 08 02:10:16 UTC 2024 - 9.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/tflite_import_export.cc
cost = target_hardware->GetOpCost(op); } mlir::StringAttr device_identifier = mlir::StringAttr::get(module.getContext(), device); auto float_type = mlir::FloatType::getF32(module.getContext()); auto float_attr = mlir::FloatAttr::get(float_type, static_cast<float>(cost)); device_costs.push_back({device_identifier, float_attr}); }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 08 01:19:25 UTC 2023 - 4.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/common/ir/UniformSupport.cc
#include "mlir/IR/Types.h" // from @llvm-project #include "mlir/Support/LLVM.h" // from @llvm-project namespace mlir::quantfork { static bool isQuantizablePrimitiveType(Type input_type) { return isa<FloatType>(input_type); } ExpressedToQuantizedConverter ExpressedToQuantizedConverter::forInputType( Type input_type) { if (isa<TensorType, VectorType>(input_type)) {
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/utils/tf_type_utils_test.cc
{2, 2}, quant::UniformQuantizedType::get( quant::QuantizationFlags::FlagValue::Signed, IntegerType::get(context.get(), 8), FloatType::getF32(context.get()), 3.0, 2, -128, 127)); auto dense_attr = GetDenseAttrFromTensorProtoAttr(GetQint8Tensor(), result_tensor_type); ASSERT_TRUE(succeeded(dense_attr));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 9K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/quantization/quantization_context.cc
// Use the final state to set all the operands' parameters. for (int i = 0, e = op->getNumOperands(); i != e; ++i) { auto ele = op->getOperand(i).getType().cast<ShapedType>().getElementType(); if (ele.isa<FloatType>() && SetOperandParams(op, i, params)) { *changed |= true; new_items->push_back(op->getOperand(i).getDefiningOp()); } } // Use the final state to set all the results' parameters.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Apr 08 01:38:03 UTC 2024 - 13.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/odml_converter/folders.cc
return success(); } static LogicalResult FoldDivOp(stablehlo::DivOp op, PatternRewriter& rewriter) { auto etype = op.getType().getElementType(); if (etype.isa<FloatType>()) { return FoldDivOpInternal<APFloat>(op, rewriter); } if (etype.isa<IntegerType>()) { return FoldDivOpInternal<APInt>(op, rewriter); } return failure(); } } // namespace
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 08 06:11:55 UTC 2024 - 4.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/ir/tf_ops_tensor_helper.h
// Returns true if the given `value` is of ranked float tensor type with the // given `rank`. inline bool IsOfRankedFloatTensorType(RankedTensorType type, int rank) { return type && type.getRank() == rank && mlir::isa<FloatType>(type.getElementType()); } // Returns true if the given `value` has the specified rank or has unranked // type. inline bool IsOfRankOrUnranked(Value value, int64_t rank) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 3.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/reduce.h
// as the reduction. Value iota = reduce_op.getInputs().back(); if (!MatchIota(reduce_op.getDimensions(), iota)) return failure(); // Match the reduction computation. const bool is_float = mlir::isa<FloatType>(operand_init.getElementType()); if (failed(MatchReduceToArgMinMaxType1(reduce_op, is_float, is_argmax)) && failed(MatchReduceToArgMinMaxType2(reduce_op, is_argmax))) return rewriter.notifyMatchFailure(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.7K bytes - Viewed (0) -
tensorflow/cc/experimental/base/tests/tensor_test.cc
#include "tensorflow/core/platform/test.h" namespace { using tensorflow::experimental::cc::Status; using tensorflow::experimental::cc::Tensor; using SimpleTypes = ::testing::Types< tensorflow::FloatType, tensorflow::DoubleType, tensorflow::Int32Type, tensorflow::UINT8Type, tensorflow::INT8Type, tensorflow::INT64Type, tensorflow::UINT16Type, tensorflow::UINT32Type, tensorflow::UINT64Type>; template <typename T>
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Apr 13 09:56:08 UTC 2024 - 6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/ir/tf_arith_ops_folder.h
std::is_same<OpT, RealDivOp>::value) ? 1 : 0; Type element_ty = lhs_type.getElementType(); Attribute identity_attr; if (auto ty = mlir::dyn_cast<FloatType>(element_ty)) { identity_attr = FloatAttr::get(ty, static_cast<double>(identity)); } else if (auto ty = mlir::dyn_cast<IntegerType>(element_ty)) { identity_attr = IntegerAttr::get(ty, static_cast<int64_t>(identity));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.3K bytes - Viewed (0)