tacco.utils.min_dtype

min_dtype(maximum)[source]

Gives the smallest signed integer dtype which is necessary to represent maximum.

Parameters:

maximum – The integer to be representable in the dtype.

Returns:

A signed integer dtype.