Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for TFE_TensorHandleDataType (0.3 sec)

  1. tensorflow/c/eager/c_api_test_util.cc

      CHECK_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
      TFE_OpAddInput(op, b, status);
      CHECK_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
      TF_DeleteStatus(status);
      TFE_OpSetAttrType(op, "T", TFE_TensorHandleDataType(a));
    
      return op;
    }
    
    TFE_Op* MatMulOp(TFE_Context* ctx, TFE_TensorHandle* a, TFE_TensorHandle* b) {
      TF_Status* status = TF_NewStatus();
    
      TFE_Op* op = TFE_NewOp(ctx, "MatMul", status);
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Wed Feb 21 22:37:46 GMT 2024
    - 23.5K bytes
    - Viewed (2)
  2. tensorflow/c/eager/parallel_device/parallel_device_lib.cc

      }
    
      TF_DataType dtype = TFE_TensorHandleDataType(components[0].get());
      // Verify that the TensorHandle's shape and dtype match all of the component
      // shapes and dtypes.
      for (TensorHandlePtr& component : components) {
        TFE_TensorHandleGetStatus(component.get(), status);
        if (!status->status.ok()) {
          return nullptr;
        }
        if (TFE_TensorHandleDataType(component.get()) != dtype) {
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Fri Feb 09 07:47:20 GMT 2024
    - 25.4K bytes
    - Viewed (1)
  3. tensorflow/c/eager/c_api_test.cc

      CHECK_EQ(TF_OK, TF_GetCode(status.get())) << TF_Message(status.get());
      TFE_DeleteContextOptions(opts);
    
      TFE_TensorHandle* h = TestMatrixTensorHandle(ctx);
      EXPECT_EQ(TF_FLOAT, TFE_TensorHandleDataType(h));
    
      TF_Tensor* t = TFE_TensorHandleResolve(h, status.get());
      ASSERT_EQ(16, TF_TensorByteSize(t));
      float data[4] = {0};
      memcpy(&data[0], TF_TensorData(t), TF_TensorByteSize(t));
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Aug 03 20:50:20 GMT 2023
    - 94.6K bytes
    - Viewed (1)
  4. tensorflow/c/eager/custom_device_testutil.cc

    }
    
    TFE_TensorHandle* MakeLoggedTensorHandle(
        TFE_Context* context, const tensorflow::string& logging_device_name,
        std::unique_ptr<LoggedTensor> t, TF_Status* status) {
      auto dtype = TFE_TensorHandleDataType(t->tensor);
      TFE_CustomDeviceTensorHandleMethods handle_methods;
      handle_methods.num_dims = &LoggedTensorNumDims;
      handle_methods.dim = &LoggedTensorDim;
      handle_methods.deallocator = &LoggedTensorDeallocator;
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Wed Mar 03 20:47:31 GMT 2021
    - 8.3K bytes
    - Viewed (0)
  5. tensorflow/c/eager/c_api.h

    // Indicates that the caller will not be using `h` any more.
    TF_CAPI_EXPORT extern void TFE_DeleteTensorHandle(TFE_TensorHandle* h);
    TF_CAPI_EXPORT extern TF_DataType TFE_TensorHandleDataType(TFE_TensorHandle* h);
    // This function will block till the operation that produces `h` has completed.
    TF_CAPI_EXPORT extern int TFE_TensorHandleNumDims(TFE_TensorHandle* h,
    C
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Apr 27 21:07:00 GMT 2023
    - 22.8K bytes
    - Viewed (1)
  6. tensorflow/c/eager/c_api_distributed_test.cc

      TFE_TensorHandle* packed_handle =
          TFE_CreatePackedTensorHandle(ctx, handles.data(), &num_replicas, status);
      ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status);
      EXPECT_EQ(TFE_TensorHandleDataType(packed_handle), TF_RESOURCE);
      EXPECT_EQ(TFE_TensorHandleNumDims(packed_handle, status), 0);
      EXPECT_EQ(TFE_TensorHandleNumElements(packed_handle, status), 1);
    
      const string composite_device_name =
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Feb 15 09:49:45 GMT 2024
    - 23.5K bytes
    - Viewed (0)
  7. tensorflow/c/eager/c_api_experimental_test.cc

        TFE_Execute(op, &handle_1, &num_retvals, status);
        ASSERT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
        TFE_DeleteOp(op);
    
        ASSERT_EQ(1, num_retvals);
        EXPECT_EQ(TF_FLOAT, TFE_TensorHandleDataType(handle_1));
        EXPECT_EQ(0, TFE_TensorHandleNumDims(handle_1, status));
        ASSERT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
    
        // Read the value of tensor handle `handle_1`.
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Aug 03 03:14:26 GMT 2023
    - 31.5K bytes
    - Viewed (1)
  8. tensorflow/c/eager/parallel_device/parallel_device_test.cc

      if (TF_GetCode(status) != TF_OK) return nullptr;
      TFE_OpSetDevice(op.get(), device, status);
      if (TF_GetCode(status) != TF_OK) return nullptr;
      TFE_OpSetAttrType(op.get(), "T", TFE_TensorHandleDataType(input));
      TFE_OpSetAttrInt(op.get(), "group_size", group_size);
      TFE_OpSetAttrInt(op.get(), "group_key", 0);
      TFE_OpSetAttrInt(op.get(), "instance_key", 0);
      const std::string merge_op("Add");
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Jul 08 23:47:35 GMT 2021
    - 29.3K bytes
    - Viewed (1)
  9. tensorflow/c/eager/c_api.cc

      tensorflow::profiler::TraceMe activity(
          "TFE_DeleteTensorHandle", tensorflow::profiler::TraceMeLevel::kInfo);
      if (h) {
        tensorflow::unwrap(h)->Unref();
      }
    }
    
    TF_DataType TFE_TensorHandleDataType(TFE_TensorHandle* h) {
      return static_cast<TF_DataType>(tensorflow::unwrap(h)->DataType());
    }
    
    int TFE_TensorHandleNumDims(TFE_TensorHandle* h, TF_Status* status) {
      if (h == nullptr) {
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Tue Mar 12 20:00:09 GMT 2024
    - 43.9K bytes
    - Viewed (2)
Back to top