- Sort Score
- Result 10 results
- Languages All
Results 41 - 50 of 122 for eraseOp (0.15 sec)
-
tensorflow/compiler/mlir/lite/transforms/reduce_while_operands.cc
!cond.getArgument(i).use_empty()) { explicitly_consumed_ids.push_back(i); } } // Empty consumed_element_ids implies none of results is used. if (explicitly_consumed_ids.empty()) { while_op.erase(); return true; } // If every element is consumed, one can't reduce any operand. if (explicitly_consumed_ids.size() == n) { return false; } // Build the dependency graph.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 10.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/tensor_device_copy_conversion.cc
StringAttr op_device = op->getAttrOfType<StringAttr>(kDeviceAttr); if (should_fold_op_func(op.getOperand(), op_device)) { op.replaceAllUsesWith(op.getOperand()); op.erase(); } return WalkResult::advance(); }); func_op.walk([&should_fold_op_func](TF::IdentityNOp op) { StringAttr op_device = op->getAttrOfType<StringAttr>(kDeviceAttr); bool should_fold = llvm::all_of(
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 4.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/resource_op_lifting_cleanup.cc
return std::get<TF::MlirLocalVarOp>(op).getResource(); } } void LocalVarOp_erase(LocalVarOp &op) { if (auto var_handle_op = std::get_if<TF::VarHandleOp>(&op)) { var_handle_op->erase(); } else { std::get<TF::MlirLocalVarOp>(op).erase(); } } std::optional<LocalVarOp> IsLocalVarOp(Operation &op) { if (TF::MlirLocalVarOp mlir_local_var_op = llvm::dyn_cast<TF::MlirLocalVarOp>(&op)) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 19.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/promote_resources_to_args.cc
block.eraseArgument(argument_index_to_remove); argument_types.erase(argument_types.begin() + argument_index_to_remove); } // Rewrite return if there are variable writes. const int return_operands_size = return_operands.size(); if (return_operands_size > num_results_before) { builder.create<func::ReturnOp>(return_op.getLoc(), return_operands); return_op.erase(); }
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/tensorflow/transforms/tf_saved_model_asset_sinking_pass.cc
} // Clean up unused asset ops. for (auto asset : llvm::make_early_inc_range(module.getOps<AssetOp>())) { if (symbol_table.symbolKnownUseEmpty(asset, module)) { asset.erase(); } } } private: // Replaces bounded-input arguments of the function with constant ops in the // body and removes the arguments.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/executor_tpuv1_island_coarsening.cc
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 17 17:58:54 UTC 2024 - 27.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/optimize_global_tensors.cc
continue; } // If the tensor is bound to an argument, then it is used. if (global_tensor_uses.find(global_tensor) != global_tensor_uses.end()) { continue; } // Erase it. global_tensor.erase(); } } void EraseUnusedBoundInputs(ModuleOp module) { for (auto func : module.getOps<func::FuncOp>()) { llvm::BitVector args_to_erase(func.getNumArguments());
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/tensorflow/transforms/tpu_annotate_dynamic_shape_inputs.cc
std::get<1>(result).replaceAllUsesWith(std::get<0>(result)); } launch_ops.insert(op->getParentOfType<tf_device::LaunchOp>()); op->erase(); } return WalkResult::advance(); }); for (auto launch_op : launch_ops) { Block& block = launch_op.GetBody(); if (&block.front() == &block.back()) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 6.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/python/pywrap_quantize_model.cc
// for CPU. Note the 'tpu' value should be the same as `TPU` defined in // tensorflow/python/saved_model/tag_constants.py. if (quantization_options.has_debugger_config()) { tags.erase("tpu"); } py_function_library.SaveExportedModel( dst_saved_model_path, *exported_model, src_saved_model_path, tags, signature_def_map); return absl::OkStatus(); },
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Apr 09 06:33:29 UTC 2024 - 12K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/merge_initializer_function_ops_to_main.cc
} GraphOp main_graph_op = GetGraphOpFromFuncOp(main_func_op); FetchOp main_fetch_op = main_graph_op.GetFetch(); const absl::Cleanup erase_main_fetch_op = [main_fetch_op]() mutable { main_fetch_op.erase(); }; // TODO(b/245473863): Handle when assets are actually used in the body. IRMapping mapper = CloneSrcFuncArgumentsToMainFunc(src_func_op, main_func_op); // Clones each op from src to main_body.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sun May 12 12:54:52 UTC 2024 - 15.3K bytes - Viewed (0)