3 ms·
The first thought I had would be to put this into HSV, and then index that with an R-tree [1]. This way, you can do nearest neighbor kind of stuff, similar to g
by cordite 12y ago
The first thought I had would be to put this into HSV, and then index that with an R-tree [1]. This way, you can do nearest neighbor kind of stuff, similar to geospatial indexing.
[1]: http://en.wikipedia.org/wiki/R-tree http://en.wikipedia.org/wiki/R-tree
- sibsibsib 12y agoI've had good results from converting to Lab space and geospatial indexing the ab components. http://en.m.wikipedia.org/wiki/Lab_color_space http://en.m.wikipedia.org/wiki/Lab_color_space
- 3pt14159 12y agoYou can't use HSV because the apparent differences in H / S / V aren't linear. You need to convert it to a different color system: https://en.wikipedia.org/wiki/Munsell_color_system https://en.wikipedia.org/wiki/Munsell_color_system What is interesting about this color system is that it isn't symmetric (your eye is better at differentiating certain hues like blue at more maximal values than others) so more care is needed on the nearest neighbour lookups. If you are using this coloring scheme for labelling colors in a photograph then you also need to adjust for colors that are especially vibrant and overtake the photo. For example this photo: http://1.bp.blogspot.com/-OkTS4Wo34UM/Uwg568lRl2I/AAAAAAAAFiM/_tawBh648b0/s1600/heart-pink-bench-love-wallpaper.jpg http://1.bp.blogspot.com/-OkTS4Wo34UM/Uwg568lRl2I/AAAAAAAAFi... Is best tagged "pink" not "brown".