- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 86 for StringAttr (0.13 sec)
-
tensorflow/compiler/mlir/lite/experimental/tac/transforms/get_alternative_subgraph.cc
} SmallVector<func::FuncOp, 25> funcs_to_be_processed; // We only process if func has device annotations. for (auto func : module.getOps<func::FuncOp>()) { auto device_attr = func->getAttrOfType<StringAttr>(kDevice); if (device_attr != nullptr) funcs_to_be_processed.push_back(func); } OpBuilder builder(module); // Go head to process those funcs.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Jun 06 03:08:33 UTC 2023 - 12.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/translate/tf_mlir_translate.cc
} auto& module = module_or.value(); std::srand(0); for (auto fn : module->getOps<mlir::func::FuncOp>()) { for (auto& bb : fn) { for (auto& inst : bb) { auto attr_id = mlir::StringAttr::get(context, "value"); if (auto attr = inst.getAttrOfType<mlir::ElementsAttr>(attr_id)) { mlir::Attribute rand_val; mlir::Type element_type = attr.getShapedType().getElementType();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue May 07 11:51:44 UTC 2024 - 14.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/convert_control_to_data_outputs.cc
TF::detail::ResourceAliasAnalysisInfo::kInvalidResourceId; using OperationSetTy = SmallPtrSet<Operation*, 4>; using ResourceToOpsMapTy = DenseMap<ResourceAndDevice, OperationSetTy>; using DeviceMap = DenseMap<StringAttr, int64_t>; constexpr int64_t kAnyDevice = 0; constexpr ResourceAndDevice kInvalidResourceAndDevice{kInvalidResourceId, kAnyDevice};
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 28.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/cluster_ops_by_policy.cc
// Create `tf_device.cluster` operation from the discovered ops cluster. // -------------------------------------------------------------------------- // tf_device::ClusterOp CreateClusterOp(Cluster &cluster, StringAttr policy) { // Find all the values that are used outside of the cluster. These values // will be returned from the created cluster operation. llvm::DenseSet<Operation *> in_cluster;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 27.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/region_control_flow_to_functional.cc
// and outline the `then` and `else` regions by moving the bodies of these // regions into these functions. Replace tf.yield with a regular return. if (if_region->hasAttrOfType<StringAttr>(kThenFuncNameAttr) && !if_region.get_thenFuncNameAttr().getValue().empty()) { then_name = mapper.GetUniqueName(if_region.get_thenFuncNameAttr().getValue()) .str(); } else {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 28.7K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/prepare_lifting.cc
bool is_supported_affine_op = false; if (llvm::isa<TF::Conv2DOp, TF::Conv3DOp, TF::DepthwiseConv2dNativeOp>(op)) { if (const auto data_format = op->getAttrOfType<StringAttr>("data_format")) { is_supported_affine_op = data_format.getValue() == "NHWC" || data_format.getValue() == "NDHWC"; } } else if (llvm::isa<TF::BatchMatMulV2Op>(op)) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri May 17 17:58:54 UTC 2024 - 13.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/tests/tf_saved_model_ops_invalid.mlir
// ----- module attributes {tf_saved_model.semantics} { "tf_saved_model.session_initializer"() { initializers = [@init] } : () -> () // expected-error@+1 {{tf_saved_model.initializer_type should be a StringAttr}} func.func @init() attributes { tf_saved_model.exported_names = ["__tf_saved_model_session_initializer"], tf_saved_model.initializer_type = 123 } { func.return } } // -----
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Oct 19 13:38:14 UTC 2022 - 14.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/tfrt/ir/tfrt_fallback_async.cc
rewriter .create<fallback_async::CoreRTTensorHandleToFallbackTensorOp>( op.getLoc(), rewriter.getType<fallback::TFTensorType>(), operand, op->getAttrOfType<mlir::StringAttr>("device")) .getResult(0)); } if (!should_rewrite) return failure(); rewriter.replaceOp(op, new_values); return success(); } };
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Jun 08 01:19:25 UTC 2023 - 15.6K bytes - Viewed (0) -
tensorflow/compiler/mlir/tensorflow/transforms/cluster_ops_by_policy.h
std::function<bool(Operation* op)> filter = {}); // Creates a `tf_device.cluster` operation from the clustered operations. tf_device::ClusterOp CreateClusterOp(Cluster& cluster, StringAttr policy = {}); // -------------------------------------------------------------------------- // // Helper functions for value constraints propagations and analysis.
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Mar 03 03:47:00 UTC 2023 - 12.1K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/unfreeze_constants.cc
// matches `initializer_type`. bool IsInitializerType(func::FuncOp init_func_op, StringRef initializer_type) { auto init_type = init_func_op->getAttrOfType<StringAttr>(kTfSavedModelInitializerTypeAttr); return init_type && init_type == initializer_type; } // Returns the initializer function whose tf_saved_model.initializer_type
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Aug 16 15:04:53 UTC 2023 - 14K bytes - Viewed (0)