itkwasm.to_numpy_array#

Module Contents#

Functions#

array_like_to_numpy_array

Convert a numpy array-like to a numpy ndarray.

_buffer_to_numpy_array

_dtype_to_component_type

API#

itkwasm.to_numpy_array.array_like_to_numpy_array(arr: numpy.typing.ArrayLike) numpy.ndarray#

Convert a numpy array-like to a numpy ndarray.

Parameters:

arr (ArrayLike) – numpy ndarray like

Returns:

Numpy array

Return type:

np.ndarray

itkwasm.to_numpy_array._buffer_to_numpy_array(component_type: Union[itkwasm.int_types.IntTypes, itkwasm.float_types.FloatTypes], buf)#
itkwasm.to_numpy_array._dtype_to_component_type(dtype)#