Normalize data 'before' or 'after' regionprops?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
After image segmentation, I use regionprops to extract the features for classification. My data consists of 500 samples with 13 features. The range of the features from regionprops is averagely between 0.1 to 20,000 (area of pixel).
My problem is, is it advisable to 'norm' the value (such as im2double?) before regionprops or the normalization can be done afterwards?
I tried norm_v = v/norm(v) between the big numbers ranging between 200-20,000, but the end result (0.001 - 0.99) is still not satisfying.
Please help.
4 commentaires
Walter Roberson
le 3 Juil 2013
It depends: is your preselection and labeling already enough to group pixels correctly, or are you using the results from regionprops to determine boundaries of the groupings but before putting them into the classifier ?
Réponse acceptée
Image Analyst
le 3 Juil 2013
regionprops won't measure anything less than 1 pixel so I'm not sure how you're getting 0.1 pixels for the area.
I'd recommend leaving your image as integer if you can, or leaving it as whatever floating point range it has if you can. If it forces you to scale your image to 0-1 with imdouble, then you'll have to unscale it later. But again, I'd prefer not to do any scaling at all - I rarely do, but then I've never tried to send in a floating point RGB image into regionprops to get intensity information (MeanIntensity). Of course for spatial measurements (area, perimeter, equivdiameter, etc0) you don't need to scale at all since measuring those is done purely from the binary image, not from the grayscale image (single color channel).
2 commentaires
Image Analyst
le 4 Juil 2013
Not sure how to answer other than to say the shape-based measurements won't depend on whether your image is in the range 0-1 or 0-255. However your intensity-based measurements will and you just need to be aware of what range your intensities are in every step of the way.
Plus de réponses (0)
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!