- Sort Score
- Result 10 results
- Languages All
Results 131 - 140 of 271 for getOperation (0.56 sec)
-
tensorflow/compiler/mlir/lite/transforms/dense_to_sparse.cc
}; void DenseToSparsePass::runOnOperation() { func::FuncOp func = getOperation(); OpBuilder builder(func); func.walk([&](SparseOpInterface sparse_op) { const auto& sparse_operands = sparse_op.GetSparseOperands(); std::vector<std::vector<int>> supported_block_size; for (int operand : sparse_operands) { auto* op = sparse_op.getOperation(); auto value = op->getOperand(operand);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 16.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/insert_main_function.cc
StringRef attr_name = attr.getName().getValue(); if (attr_name.starts_with("tf_saved_model.")) { func->removeAttr(attr_name); } } auto iface = cast<FunctionOpInterface>(func.getOperation()); for (int i = 0; i < func.getNumArguments(); ++i) { for (auto& attr : iface.getArgAttrs(i)) { const StringAttr& attr_name = attr.getName(); if (attr_name.getValue().starts_with("tf_saved_model.")) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 16.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/optimize_global_tensors.cc
args_to_erase.set(i); } } func.eraseArguments(args_to_erase); } } void OptimizeGlobalTensorsPass::runOnOperation() { auto module = getOperation(); if (!tf_saved_model::HasTfSavedModelSemantics(module)) { return; } EraseUnusedBoundInputs(module); TF::ResourceAnalyzer resource_analyzer(module);
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/quantization/stablehlo/passes/post_quantize.cc
q_op, q_op.getResult().getType(), q_op.getArg()); return success(); } }; void PostQuantizePass::runOnOperation() { RewritePatternSet patterns(&getContext()); func::FuncOp func = getOperation(); MLIRContext* ctx = func.getContext(); // TODO: b/307463853 - Consider splitting passes for each pattern set. patterns.add<FoldTrivalRequantizeOp<quantfork::QuantizeCastOp>,
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Mar 05 07:39:40 UTC 2024 - 6.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/insert_calibration_statistics_saver.cc
InsertCalibrationStatisticsSaverPassBase; private: void runOnOperation() override; }; void InsertCalibrationStatisticsSaverPass::runOnOperation() { ModuleOp module_op = getOperation(); MLIRContext& ctx = getContext(); std::unordered_set<std::string> aggregator_ops_to_ignore( aggregator_ops_to_ignore_.begin(), aggregator_ops_to_ignore_.end());
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 14 06:31:57 UTC 2024 - 7.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/debugging/mlir_dump_test.cc
ParentPass() = default; llvm::StringRef getArgument() const final { return "parent-pass"; } void runOnOperation() override { mlir::MLIRContext* ctx = &getContext(); mlir::ModuleOp module_op = getOperation(); mlir::PassManager pm(ctx); pm.addPass(CreateNoOpPass()); EnableIrPrinting(pm, "dump2"); if (failed(pm.run(module_op))) { signalPassFailure(); } } };
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Feb 14 03:17:14 UTC 2024 - 6.4K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/legalize_stablehlo_composite_to_tfl_custom.cc
LegalizeCompositeToCustomOpPass> { using LegalizeCompositeToCustomOpPassBase:: LegalizeCompositeToCustomOpPassBase; void runOnOperation() override { func::FuncOp fn = getOperation(); int num_layers = 0, current_layer_index = 0; // First walk the function to count number of KV Caches. fn.walk([&](Operation* op) { auto composite = llvm::dyn_cast<stablehlo::CompositeOp>(op);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 6.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/split_merged_operands.cc
return failure(); } } return success(); } void SplitMergedOperandsPass::runOnOperation() { llvm::DenseSet<Value> stateful_values; auto func = getOperation(); OpBuilder builder(func); for (auto& bb : func.getBody()) { for (auto& op : bb) { if (failed(DuplicateValueIfNeeded(&op, &stateful_values, &builder))) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Apr 24 20:30:06 UTC 2024 - 5.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/tf_saved_model_asset_sinking_pass.cc
AssetSinkingPass() = default; explicit AssetSinkingPass(llvm::StringRef saved_model_dir) { saved_model_dir_ = saved_model_dir.str(); } void runOnOperation() override { ModuleOp module = getOperation(); if (!HasTfSavedModelSemantics(module)) { return; } auto init_op = GetSessionInitializerOp(module); if (init_op == nullptr || init_op.getInitializers().empty()) { return; }
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/quantization/tensorflow/passes/propagate_quantize_type.cc
} changed = true; } return changed ? success() : failure(); } }; void PropagateQuantizeType::runOnOperation() { RewritePatternSet patterns(&getContext()); auto module_op = getOperation(); MLIRContext* ctx = &getContext(); patterns.add<PropagateDequantizeOpIfAllowed>(ctx); FrozenRewritePatternSet frozen_patterns(std::move(patterns));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7K bytes - Viewed (0)