Issue in recognising multiple objects in an Image
    3 views (last 30 days)
  
       Show older comments
    
    Rohan Gupta
 on 21 Jan 2017
  
    
    
    
    
    Commented: william  pyae
 on 26 May 2018
            I have images of Apples as well as of Oranges, which I am using as training images. The test image is an image consisting of both apple and orange. I am using GIST descriptor for feature extraction. When I train the classifier using extracted features, it gives an output as apple or orange for the test image. I have a query, as how can I make classifier recognise both of them in the test image. I am using KNN classifier
4 Comments
  william  pyae
 on 26 May 2018
				Hi Rohan, I'm doing a similar project as yours. Could you able to post all your matlab code in the file exchange? I would like to take references from your project. Thank you so much.
Accepted Answer
  Image Analyst
      
      
 on 25 Jan 2017
        Why not simply look at the color? Just convert to HSV color space, mask out the background and look at the amount of orange in the image. If there's more orange than non-orange, it's an orange.
3 Comments
  Image Analyst
      
      
 on 27 Jan 2017
				regionprops() will tell you the hue of every single region in the image. Once you've made a determination, you can assign a string with the name of the fruit. Like
props = regionprops(binaryImage, hueImage, 'MeanIntensity');
for k = 1 : length(props)
    thisHue = props(k).MeanIntensity
    if thisHue < 0.1 % or whatever
        fruitType{k} = 'Apple'
    else
        fruitType{k} = 'Orange'
    end
end
More Answers (1)
  Takuji Fukumoto
    
 on 25 Jan 2017
        I think you should cut block from a whole image and slide it for recognition if you want to use that classification.
3 Comments
  Takuji Fukumoto
    
 on 25 Jan 2017
				
      Edited: Takuji Fukumoto
    
 on 25 Jan 2017
  
			I mean it can work if you create 'search window'. The search window is used in some detector algorithm.
RCNN find something like object first and then use classifier.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


