Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 45 for set_device (0.14 sec)

  1. tensorflow/compiler/mlir/tensorflow/utils/fake_session.cc

          t.scalar<tensorflow::ResourceHandle>()().set_device(kDeviceName);
    
          outputs->push_back(t);
        } else if (output_name == "var2") {
          Tensor t = Tensor(tensorflow::DT_RESOURCE, tensorflow::TensorShape({1}));
          t.scalar<tensorflow::ResourceHandle>()().set_name("var2");
          t.scalar<tensorflow::ResourceHandle>()().set_device(kDeviceName);
    
          outputs->push_back(t);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Feb 26 03:47:51 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  2. tensorflow/c/experimental/saved_model/core/saved_variable_loading_test.cc

      auto& test_params = GetParam();
      DataType dtype = std::get<0>(test_params);
      TensorShape shape(std::get<1>(test_params));
    
      SavedVariable saved_variable;
      saved_variable.set_dtype(dtype);
      saved_variable.set_device("/job:localhost/replica:0/task:0/device:CPU:1"),
          shape.AsProto(saved_variable.mutable_shape());
    
      std::unique_ptr<Variable> var;
      TF_ASSERT_OK(internal::LoadSavedVariable(context(), saved_variable, &var));
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Feb 27 09:34:33 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  3. tensorflow/compiler/jit/xla_launch_util_gpu_test.cc

        Var* var = CreateVariable<T>(name, shape, data);
        ResourceMgr* rm = device_->resource_manager();
        TF_ASSERT_OK(rm->Create(rm->default_container(), name, var));
    
        ResourceHandle handle;
        handle.set_device(device_->name());
        handle.set_container(rm->default_container());
        handle.set_name(name);
        TypeIndex type_index = TypeIndex::Make<Var>();
        handle.set_hash_code(type_index.hash_code());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 10K bytes
    - Viewed (0)
  4. tensorflow/c/kernels_test.cc

                                                   const char* node_name,
                                                   Status* status) {
      NodeDef def;
      def.set_op(op_name);
      def.set_name(node_name);
      def.set_device(device_name);
      def.add_input("input1");
      def.add_input("input2");
    
      AttrValue v;
      v.set_type(DataType::DT_FLOAT);
      (*def.mutable_attr())["SomeDataTypeAttr"] = v;
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 50.4K bytes
    - Viewed (0)
  5. tensorflow/compiler/jit/encapsulate_xla_computations_pass.cc

        // Target the XLA CPU/GPU backends.
        VLOG(2) << "Replacing with XlaLaunch";
        VLOG(2) << "Device is " << launch->requested_device();
        def.set_op("XlaLaunch");
        def.set_device(launch->requested_device());
        AddNodeAttr("Tconstants", DataTypeVector{}, &def);
        AddNodeAttr("Targs", arg_types, &def);
        AddNodeAttr("Nresources", num_variables, &def);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 12 06:33:33 UTC 2024
    - 15.1K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/utils/export_utils.cc

      // associated NodeDef is not updated.
      for (int i = 0, e = inst->getNumOperands(); i < e; ++i) {
        node_def->add_input();
      }
      if (auto attr = inst->getAttrOfType<mlir::StringAttr>("device")) {
        node_def->set_device(std::string(attr.getValue()));
      }
    
      // Add the node debug info.
      TF_RETURN_IF_ERROR(ConvertLocation(
          inst->getLoc(), name, node_def->mutable_experimental_debug_info()));
    
      return node_def;
    }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 17:58:54 UTC 2024
    - 19.7K bytes
    - Viewed (0)
  7. tensorflow/compiler/jit/xla_launch_util_test.cc

        Var* var = CreateVariable<T>(name, shape, data);
        ResourceMgr* rm = device_->resource_manager();
        TF_ASSERT_OK(rm->Create(rm->default_container(), name, var));
    
        ResourceHandle handle;
        handle.set_device(device_->name());
        handle.set_container(rm->default_container());
        handle.set_name(name);
        TypeIndex type_index = TypeIndex::Make<Var>();
        handle.set_hash_code(type_index.hash_code());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Feb 21 09:53:30 UTC 2024
    - 28.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/jit/encapsulate_subgraphs_pass.cc

      // name_in is copied here because name may be modified below if
      // rewrite_subgraph_fn is true.
      string name = name_in;
      call_node_def_.set_op(name);
      call_node_def_.set_name(name);
      call_node_def_.set_device(device_);
    
      if (rewrite_subgraph_fn) {
        std::vector<OutputTensor> arg_source_tensors(args_by_src_.size());
        for (const auto& arg : args_by_src_) {
          arg_source_tensors.at(arg.second) = arg.first;
        }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 22 08:47:20 UTC 2024
    - 51K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/transforms/colocate_tpu_copy_with_dynamic_shape.cc

        if (otherDevice->device_) {
          return SetDevice(otherDevice->device_);
        }
        return ChangeResult::NoChange;
      }
    
      void print(raw_ostream &os) const override {
        if (device_) {
          os << "<" << device_ << ">";
        } else {
          os << "<no device>";
        }
      }
    
      ChangeResult SetDevice(mlir::StringAttr device) {
        bool changed = (device != device_);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Aug 23 00:30:27 UTC 2023
    - 5.2K bytes
    - Viewed (0)
  10. tensorflow/compiler/jit/kernels/xla_ops.cc

            const std::string& src_device = ctx->device()->name();
            std::string task_prefix;
            TF_RETURN_IF_ERROR(GetTaskName(src_device, &task_prefix));
            const std::string dst_device =
                absl::StrCat(task_prefix, "/device:CPU:0");
            const std::string& rendezvous_key =
                Rendezvous::CreateKey(src_device, /*src_incarnation=*/1, dst_device,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 22:46:36 UTC 2024
    - 41.4K bytes
    - Viewed (0)
Back to top