<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Hello,<div><br></div><div>2) I believe that is the error message when the the filter hasn't been instantiated with that template argument. Poke around itk.BinaryImageToLabelMapFilter's dict interface, some method along the lines 'keys()' should give you a list of the types that have been compiled and can be created.</div><div><br></div><div>hope this helps,</div><div>Brad</div><div><br><div><div>On Sep 15, 2014, at 1:04 PM, gowith king <<a href="mailto:gowithking@googlemail.com">gowithking@googlemail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><div dir="ltr"><div><div>Hi, my Itk friends,<br></div> I am using python warped ITK to write my first itk process to analysis series of mhd images, I test my procedure in slicer4 first to make sure it works well. Then I start the programming. However, two problem block me for a whole day. <br></div><ul><li> The imagetype of itk.Image.UC3 should be used for 16 bit image in all the itk instructions. But in my case it only has a range of 0-255. Then I take itk.Image.F3, then it get a range of '-3.40282346639e+38 3.40282346639e+38' . The grey value of my image is 0-9000 . How could I read it proprietorially?</li></ul><p><br></p><ul><li> I need to get a label map with simply threshold method, and then make few statistics with LabelStatisticsImageFilter. So the BinaryImageToLabelMapFilter is taken. but then the key error occurs: </li></ul><div> LabelFilter = itk.BinaryImageToLabelMapFilter[IUC3].New()<br> File "/usr/local/lib/ITK-4.7/Python/itkTemplate.py", line 263, in __getitem__<br> (str(parameters), self.__name__))<br>KeyError: "itkTemplate : No template [<class 'itkImagePython.itkImageUC3'>] for the itk::BinaryImageToLabelMapFilter class"<br><br><br></div><div> What should I do to achieve the LabelStatisticsImageFilter ?<br></div><div> Thank you in advance<span><330.gif></span><br></div></div>
_______________________________________________<br>Community mailing list<br><a href="mailto:Community@itk.org">Community@itk.org</a><br>http://public.kitware.com/mailman/listinfo/community<br></blockquote></div><br></div></body></html>