acia.colors#
Named channel colors for ImageSequenceSource.to_rgb(colors=…) composites.
This is a minimal starter palette (see color-constants.md in the spec-to-rgb implementation artifact), not a comprehensive named-color library – expanding it is future work.
- acia.colors.resolve_channel_color(value)[source]#
Resolve a channel color to an RGB triple in
[0, 1].Looks
valueup inCHANNEL_COLORScase-insensitively first; if it is not a known channel name,valueis passed straight tomatplotlib.colors.to_rgb()(so hex strings like"#00FF00"and any matplotlib-recognized color name work too).- Parameters:
value (str) – A key of
CHANNEL_COLORS(case-insensitive), a hex color string, or any color accepted bymatplotlib.colors.to_rgb().- Returns:
tuple[float, float, float] – RGB triple with each component in
[0, 1].- Raises:
ValueError – if
valueis neither a known channel name nor a colormatplotlib.colors.to_rgb()can parse.- Return type: