Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 41 for add_attrs (0.2 sec)

  1. tensorflow/compiler/jit/force_xla_constants_on_host_pass_test.cc

      NameAttrList b_name_attr;
      b_name_attr.set_name("TransposeCall");
      ops::PartitionedCall call(root.WithOpName("call"), {in, perm}, {DT_FLOAT},
                                b_name_attr);
      call.output.front().node()->AddAttr(kXlaMustCompileAttr, true);
    
      std::unique_ptr<Graph> graph;
      TF_ASSERT_OK(ForceXlaConstantsOnHost(root, &flib_def, &graph));
    
      bool found = false;
      for (Node* node : graph->nodes()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 22 08:47:20 UTC 2024
    - 4.1K bytes
    - Viewed (0)
  2. tensorflow/compiler/jit/encapsulate_util.cc

        return s;
      }
    
      n->ClearAttr(attr_name);
      attr_value.push_back(value);
      n->AddAttr(attr_name, attr_value);
      return absl::OkStatus();
    }
    
    // Replaces attribute value.
    template <typename T>
    void ReplaceAttr(Node* n, const string& attr_name, const T& value) {
      n->ClearAttr(attr_name);
      n->AddAttr(attr_name, value);
    }
    
    // Step 1 for `PreprocessEdgesBetweenOutsideCompilations`. See comments of
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 12 06:33:33 UTC 2024
    - 15.5K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tf2xla/internal/mlir_bridge_pass_util_test.cc

              .Input(inputs)
              .Attr("Tin", {DT_RESOURCE})
              .Attr("Tout", {DT_RESOURCE})
              .Attr("f", f_name_attr)
              .Finalize(root.graph(), &call));
      call->AddAttr(std::string(kMustCompileAttr), true);
    
      TF_ASSERT_OK(root.ToGraph(&graph));
    
      // Required for passing the PS server parameter check.
      for (Node* node : graph.nodes()) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 17 19:51:50 UTC 2024
    - 10.3K bytes
    - Viewed (0)
  4. src/log/slog/json_handler_test.go

    		},
    	} {
    		t.Run(test.name, func(t *testing.T) {
    			var buf bytes.Buffer
    			h := NewJSONHandler(&buf, &test.opts)
    			r := NewRecord(testTime, LevelInfo, "m", 0)
    			r.AddAttrs(Int("a", 1), Any("m", map[string]int{"b": 2}))
    			if err := h.Handle(context.Background(), r); err != nil {
    				t.Fatal(err)
    			}
    			got := strings.TrimSuffix(buf.String(), "\n")
    			if got != test.want {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jul 11 17:06:26 UTC 2023
    - 6.5K bytes
    - Viewed (0)
  5. tensorflow/compiler/jit/cluster_scoping_pass.cc

      string scope;
      if (GetNodeAttr(node->attrs(), kXlaInternalScopeAttr, &scope).ok()) {
        return scope;
      }
    
      return std::nullopt;
    }
    
    void SetXlaInternalScope(Node* node, StringPiece scope) {
      node->AddAttr(kXlaInternalScopeAttr, scope);
    }
    
    // NB! We append a new scope as suffix to the _XlaInternalScope attribute
    // instead of overriding the old value.  In other words, appending scope B to
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 22 08:47:20 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  6. tensorflow/compiler/jit/encapsulate_xla_computations_pass.cc

        if (args[i]->output_type(0) == DT_RESOURCE &&
            variable_start_index == num_args) {
          variable_start_index = i;
        }
        (*input_permutation)[index] = i;
        args[i]->AddAttr("index", i);
      }
      VLOG(4) << "variable_start_index: " << variable_start_index;
    
      // Computes the permutation to produce the correct retval order, and update
      // the argument indices.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 12 06:33:33 UTC 2024
    - 15.1K bytes
    - Viewed (0)
  7. src/log/slog/logger.go

    	if !internal.IgnorePC {
    		var pcs [1]uintptr
    		// skip [runtime.Callers, this function, this function's caller]
    		runtime.Callers(3, pcs[:])
    		pc = pcs[0]
    	}
    	r := NewRecord(time.Now(), level, msg, pc)
    	r.AddAttrs(attrs...)
    	if ctx == nil {
    		ctx = context.Background()
    	}
    	_ = l.Handler().Handle(ctx, r)
    }
    
    // Debug calls [Logger.Debug] on the default logger.
    func Debug(msg string, args ...any) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jan 08 18:26:18 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  8. tensorflow/c/c_api_function_test.cc

      // Verify that FunctionDef ArgDef has attributes.
      ASSERT_EQ(func_->record->fdef().arg_attr_size(), 1);
      auto arg_attrs = func_->record->fdef().arg_attr().find(0);
      ASSERT_NE(arg_attrs, func_->record->fdef().arg_attr().end());
      auto iter = arg_attrs->second.attr().find("_test_attr");
      ASSERT_NE(iter, arg_attrs->second.attr().end());
      EXPECT_EQ(iter->second.s(), "value");
    }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Jul 20 22:08:54 UTC 2023
    - 63.6K bytes
    - Viewed (0)
  9. src/log/slog/doc.go

    and hidden fields that refer to state (such as attributes) indirectly. This
    means that modifying a simple copy of a Record (e.g. by calling
    [Record.Add] or [Record.AddAttrs] to add attributes)
    may have unexpected effects on the original.
    Before modifying a Record, use [Record.Clone] to
    create a copy that shares no state with the original,
    or create a new Record with [NewRecord]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 15 14:35:48 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  10. tensorflow/compiler/jit/encapsulate_subgraphs_pass.cc

          });
    
      for (auto& src_arg : src_arg_pairs) {
        if (guaranteed_const_nodes.count(src_arg.first) != 0) {
          VLOG(1) << "Guaranteed const found: " << src_arg.first->DebugString();
          src_arg.second->AddAttr("_is_guaranteed_constant", true);
        }
      }
    }
    
    struct OutputInputTensorPairHasher {
      uint64 operator()(std::pair<OutputTensor, InputTensor> const& s) const {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 22 08:47:20 UTC 2024
    - 51K bytes
    - Viewed (0)
Back to top