Pylette icon indicating copy to clipboard operation
Pylette copied to clipboard

Gracefully handle error when all pixels are masked out by alpha

Open qTipTip opened this issue 6 months ago • 0 comments

If you mask out all the pixels using an alpha mask:

poetry run pylette --filename docs/example_imgs/pylette_gui.png --alpha-mask-threshold 255

You get an error:

ValueError: Found array with 0 sample(s) (shape=(0, 4)) while a minimum of 1 is required by KMeans.

qTipTip avatar Jul 04 '25 22:07 qTipTip