I am working with numpy arrays of a range of data types (uint8, uint16, int16, etc.). I would like to be able to check whether a number can be represented within the limits
min_value = np.iinfo(im.dtype).min max_value = np.iinfo(im.dtype).max
docs: