- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 43 for ReplaceOpWithNewOp (0.32 sec)
-
tensorflow/compiler/mlir/lite/transforms/post_quantize.cc
if (auto qtype = quant::QuantizedType::getQuantizedElementType( q.getInput().getType())) { rewriter.setInsertionPoint(op); rewriter.replaceOpWithNewOp<DequantizeOp>(op, op.getOutput().getType(), q.getInput()); return success(); } op.replaceAllUsesWith(q.getInput());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 17.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/lower_static_tensor_list.cc
tensorflow::TensorShape(result_shape)); auto attr_or = tensorflow::ConvertTensor(tensor, &rewriter); if (!attr_or.ok()) return failure(); rewriter.replaceOpWithNewOp<TF::ConstOp>(op, attr_or.value()); return success(); } // Extract individual tensor list element and combine them using the tf.Pack // op. Location loc = op.getLoc();
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/stablehlo/passes/xla_call_module_to_call.cc
symbol_table.lookup(GetEntryFunctionName(op))); if (!entry_func_op) return failure(); // Replace the XlaCallModuleOp with a new CallOp. rewriter.replaceOpWithNewOp<func::CallOp>(op, entry_func_op, op.getArgs()); return success(); } }; void XlaCallModuleToCallPass::runOnOperation() { ModuleOp module_op = getOperation(); MLIRContext* ctx = module_op.getContext();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 04 20:02:00 UTC 2024 - 3.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_hlo_conversions/scatter.h
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 10.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/batchmatmul_to_einsum.cc
std::string equation("...mk,...kn->...mn"); if (op.getAdjX()) std::swap(equation[3], equation[4]); if (op.getAdjY()) std::swap(equation[6 + 3], equation[6 + 4]); rewriter.replaceOpWithNewOp<TF::EinsumOp>( op, op.getType(), /*inputs=*/ValueRange({input_lhs, input_rhs}), /*equation=*/equation); return success(); } }; #define GEN_PASS_DEF_BATCHMATMULTOEINSUMPASS
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/quantization/stablehlo/passes/convert_func_to_bfloat16.cc
const Value output = rewriter.create<mlir::stablehlo::BitcastConvertOp>( op->getLoc(), op.getResult().getType(), adaptor.getOperand()); rewriter.replaceOpWithNewOp<mlir::stablehlo::ConvertOp>( op, getTypeConverter()->convertType(op.getResult().getType()), output); } else if (is_output_legal) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 9.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/quantization/ir/ConvertConst.cc
{qbarrier.getArg().getDefiningOp()->getLoc(), qbarrier.getLoc()}); auto newConstOp = rewriter.create<arith::ConstantOp>( fusedLoc, newConstValueType, cast<TypedAttr>(newConstValue)); rewriter.replaceOpWithNewOp<StorageCastOp>(qbarrier, qbarrier.getType(), newConstOp); return success(); } void ConvertConstPass::runOnOperation() {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 4.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/tfr/ir/tfr_ops.cc
auto new_tfr_cast = rewriter.create<TFR::CastOp>( cast_op.getLoc(), output_tensor_type.clone(input_tensor_type.getElementType()), cast_op.getArg()); rewriter.replaceOpWithNewOp<TF::CastOp>(cast_op, output_type, new_tfr_cast); return success(); } // If the two types are the same, the back-to-back tfr.cast ops can be
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Nov 21 16:55:41 UTC 2023 - 38.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/post_quantize.cc
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Mar 05 07:39:40 UTC 2024 - 5.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/odml_converter/folders.cc
return failure(); } res.push_back(signed_lhs_val / signed_rhs_val); } auto res_attr = DenseElementsAttr::get( const_oprs[0].getType().cast<RankedTensorType>(), res); rewriter.replaceOpWithNewOp<stablehlo::ConstantOp>(adaptor.value().Op(), res_attr); return success(); } static LogicalResult FoldDivOp(stablehlo::DivOp op, PatternRewriter& rewriter) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed May 08 06:11:55 UTC 2024 - 4.5K bytes - Viewed (0)