class nbla::CudaCachedUnifiedArray

class CudaCachedUnifiedArray : public nbla::CudaArray

Array allocated on unified memory with a CudaUnifiedMemory obtained by Cuda::unified_allocator().

Public Functions

explicit CudaCachedUnifiedArray(const Size_t size, dtypes dtype, const Context &ctx, const AllocatorMemoryPtr mem = nullptr, const Size_t offset = 0)

Constructor.

Parameters:
  • size – Length of array.

  • dtype – Data type.

  • ctx – Context specifies device ID.