spyrit.misc.color

Created on Mon Dec 2 20:53:59 2024

@author: ducros

Functions

colorize(im, color[, clip_percentile])

Helper function to create an RGB image from a single-channel image using a specific color.

generate_colormap(wavelength[, img_size, gamma])

Generates colormap for a wavelength.

plot_hs(strategy, img, wav[, suptitle, ...])

Plot hyperspectral data with wavelength-aware colormaps.

spectral_colorization(M_gray, wav[, axis])

Colorize the last dimension of an array

wavelength_to_colormap(wav[, gamma])

Creates a linear Matplotlib colormap that transitions from black to a specific color corresponding to a given electromagnetic wavelength.

wavelength_to_rgb(wavelength[, gamma])

Converts wavelength to RGB.

wavelength_to_rgb_mat(wav_range[, gamma])