colour.hints.ProtocolArrayNamespace#

class colour.hints.ProtocolArrayNamespace(*args, **kwargs)[source]#

Define the surface of an Array API namespace used by Colour.

Function members are typed as callables returning numpy.ndarray so that the array resulting from a namespace call is typed as a concrete array rather than typing.Any.

__init__(*args, **kwargs)#

Methods

__init__(*args, **kwargs)

Attributes

fft

Return the fast Fourier transform extension.

inf

Return the floating point representation of positive infinity.

linalg

Return the linear algebra extension.

pi

Return the mathematical constant pi.

float32

float64

int32

int64

abs

acos

all

any

arange

arctan

argmax

argmin

argsort

asarray

asin

astype

atan

atan2

bitwise_and

bitwise_right_shift

bitwise_xor

broadcast_arrays

broadcast_shapes

broadcast_to

clip

concat

cos

cumsum

cumulative_sum

diff

exp

expand_dims

expm1

eye

finfo

flip

floor

full

full_like

gradient

hypot

interp

isfinite

isin

isinf

isnan

linspace

log

log10

log1p

log2

logical_and

logical_not

logical_or

matmul

matrix_transpose

max

maximum

mean

meshgrid

min

minimum

moveaxis

nonzero

ones

ones_like

pad

permute_dims

pow

prod

real

repeat

reshape

resize

roll

round

searchsorted

sign

sin

sort

sqrt

square

squeeze

stack

std

sum

take

take_along_axis

tan

tanh

tile

trapezoid

tril

unique

unique_values

where

zeros

zeros_like