Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 92 for getOps (0.1 sec)

  1. tensorflow/compiler/mlir/quantization/tensorflow/passes/lift_hashtable_ops_as_args.cc

      if (shared_name.empty()) return false;
    
      for (func::FuncOp init_func_op :
           tf_saved_model::GetInitializerFunctions(module_op)) {
        for (Operation& op : init_func_op.getBody().getOps()) {
          StringRef other_shared_name = GetSharedName(&op);
          if (IsHashTableOp(&op) && other_shared_name == shared_name) {
            return true;
          }
        }
      }
      return false;
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/lift_variables.cc

      mlir::Builder builder(context);
      StringAttr resource_name_id = builder.getStringAttr(kResourceNameArgAttr);
    
      SmallSet<StringRef, 4> resource_names;
    
      for (func::FuncOp func : module.getOps<func::FuncOp>()) {
        for (int i = 0, e = func.getNumArguments(); i < e; ++i) {
          auto resource_arg =
              func.getArgAttrOfType<StringAttr>(i, kResourceNameArgAttr);
          if (!resource_arg) continue;
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 23 09:05:47 UTC 2024
    - 7.9K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/stablehlo/passes/replace_stablehlo_ops_in_main_function_with_xla_call_module_ops.cc

        if (!main_func) continue;
    
        SymbolTable symbol_table(module_op);
        for (auto call_op : main_func.getOps<TF::PartitionedCallOp>()) {
          func_ops.push_back(dyn_cast_or_null<func::FuncOp>(symbol_table.lookup(
              mlir::cast<FlatSymbolRefAttr>(call_op.getFAttr()).getValue())));
        }
        for (auto call_op : main_func.getOps<TF::StatefulPartitionedCallOp>()) {
          func_ops.push_back(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 21K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/passes/insert_main_function.cc

      bool need_prefix_for_output_name = false;
      std::vector<StringRef> fn_input_name_vec, fn_output_name_vec;
      StringSet<> input_name_set, output_name_set;
      for (auto func_op : module_op.getOps<func::FuncOp>()) {
        if (!ShouldIncludeInMainFunction(func_op)) continue;
        if (auto tf_attrs =
                func_op->getAttrOfType<DictionaryAttr>(kEntryFunctionAttr)) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 16.5K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/stablehlo/passes/quantization_patterns.cc

    template <typename GemmStyleOp>
    // Match for all gemm_style op and check for possible fusions.
    LogicalResult MatchGemmStyleOp(func::FuncOp entry_func_op) {
      const auto op_iterator_range = entry_func_op.getOps<GemmStyleOp>();
      if (op_iterator_range.empty()) {
        LLVM_DEBUG(llvm::dbgs() << "Function does not have "
                                << GemmStyleOp::getOperationName() << " op.\n");
        return failure();
      }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 03 06:04:36 UTC 2024
    - 41.7K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/transforms/xla_call_module_deserialization.cc

      // to store its `SymbolTable` to `SymbolTableCollection`.
      SymbolTable stablehlo_symbol_table(stablehlo_module);
    
      Builder builder(context);
      StringAttr main_func_name;
      for (auto func : stablehlo_module.getOps<func::FuncOp>()) {
        const bool is_main_func = func.getSymName() == kStablehloMainFunctionName;
        if (tf_symbol_table.lookup(func.getSymName())) {
          if (failed(stablehlo_symbol_table.renameToUnique(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 23 09:05:47 UTC 2024
    - 11.1K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/transforms/executor_tpuv1_outline_tpu_island.cc

        builder.create<YieldOp>(island_op.getLoc(), yield_operands);
      }
    
      // Outline all the transitively called functions by moving them in the
      // outlined module.
      for (func::FuncOp func : outlined_module.getOps<func::FuncOp>()) {
        func.walk([&](Operation *op) {
          for (NamedAttribute attr : op->getAttrs()) {
            if (auto symbol_ref =
                    mlir::dyn_cast<FlatSymbolRefAttr>(attr.getValue())) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.7K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/sparsecore/embedding_pipelining.cc

      LogicalResult UnifyReplicationInfo(func::FuncOp func) {
        auto new_repl_info =
            builder.getStringAttr(func.getSymName().str() + "_repl_info");
        for (auto& op : func.getRegion().getOps()) {
          if (auto compile_op = llvm::dyn_cast<TF::TPUCompilationResultOp>(op)) {
            UpdateReplicationAttr(compile_op, new_repl_info);
          } else {
            UpdateReplicationAttr(&op, new_repl_info);
          }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 92.9K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/quantization/common/test_base.h

      FailureOr<OpT> FindFirstOpFromMainFunc(ModuleOp module_op) {
        func::FuncOp main_func_op = FindMainFuncOp(module_op);
        if (main_func_op == nullptr) return failure();
    
        auto ops = main_func_op.getOps<OpT>();
        if (ops.empty()) return failure();
    
        return *ops.begin();
      }
    
      std::unique_ptr<MLIRContext> ctx_;
      OpBuilder builder_;
    };
    
    }  // namespace mlir::quant
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 04 07:19:09 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/quantization/stablehlo/passes/insert_weight_param.cc

        if (function_name.contains("conv")) {
          return (*(func.getOps<mlir::stablehlo::ConvolutionOp>().begin()))
              .getDimensionNumbers()
              .getKernelOutputFeatureDimension();
        } else if (function_name.contains("dot_general")) {
          auto dot = *(func.getOps<mlir::stablehlo::DotGeneralOp>().begin());
          const ::mlir::stablehlo::DotDimensionNumbersAttr dimension_numbers =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 09 05:56:10 UTC 2024
    - 10.2K bytes
    - Viewed (0)
Back to top