Hi Gaëtan,<br><br>Thanks, but the link doesn't seem to work. Could you check it again?<br><br>Mengchen<br><br><div class="gmail_quote">On Nov 29, 2007 11:05 PM, Gaëtan Lehmann <<a href="mailto:gaetan.lehmann@jouy.inra.fr">
gaetan.lehmann@jouy.inra.fr</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>Hi,<br><br>I might be biased, because I made that contribution, but I would use
<br>the the class BinaryImageToStatisticsLabelMapFilter from http://<br><a href="http://hdl.handle.net/1926/584" target="_blank">hdl.handle.net/1926/584</a> , to get (I think) all the informations that<br>you need (and much more) in a single filter.
<br><br>Gaëtan<br><br><br>Le 29 nov. 07 à 23:42, Bill Lorensen a écrit :<br><div><div></div><div class="Wj3C7c"><br>> MC,<br>><br>> Instead of the bounding box, it might be better to use the GetRegion<br>> () method of LabelStatisticsImageFilter. This will save you from
<br>> having to create a region from the bounding box.<br>><br>> Bill<br>><br>> On Nov 29, 2007 5:11 PM, Mengchen Zhu <<a href="mailto:acidwind@gmail.com">acidwind@gmail.com</a>> wrote:<br>> Hi everyone,
<br>><br>> I am now trying to extract the regional centers of mass of a<br>> labeled image (output of ConnectedComponentImageFilter and<br>> RelabelComponentImageFilter). Are there any "direct" ways of doing
<br>> this?<br>><br>> My current plan is to first calculate the bounding boxes of each<br>> region using LabelStatisticsImageFilter; and then either manually<br>> compute the CoM, or "convert" the region inside the bounding box to
<br>> image, and use ImageMomentsCalculator to calculate the CoM. I don't<br>> know how to do the conversion exactly for the 2nd method. The 2nd<br>> method is favored somehow because I might need other attributes
<br>> from ImageMomentsCalculator such as principal axes.<br>><br>> The context: I am currently working on registration using ICP; the<br>> extracted centers of mass will serve as inputs to the registration<br>
> process.<br>><br>> Your comments are welcomed. Thanks.<br>><br>> Regards,<br>> MC<br>><br>> _______________________________________________<br>> Insight-users mailing list<br>> <a href="mailto:Insight-users@itk.org">
Insight-users@itk.org</a><br>> <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>><br>><br>> _______________________________________________
<br>> Insight-users mailing list<br>> <a href="mailto:Insight-users@itk.org">Insight-users@itk.org</a><br>> <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users
</a><br><br></div></div><font color="#888888">--<br>Gaëtan Lehmann<br>Biologie du Développement et de la Reproduction<br>INRA de Jouy-en-Josas (France)<br>tel: +33 1 34 65 29 66 fax: 01 34 65 29 09<br><a href="http://voxel.jouy.inra.fr" target="_blank">
http://voxel.jouy.inra.fr</a><br><br><br><br><br></font></blockquote></div><br>