Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for TFE_AllocateHostTensor (0.23 sec)

  1. tensorflow/c/eager/c_api_test_util.cc

    using tensorflow::string;
    using tensorflow::tstring;
    
    TFE_TensorHandle* TestScalarTensorHandle(TFE_Context* ctx, float value) {
      float data[] = {value};
      TF_Status* status = TF_NewStatus();
      TF_Tensor* t = TFE_AllocateHostTensor(ctx, TF_FLOAT, nullptr, 0, status);
      memcpy(TF_TensorData(t), &data[0], TF_TensorByteSize(t));
      TFE_TensorHandle* th = TFE_NewTensorHandleFromTensor(ctx, t, 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/c_api_test_util.h

    TFE_TensorHandle* TestTensorHandleWithDims(TFE_Context* ctx, const T* data,
                                               const int64_t* dims, int num_dims) {
      TF_Status* status = TF_NewStatus();
      TF_Tensor* t = TFE_AllocateHostTensor(ctx, datatype, dims, num_dims, status);
      memcpy(TF_TensorData(t), data, TF_TensorByteSize(t));
      TFE_TensorHandle* th = TFE_NewTensorHandleFromTensor(ctx, t, status);
    C
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Mon Jul 17 23:43:59 GMT 2023
    - 7.7K bytes
    - Viewed (0)
  3. tensorflow/c/eager/c_api_experimental.cc

      buf->data = data;
      buf->length = str.length();
      buf->data_deallocator = [](void* data, size_t length) {
        tensorflow::port::Free(data);
      };
      status->status = absl::OkStatus();
    }
    
    TF_Tensor* TFE_AllocateHostTensor(TFE_Context* ctx, TF_DataType dtype,
                                      const int64_t* dims, int num_dims,
                                      TF_Status* status) {
      std::vector<int64_t> dimvec(num_dims);
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Apr 11 23:52:39 GMT 2024
    - 35.9K bytes
    - Viewed (3)
  4. tensorflow/c/eager/c_api_experimental.h

    // Allocate and return a new Tensor on the host.
    //
    // The caller must set the Tensor values by writing them to the pointer returned
    // by TF_TensorData with length TF_TensorByteSize.
    TF_CAPI_EXPORT extern TF_Tensor* TFE_AllocateHostTensor(TFE_Context* ctx,
                                                            TF_DataType dtype,
                                                            const int64_t* dims,
    C
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Wed Feb 21 22:37:46 GMT 2024
    - 39.5K bytes
    - Viewed (0)
Back to top