File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,40 @@ include "_slicing.pxi"
54
54
55
55
56
56
class DLDeviceType (IntEnum ):
57
+ """
58
+ An ``IntEnum`` for the types of DLDevices supported by the DLPack
59
+ protocol.
60
+ ``kDLCPU``:
61
+ CPU (host) device
62
+ ``kDLCUDA``:
63
+ CUDA GPU device
64
+ ``kDLCUDAHost``:
65
+ Pinned CUDA CPU memory by cudaMallocHost
66
+ ``kDLOpenCL``:
67
+ OpenCL device
68
+ ``kDLVulkan``:
69
+ Vulkan buffer
70
+ ``kDLMetal``:
71
+ Metal for Apple GPU
72
+ ``kDLVPI``:
73
+ Verilog simulator buffer
74
+ ``kDLROCM``:
75
+ ROCm GPU device
76
+ ``kDLROCMHost``:
77
+ Pinned ROCm CPU memory allocated by hipMallocHost
78
+ ``kDLExtDev``:
79
+ Reserved extension device type used to test new devices
80
+ ``kDLCUDAManaged``:
81
+ CUDA managed/unified memory allocated by cudaMallocManaged
82
+ ``kDLOneAPI``:
83
+ Unified shared memory allocated on a oneAPI non-partitioned device
84
+ ``kDLWebGPU``:
85
+ Device support for WebGPU standard
86
+ ``kDLHexagon``:
87
+ Qualcomm Hexagon DSP
88
+ ``kDLMAIA``:
89
+ Microsoft MAIA device
90
+ """
57
91
kDLCPU = c_dlpack.device_CPU
58
92
kDLCUDA = c_dlpack.device_CUDA
59
93
kDLCUDAHost = c_dlpack.device_CUDAHost
You can’t perform that action at this time.
0 commit comments