cuda.core.typing.ArrayFormatType#

class cuda.core.typing.ArrayFormatType(
value,
names=<not given>,
*values,
module=None,
qualname=None,
type=None,
start=1,
boundary=None,
)#

Element format for an OpaqueArray allocation.

Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch.

  • UINT8 / UINT16 / UINT32 — unsigned integer elements.

  • INT8 / INT16 / INT32 — signed integer elements.

  • FLOAT16 / FLOAT32 — half- and single-precision float elements.

Added in version 1.1.0.

UINT8: uint8

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

UINT16: uint16

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

UINT32: uint32

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

INT8: int8

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

INT16: int16

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

INT32: int32

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

FLOAT16: float16

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0

FLOAT32: float32

Element format for an OpaqueArray allocation. Corresponds to CUarray_format from the CUDA driver API. Each value maps 1:1 to a NumPy dtype; the enum is retained as an explicit escape hatch. * UINT8 / UINT16 / UINT32 — unsigned integer elements. * INT8 / INT16 / INT32 — signed integer elements. * FLOAT16 / FLOAT32 — half- and single-precision float elements. .. versionadded:: 1.1.0