Colorfy icon indicating copy to clipboard operation
Colorfy copied to clipboard

Change clustering method used to find distinct colors in album artwork

Open davidkrantz opened this issue 6 years ago • 2 comments

Right now the K-means clustering method is used to find K distinct colors from the album artwork. This method has its flaws, more specifically:

  • Need to know K (how many distinct colors the image have)
  • Always learns convex clusters
  • Sensitive to outliers

Therefore, the accuracy of the system could potentially be significantly increased by changing the clustering method. Potential clustering methods include DBSCAN and HDBSCAN, where the latter probably is the better choice as it allows clusters of different densities, is efficient and only requires one parameter, namely the minimum cluster size.

The clustering takes place in the file spotify_background_color.py in the method best_color. When evaluating different clustering methods, the plotting feature of this method might be of use. This can be activated by simply setting the argument plot=True.

davidkrantz avatar Oct 19 '19 11:10 davidkrantz

Hello, I was wondering if you had found any for this yet? I am also having trouble with accuracy and speed with KMeans

Pixeled99 avatar Sep 05 '23 13:09 Pixeled99

Hi! I have not tried this yet and no one is working on this issue at the moment, so feel free to give it a go! Nowadays, there might even exist new better suitable clustering methods than the two I mentioned above.

davidkrantz avatar Sep 09 '23 11:09 davidkrantz