Data Type Functions

Array API specification for data type functions.

A conforming implementation of the array API standard must provide and support the following data type functions.

Objects in API

astype(x, dtype, /, *, copy=True)

Copies an array to a specified data type irrespective of Type Promotion Rules rules.

broadcast_arrays(*arrays)

Broadcasts one or more arrays against one another.

broadcast_to(x, /, shape)

Broadcasts an array to a specified shape.

can_cast(from_, to, /)

Determines if one data type can be cast to another data type according Type Promotion Rules rules.

finfo(type, /)

Machine limits for floating-point data types.

iinfo(type, /)

Machine limits for integer data types.

result_type(*arrays_and_dtypes)

Returns the dtype that results from applying the type promotion rules (see Type Promotion Rules) to the arguments.