How can I classify a fruit based on its color into white(unripe), turning, ripe using color image processing in matlab. Is there any code for it or some ideas on how to do it.

2 次查看(过去 30 天)
I was looking for help in classifying a fruit image based on its color.
say for example if the picture shows red color in the image of the fruit(for eg strawberry) how can it be classified as ripe fruit, if its white in color it needs to be classified as unripe and if its mix of white and orange should be classified as turning. How can this be done using matlab. I was looking for an immediate help. Thank you

回答(1 个)

Dhruv G
Dhruv G 2021-7-27
If the fruit occupies most of the image you can get the RGB values of a cluster of pixels near the center of the image and average over the cluster. You could then classify based on color, eg - (255,255,255) is white, (255,0,0) is red etc.

类别

Help CenterFile Exchange 中查找有关 Convert Image Type 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by