- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 51 for use_empty (0.22 sec)
-
tensorflow/compiler/mlir/tensorflow/transforms/sink_constant.cc
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Nov 03 12:35:38 UTC 2022 - 4.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/optimize_global_tensors.cc
llvm::BitVector args_to_erase(func.getNumArguments()); for (int i = 0, e = func.getNumArguments(); i < e; i++) { if (func.getArgAttr(i, "tf_saved_model.bound_input") && func.getArgument(i).use_empty()) { args_to_erase.set(i); } } func.eraseArguments(args_to_erase); } } void OptimizeGlobalTensorsPass::runOnOperation() { auto module = getOperation();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 5.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/tfr/passes/canonicalize.cc
mapping.map(std::get<0>(iter_op), std::get<1>(iter_op)); } mapping.map(iv, for_op.getLowerBound()); for (auto i = 0; i < trip_count; ++i) { if (!iv.use_empty()) { // iv' = iv + step * i; Value iter = rewriter.create<arith::ConstantIndexOp>(loc, i); Value step_cst = rewriter.create<arith::ConstantIndexOp>(loc, step.getSExtValue());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Jan 14 22:15:06 UTC 2023 - 6.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/replicate_to_island.cc
// Add sink island to pin all replicas as a control dependency if there is a // control dependency leading from the replicate originally. if (!island_op.getControl().use_empty()) { llvm::SmallVector<Value, 8> island_operands; for (auto& replica : replicas) island_operands.push_back(replica.getControl()); builder.setInsertionPoint(island_op);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Mon Jul 24 21:01:40 UTC 2023 - 16.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/tests/canonicalize.mlir
// CHECK: return %0#1 : tensor<f32> func.return %0#1 : tensor<f32> } // ----- // Test case to test bug due to checking // `while_op.getResult(arg_index).use_empty()` instead of // `while_op.getResult(while_index).use_empty()` in the tfl.while // canonicalization. // arg0 is a pass through. After first iteration, arg_index = 0 // and while_index = 1. Make arg1 use empty in block and condition, but not in
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu May 02 09:41:17 UTC 2024 - 20.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/optimize_functional_ops.cc
func::FuncOp else_func = op.else_function(); // If the If has no uses and its functions are side-effect free, then // remove. // TODO(jpienaar): Remove once recusive side-effects are supported. if (op.use_empty() && (op.getIsStateless() || (IsSideEffectFree(then_func) && IsSideEffectFree(else_func)))) { rewriter.eraseOp(op.getOperation()); return success(); }
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 6.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/readonly_references_to_resources.cc
// directly. auto read_only_vars_fn = [&variable_v2s_to_replace]( VariableV2Op variable_v2_op) { if (variable_v2_op.getResult().use_empty()) { // Erase the op when there is no user. variable_v2_op.erase(); return mlir::WalkResult::advance(); } if (!all_of(variable_v2_op.getResult().getUsers(), [&variable_v2_op](
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/prepare_tf.cc
return failure(); if (!(((*root.getODSResults(1).begin()).use_empty()))) { return rewriter.notifyMatchFailure( fused_batch_norm_op, [&](::mlir::Diagnostic &diag) { diag << "entities '' failed to satisfy constraint: has no use"; }); } if (!(((*root.getODSResults(2).begin()).use_empty()))) { return rewriter.notifyMatchFailure(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 28 21:49:50 UTC 2024 - 64.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/experimental/tac/transforms/device_transform.cc
LogicalResult matchAndRewrite(TFL::QuantizeOp quant_op, PatternRewriter& rewriter) const override { if (!quant_op.getResult().use_empty()) return failure(); rewriter.eraseOp(quant_op); return success(); } }; void OptimizeQuantizedOpToFloat(func::FuncOp func, MLIRContext* context) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 8.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/quantize_weight.cc
for (Operation* connected_op : op.getResult().getUsers()) { ConvertOp convert_op = dyn_cast_or_null<ConvertOp>(connected_op); // Skip if no convert op exists. if (!convert_op || convert_op.getResult().use_empty()) continue; // Get types. const Type old_result_type = op.getResult().getType(); const ShapedType new_result_type = mlir::dyn_cast<ShapedType>(convert_op.getType());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 9.9K bytes - Viewed (0)