Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for single_use_scope (0.13 sec)

  1. tensorflow/cc/framework/scope.cc

        builder->XlaCluster(impl()->xla_cluster_);
      }
    }
    
    string Scope::Impl::GetUniqueName(const string& prefix,
                                      bool check_single_use) const {
      if (check_single_use && single_use_scope()) {
        if (*scope_used_) {
          *status_ =
              errors::AlreadyExists(prefix, " already exists in the current scope");
          return "";
        }
        *scope_used_ = true;
        return prefix;
      }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sat Apr 13 05:57:22 UTC 2024
    - 20.9K bytes
    - Viewed (0)
  2. tensorflow/cc/framework/scope_internal.h

      // Helper functions to get a unique names.
      string GetUniqueName(const string& prefix, bool check_single_use) const;
      string GetNameForOp(const string& default_name) const;
    
      bool single_use_scope() const { return scope_used_ != nullptr; }
    
      // The graph, status, and name maps are shared by all child scopes
      // created from a single 'root' scope. A root scope is created by calling the
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Oct 05 15:46:43 UTC 2022
    - 5.1K bytes
    - Viewed (0)
  3. tensorflow/cc/framework/scope_test.cc

      EXPECT_EQ(names3[0], "c/mul");
      EXPECT_EQ(names3[1], "c/bias_add");
      EXPECT_EQ(names3[2], "c/c1");
      EXPECT_EQ(names3[3], "c/mul_1");
      EXPECT_EQ(names3[4], "c");
    }
    
    TEST(ScopeTest, SingleUseScope) {
      Scope root = Scope::NewRootScope();
      auto cop_scopes = root.GetCompositeOpScopes("cop");
      // cop_scopes.last is a single use scope
      EXPECT_EQ(cop_scopes.last.GetUniqueNameForOp("foo"), "cop");
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 14 08:17:37 UTC 2019
    - 5.5K bytes
    - Viewed (0)
Back to top