fishtank.correct.illumination#
- fishtank.correct.illumination(img, colors, corr_path, transpose=True, flip=True)#
Correct image illumination.
- Parameters:
img (
ndarray) – A (Y,X), (C,Y,X) or (C,Z,Y,X) image.colors (
list|ndarray|int) – A list of channel colors. Must be the same length as the number of channels in the image.corr_path (
str|Path) – The path to the illumination correction file.transpose (
bool(default:True)) – Whether to transpose the correction matrix.flip (
bool(default:True)) – Whether to flip the correction matrix.
- Return type:
- Returns:
corrected a numpy array of the same shape and dtype as the input image.