Afficher commentaires plus anciens
can any one give me code to find the aspect ratio of human or any genral code to find aspect ratio.....
plzz relpy soon
Réponse acceptée
Plus de réponses (1)
Walter Roberson
le 3 Avr 2011
0 votes
Identify the object and label it and regionprops the area; the aspect ratio can be approximated as the ratios of the sides of the bounding box. If the human isn't sitting or lying down or the picture isn't taken at an unusual angle...
7 commentaires
Jan
le 4 Avr 2011
If the OP is speaking about an image at all. It could be a 3D voxel data set also.
Walter Roberson
le 4 Avr 2011
How is aspect ratio defined in 3D?
Jan
le 4 Avr 2011
@Walter: ax = axes; cylinder(ax, 10); get(ax, 'DataAspectRatio'); >> [20, 20, 1]
shafaq
le 4 Avr 2011
Walter Roberson
le 4 Avr 2011
"area" means "region" in this sense.
shafaq
le 4 Avr 2011
Walter Roberson
le 4 Avr 2011
foo = double(get(imagesc(),'CData') > 20);
ans =
Area: 904
Centroid: [42.4977876106195 40.5995575221239]
BoundingBox: [15.5 1.5 48 63]
so the aspect ratio for this area is 48 : 63
Catégories
En savoir plus sur Ground Truth Labeling dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!