Skip to content

🖼 Find the most dominant colors of an image in Swift

Notifications You must be signed in to change notification settings

joncardasis/DominantColor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Dominant Color

(Swift 3)

Purpose

This project tries to obtain the most accurate dominant n number of colors in an image.

Algorithm

To obtain the colors I use a k-mean clustering algorithm to cluster pixels and find the most dominant colors. For more accurate representation I also created a k-means++ initialization algorithm to better place initial centroid nodes.

Issues

Execution time currently takes ~1.6s for most images. I'll look into Color Quantization to see if it is viable to use this algorithm instead.

About

🖼 Find the most dominant colors of an image in Swift

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages