- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 175 for getOps (0.1 sec)
-
tensorflow/compiler/mlir/quantization/stablehlo/passes/insert_calibration_statistics_saver.cc
const std::unordered_set<std::string>& aggregator_ops_to_ignore, SmallVector<Value>& statistics_outputs, SmallVector<StringRef>& ids, SmallVector<int32_t>& calibration_methods) { for (auto op : region.getOps<TF::CustomAggregatorOp>()) { if (aggregator_ops_to_ignore.count(op.getId().str())) continue; ids.push_back(op.getId()); calibration_methods.push_back(op.getCalibrationMethod());
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/common/lift_as_function_call_test.cc
ASSERT_TRUE(module_op); func::FuncOp main_fn = FindMainFuncOp(*module_op); ASSERT_THAT(main_fn, NotNull()); auto xla_call_module_ops = main_fn.getOps<TF::XlaCallModuleOp>(); ASSERT_FALSE(xla_call_module_ops.empty()); // Test that `GetQuantizationMethod` returns a valid `Method` corresponding to // `"no_quantization {}"`. const absl::StatusOr<Method> method =
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 10 04:07:09 UTC 2024 - 26.2K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/cc/pre_calibration_test.cc
component.Run(*module_op, quantization_config); EXPECT_THAT(pre_calibration_result, IsOk()); SmallVector<func::FuncOp> func_ops; for (auto func_op : pre_calibration_result->getOps<func::FuncOp>()) { func_ops.push_back(func_op); } ASSERT_THAT(func_ops, SizeIs(2)); EXPECT_THAT(func_ops, Contains(HasSymName("main")));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Mar 28 21:41:08 UTC 2024 - 6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/mark_initialized_variables.cc
absl::StrCat("failed to fetch device manager: ", status.message())); // Fetch all varHandleOp in the function. llvm::SmallVector<TF::VarHandleOp, 4> var_ops; for (auto var_handle_op : block.getOps<TF::VarHandleOp>()) var_ops.emplace_back(var_handle_op); // Get resources from Session. auto resource_tensors_or = GetResourcesFromSession(var_ops, session); if (!resource_tensors_or.ok())
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 13 19:14:56 UTC 2023 - 4.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/optimize_global_tensors.cc
} } return true; } GlobalTensorUsesMap CreateGlobalTensorUsesMap(ModuleOp module) { GlobalTensorUsesMap global_tensor_uses; SymbolTable symbol_table(module); for (auto func : module.getOps<func::FuncOp>()) { for (size_t i = 0, e = func.getNumArguments(); i < e; i++) { auto sym = func.getArgAttrOfType<SymbolRefAttr>(i, "tf_saved_model.bound_input"); if (!sym) { continue;
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/common/attrs_and_constraints_test.cc
ParseModuleOpString(kModuleDotGeneralFullyConnected); ASSERT_TRUE(module_op); func::FuncOp main_fn = FindMainFuncOp(*module_op); ASSERT_THAT(main_fn, NotNull()); auto dot_general_op = *main_fn.getOps<DotGeneralOp>().begin(); EXPECT_THAT(IsDotGeneralFullyConnected(dot_general_op), true); } TEST_F(AttrsAndConstraintsTest, IsDotGeneralFullyConnectedReturnsFalse) { OwningOpRef<ModuleOp> module_op =
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 14 17:10:32 UTC 2024 - 22.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/stablehlo/passes/unwrap_xla_call_module_op.cc
call_op.getOperands())) { arg_mapper.map(func_arg, operand); } Region& function_body = func_op.getBody(); IRMapping new_op_mapper; for (Operation& op : function_body.getOps()) { if (llvm::isa<func::ReturnOp>(op)) { for (auto [call_result, return_value] : llvm::zip_equal(call_op.getResults(), op.getOperands())) { Value new_result = new_op_mapper.lookup(return_value);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Mar 05 07:39:40 UTC 2024 - 4.8K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/trim_functions_tf.cc
// if no trim_funcs_allowlist_ is specified, this pass is a no-op. if (trim_funcs_allowlist_.empty()) return false; llvm::SmallVector<func::FuncOp, 4> funcs_to_trim; for (auto func : getOperation().getOps<func::FuncOp>()) { if (llvm::is_contained(trim_funcs_allowlist_, func.getName())) { // If no main is specified in the allowlist, use the 1st func // in trim_funcs_allowlist as the main.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Oct 07 21:08:41 UTC 2022 - 4.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/init_text_file_to_import_test_pass.cc
temp_file.os().flush(); // Replace filename constant ops to use the temporary file. MLIRContext* context = &getContext(); for (func::FuncOp func : module.getOps<func::FuncOp>()) { llvm::SmallVector<arith::ConstantOp, 4> constant_ops( func.getOps<arith::ConstantOp>()); for (auto op : constant_ops) { ShapedType shaped_type = RankedTensorType::get({1}, StringType::get(context));
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Oct 04 09:19:38 UTC 2022 - 5.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/freeze_global_tensors.cc
TF::LoadResourceDataflowAnalysis(solver); if (failed(solver.initializeAndRun(module))) return signalPassFailure(); DenseSet<GlobalTensorOp> remaining_global_tensor_ops; { auto ops = module.getOps<GlobalTensorOp>(); remaining_global_tensor_ops.insert(ops.begin(), ops.end()); } for (auto global_tensor : remaining_global_tensor_ops) { // This pass assumes that all global tensors as immutable (e.g. by a
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 7.8K bytes - Viewed (0)