using kmeans to convert rgb image to grayscale

1 visualizzazione (ultimi 30 giorni)
nguyen tien
nguyen tien il 12 Gen 2016
Commentato: John D'Errico il 12 Gen 2016
I have a rgb image, I want to use kmeans to convert rgb image to grayscale. can you help me, please?

Risposte (1)

Image Analyst
Image Analyst il 12 Gen 2016
Why kmeans() specifically? Why not just use rgb2ind()?
  3 Commenti
Image Analyst
Image Analyst il 12 Gen 2016
How is simply converting to grayscale "recognition"???
Anyway, see the MATLAB demo for image segmentation using kmeans: http://www.mathworks.com/examples/image/2068-color-based-segmentation-using-k-means-clustering
John D'Errico
John D'Errico il 12 Gen 2016
I'm not at all sure I see how kmeans is intended to be used for an RGB - gray scale conversion. kmeans is a clustering algorithm. As such, it would have no value for your project.

Accedi per commentare.

Categorie

Scopri di più su Statistics and Machine Learning Toolbox in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by