Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 7 of 7 for TFE_OpSetDevice (0.2 seconds)

  1. tensorflow/c/eager/c_api_cluster_test.cc

                                     const char* local_device_name) {
      TF_Status* status = TF_NewStatus();
      TFE_TensorHandle* h0_task0 = TestMatrixTensorHandle(ctx);
    
      TFE_Op* matmul = MatMulOp(ctx, h0_task0, h0_task0);
      TFE_OpSetDevice(matmul, remote_device_name, status);
      EXPECT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
    
      TFE_TensorHandle* retvals[1];
      int num_retvals = 1;
      TFE_Execute(matmul, &retvals[0], &num_retvals, status);
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Thu Oct 09 05:56:18 GMT 2025
    - 19.2K bytes
    - Click Count (0)
  2. tensorflow/c/eager/c_api_test_util.cc

      TFE_OpSetAttrShape(op, "shape", {}, 0, status);
      TFE_OpSetAttrString(op, "container", "localhost", 0);
      TFE_OpSetAttrString(op, "shared_name", "", 0);
      if (!device_name.empty()) {
        TFE_OpSetDevice(op, device_name.c_str(), status);
      }
      if (TF_GetCode(status) != TF_OK) return nullptr;
      TFE_TensorHandle* var_handle = nullptr;
      int num_retvals = 1;
      TFE_Execute(op, &var_handle, &num_retvals, status);
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Thu Oct 09 05:56:18 GMT 2025
    - 23.4K bytes
    - Click Count (0)
  3. tensorflow/c/eager/c_api_test.cc

        TFE_Op* matmul = MatMulOp(ctx, hcpu, hgpu);
        if (cpu_op) {
          string cpu_device_name;
          ASSERT_TRUE(GetDeviceName(ctx, &cpu_device_name, "CPU"));
          TFE_OpSetDevice(matmul, cpu_device_name.c_str(), status.get());
        } else {
          TFE_OpSetDevice(matmul, gpu_device_name.c_str(), status.get());
        }
        ASSERT_EQ(TF_GetCode(status.get()), TF_OK) << TF_Message(status.get());
    
        TFE_TensorHandle* retvals[1];
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Thu Oct 09 05:56:18 GMT 2025
    - 94.6K bytes
    - Click Count (0)
  4. tensorflow/c/eager/custom_device_testutil.cc

      const TFE_OpAttrs* attributes = TFE_OpGetAttrs(original_op);
    
      TFE_Op* op(TFE_NewOp(context, operation_name, s));
      if (TF_GetCode(s) != TF_OK) return;
      TFE_OpAddAttrs(op, attributes);
      TFE_OpSetDevice(op, dev->underlying_device.c_str(), s);
      if (TF_GetCode(s) != TF_OK) return;
      int num_inputs = TFE_OpGetFlatInputCount(original_op, s);
      if (TF_GetCode(s) != TF_OK) return;
      for (int j = 0; j < num_inputs; ++j) {
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Sat Dec 20 23:30:21 GMT 2025
    - 8.4K bytes
    - Click Count (0)
  5. tensorflow/c/eager/c_api_distributed_test.cc

      ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status);
      TFE_OpAddInput(func, packed_handle, status);
      ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status);
      if (remote) {
        TFE_OpSetDevice(func, task1_name, status);
        ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status);
      }
    
      TFE_TensorHandle* retvals[1] = {nullptr};
      int num_retvals = 1;
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Sat Oct 12 05:11:17 GMT 2024
    - 23.4K bytes
    - Click Count (0)
  6. tensorflow/c/eager/c_api_experimental_test.cc

            hcpu, ctx, gpu_device_name.c_str(), status.get());
        ASSERT_TRUE(TF_GetCode(status.get()) == TF_OK) << TF_Message(status.get());
    
        TFE_Op* shape_op = ShapeOp(ctx, hgpu);
        TFE_OpSetDevice(shape_op, gpu_device_name.c_str(), status.get());
        ASSERT_TRUE(TF_GetCode(status.get()) == TF_OK) << TF_Message(status.get());
        TFE_TensorHandle* retvals[1];
        int num_retvals = 1;
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Thu Oct 09 05:56:18 GMT 2025
    - 31.5K bytes
    - Click Count (0)
  7. tensorflow/c/eager/c_api.cc

      return tensorflow::unwrap(op)->Name().c_str();
    }
    
    TFE_Context* TFE_OpGetContext(const TFE_Op* op, TF_Status* status) {
      return tensorflow::wrap(tensorflow::unwrap(op)->GetContext());
    }
    
    void TFE_OpSetDevice(TFE_Op* op, const char* device_name, TF_Status* status) {
      status->status = tensorflow::unwrap(op)->SetDeviceName(device_name);
    }
    
    const char* TFE_OpGetDevice(const TFE_Op* op, TF_Status* status) {
    Created: Tue Apr 07 12:39:13 GMT 2026
    - Last Modified: Fri Nov 07 05:55:21 GMT 2025
    - 43.9K bytes
    - Click Count (0)
Back to Top