A Python package for detecting whether images are colored or black and white using two different color spaces: RGB and LAB. The package includes two classes: - `ColorDetection`: Analyzes images in the RGB color space, calculating mean deviation from pixel color mean to determine color presence. - `LABColorDetection`: Analyzes images in the LAB color space, assessing color presence by analyzing differences between the A and B channels. Features: - Detects colored vs. black and white images. - Supports analysis of image tensors. - Adjustable thresholds for color detection. - Uses a percentage of highest deviations for more robust detection. - Efficient processing with PyTorch and OpenCV integration.
https://github.com/DrMWeigand/ComfyUI_ColorImageDetection
git clone https://github.com/DrMWeigand/ComfyUI_ColorImageDetection
comfy node install colorimagedetection