Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for createLegalizeTFPass (0.5 sec)

  1. tensorflow/compiler/mlir/tensorflow/transforms/mlprogram.cc

      pm.addPass(mlir::createSymbolDCEPass());
    
      pm.addPass(mlir::TF::CreateTFShapeInferencePass());
    
      llvm::StringRef tf2xla_fallback_device_type = "XLA_CPU_JIT";
      pm.addPass(mlir::mhlo::createLegalizeTFPass(
          /*legalize_chlo=*/true, tf2xla_fallback_device_type,
          /*prefer_tf2xla=*/false));
    
      pm.addPass(mlir::TF::CreateStripTfAttributesPass());
    
      pm.addPass(mlir::createCanonicalizerPass());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jan 09 22:39:15 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tf2xla/transforms/passes.h

    /// Note: This is a module pass because when legalizing with TF2XLA fallback,
    /// functions are imported into the module. Importing functions into a
    /// module is not thread safe.
    std::unique_ptr<OperationPass<ModuleOp>> createLegalizeTFPass(
        bool legalize_chlo = true,
        std::optional<StringRef> tf2xla_fallback_device_type = std::nullopt,
        bool prefer_tf2xla = false);
    
    /// Adds the TF to TF lowerings and TF to XLA rewrite patterns to the pattern
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 28 21:49:50 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/transforms/passes.h

    // is true, the TF::AssertOp will not be removed.
    std::unique_ptr<OperationPass<func::FuncOp>> CreateLegalizeTFPass(
        bool run_tfl_runtime_verification, bool preserve_assert_op = false);
    std::unique_ptr<OperationPass<func::FuncOp>> CreateLegalizeTFPass();
    
    // Creates an instance of the TensorFlow Lite dialect Optimize pass.
    std::unique_ptr<OperationPass<func::FuncOp>> CreateOptimizePass(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Mar 07 21:29:34 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tf2xla/transforms/xla_legalize_tf_test.cc

      passes(&pm);
    
      return pm.run(module.get()).succeeded();
    }
    
    std::function<void(PassManager*)> legalizeTFPasses() {
      return [](PassManager* pm) {
        pm->addPass(mlir::mhlo::createLegalizeTFPass(
            /* legalize_chlo=*/true, llvm::StringRef("gpu/xpu"),
            /* prefer_tf2xla=*/false));
      };
    }
    
    TEST(XlaLegalizeTest, IllegalOp) {
      constexpr char kMlirIllegalOpStr[] = R"(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 02 09:16:07 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tf2xla/transforms/xla_legalize_tf_passes.td

            /*default=*/"false",
            "Prioritize tf2xla fallback legalization over MLIR legalization "
            "patterns">,
      ];
    
      let constructor = "mlir::mhlo::createLegalizeTFPass()";
      let dependentDialects = [
        "arith::ArithDialect",
        "chlo::ChloDialect",
        "func::FuncDialect",
        "mhlo::MhloDialect",
        "quant::QuantizationDialect",
        "shape::ShapeDialect",
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Mar 21 17:44:14 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/lite/experimental/tac/tac_module.cc

            /*allow_bf16_and_f16_type_legalization=*/false));
        pass_manager->addNestedPass<mlir::func::FuncOp>(
            mlir::createCanonicalizerPass());
        pass_manager->addPass(
            mlir::TFL::CreateLegalizeTFPass(/*run_tfl_runtime_verification=*/true));
        pass_manager->addPass(
            mlir::TFL::CreateOptimizePass(/*enable_canonicalization=*/true));
      }
    
      pass_manager->addPass(mlir::TFL::tac::CreateComputeCostPass());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 08 01:19:25 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tf2xla/transforms/xla_legalize_tf.cc

                            prefer_tf2xla_))) {
        signalPassFailure();
      }
    }
    
    }  // end namespace
    
    std::unique_ptr<OperationPass<ModuleOp>> createLegalizeTFPass(
        bool legalize_chlo, std::optional<StringRef> tf2xla_fallback_device_type,
        bool prefer_tf2xla) {
      return std::make_unique<LegalizeTF>(
          legalize_chlo, tf2xla_fallback_device_type, prefer_tf2xla);
    }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 28 21:49:50 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/transforms/legalize_tf.cc

    std::unique_ptr<OperationPass<func::FuncOp>> CreateLegalizeTFPass(
        bool run_tfl_runtime_verification, bool preserve_assert_op) {
      return std::make_unique<LegalizeTFPass>(run_tfl_runtime_verification,
                                              preserve_assert_op);
    }
    
    std::unique_ptr<OperationPass<func::FuncOp>> CreateLegalizeTFPass() {
      return std::make_unique<LegalizeTFPass>();
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon May 20 20:06:54 UTC 2024
    - 45.2K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/tf_tfl_passes.cc

        pass_manager->addNestedPass<mlir::func::FuncOp>(
            mlir::TF::CreateInitTextFileToImportPass(saved_model_dir.str()));
    
        pass_manager->addNestedPass<mlir::func::FuncOp>(
            mlir::TFL::CreateLegalizeTFPass(pass_config.runtime_verification,
                                            pass_config.preserve_assert_op));
        pass_manager->addPass(mlir::TFL::CreateAnalyzeVariablesPass());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jun 06 18:45:51 UTC 2024
    - 25.5K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/lite/transforms/passes.td

    }
    
    def LegalizeTFPass : Pass<"tfl-legalize-tf", "mlir::func::FuncOp"> {
      let summary = "Legalize from TensorFlow to TensorFlow Lite dialect.";
      let constructor = "CreateLegalizeTFPass()";
      let dependentDialects = ["TFL::TensorFlowLiteDialect" ,
        "quant::QuantizationDialect",
        "quantfork::QuantizationForkDialect"
      ];
      let options = [
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 24 20:30:06 UTC 2024
    - 22.6K bytes
    - Viewed (0)
Back to top