Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for GetInitializerFunction (1.56 sec)

  1. tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model_test.cc

          R"mlir(module attributes {tf_saved_model.semantics} {})mlir";
    
      Block block;
      ModuleOp module_op = ParseModuleOp(kModuleOpStr, block, ctx_);
    
      func::FuncOp init_func_op = GetInitializerFunction(
          module_op, /*initializer_type=*/kTfSavedModelInitializerInitType);
    
      EXPECT_THAT(init_func_op, IsNull());
    }
    
    TEST_F(TfSavedModelTest,
           GetInitializerFunctionReturnsNullWhenInitializersEmpty) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Feb 01 05:03:09 UTC 2023
    - 6.4K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/quantization/tensorflow/passes/remove_var_init_by_const.cc

    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_ops.h"
    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.h"
    
    namespace mlir {
    namespace quant {
    namespace {
    
    using ::mlir::tf_saved_model::GetInitializerFunction;
    using ::mlir::tf_saved_model::kTfSavedModelInitializerRestoreType;
    
    // A pass that removes `tf.AssignVariableOp(tf.VarHandleOp, tf.Const)` patterns
    // from the initializer function (type = "restore_op").
    //
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Feb 03 12:04:03 UTC 2023
    - 4.5K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/quantization/tensorflow/cc/save_variables.cc

    #include "tsl/platform/logging.h"
    #include "tsl/platform/status.h"
    
    namespace tensorflow {
    namespace quantization {
    namespace {
    
    using ::mlir::func::FuncOp;
    using ::mlir::tf_saved_model::GetInitializerFunction;
    using ::mlir::tf_saved_model::kTfSavedModelInitializerRestoreType;
    
    // Adds the tensor that initializes the variable through the provided
    // `assign_var_op` to the `bundle_writer` for saving to checkpoint. Returns the
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Feb 26 03:36:55 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/tensorflow/passes/insert_restore_op.cc

    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_ops.h"
    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.h"
    
    namespace mlir {
    namespace quant {
    namespace {
    
    using ::mlir::tf_saved_model::GetInitializerFunction;
    using ::mlir::tf_saved_model::kTfSavedModelIndexPathAttr;
    using ::mlir::tf_saved_model::kTfSavedModelInitializerRestoreType;
    
    // This pass creates a RestoreV2 op in the initializer function with
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Mar 12 06:02:20 UTC 2023
    - 9K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/quantization/tensorflow/passes/insert_save_op.cc

    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_ops.h"
    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.h"
    
    namespace mlir {
    namespace quant {
    namespace {
    
    using ::mlir::tf_saved_model::GetInitializerFunction;
    using ::mlir::tf_saved_model::kTfSavedModelInitializerRestoreType;
    
    constexpr StringRef kTfQuantSaveV2OpName = "tf_quant__save_save_v2";
    constexpr StringRef kTfQuantSaveReturnOpName = "tf_quant__save_return";
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Mar 22 05:52:39 UTC 2024
    - 9.5K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.h

    // Returns the initializer function whose `tf_saved_model.initializer_type`
    // attribute matches `initializer_type`. Returns a null op if it doesn't exist.
    func::FuncOp GetInitializerFunction(ModuleOp module_op,
                                        StringRef initializer_type);
    
    // Checks if the module restores variables from a Checkpoint.
    bool IsRestoreGraph(ModuleOp module);
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jan 18 03:21:34 UTC 2024
    - 5.1K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/quantization/tensorflow/passes/unfreeze_constants.cc

    #include "tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.h"
    #include "tensorflow/compiler/mlir/utils/name_utils.h"
    
    namespace mlir {
    namespace quant {
    namespace {
    
    using ::mlir::tf_saved_model::GetInitializerFunction;
    using ::mlir::tf_saved_model::GetSessionInitializerOp;
    using ::mlir::tf_saved_model::kTfSavedModelExportedNamesAttr;
    using ::mlir::tf_saved_model::kTfSavedModelInitializerRestoreType;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Aug 16 15:04:53 UTC 2023
    - 14K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/initialize_variables_in_session_init.cc

    func::FuncOp GetOrCreateSessionInitFunc(ModuleOp module) {
      SessionInitializerOp session_init_op = GetSessionInitializerOp(module);
      if (!session_init_op) return CreateSessionInitFunc(module);
    
      auto init_func_op = GetInitializerFunction(
          module, /*initializer_type=*/kTfSavedModelInitializerRestoreType);
      if (init_func_op) {
        return init_func_op;
      } else if (!session_init_op.getInitializers().empty()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 23 09:05:47 UTC 2024
    - 7K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/ir/tf_saved_model.cc

        // `init_func_op` is guaranteed to be not null in a valid module.
        init_func_ops.push_back(init_func_op);
      }
    
      return init_func_ops;
    }
    
    func::FuncOp GetInitializerFunction(ModuleOp module_op,
                                        const StringRef initializer_type) {
      SmallVector<func::FuncOp, 2> init_func_ops =
          GetInitializerFunctions(module_op);
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 23.5K bytes
    - Viewed (0)
Back to top