[Insight-users] ImportError: No module named ITKMetricsv4Python

Matt McCormick matt.mccormick at kitware.com
Fri Apr 20 04:07:26 EDT 2012


Hi Mathieu,

The example needed to be updated for WrapITK.  Here is the update:

  http://review.source.kitware.com/#/c/5276/

HTH,
Matt

On Fri, Apr 20, 2012 at 2:59 AM, Mathieu Stumpf
<mathieu.stumpf at etu.unistra.fr> wrote:
> Hello,
>
> Just to be sure it's not just my compilation/installation which is
> wrong, could someone tell me if she can successfully run
> ${itk-src}/Examples/IO/DicomSliceRead.py with ITK ?
>
> I use itk version 4.1.0. If you can run the script under an other
> version, please let me know, hopefully I'll manage to install it and go
> on in my work.
>
> Kind regards,
> mathieu
>
> Le mercredi 18 avril 2012 à 13:02 +0200, Mathieu Stumpf a écrit :
>> Hello,
>>
>> Having to open a 4D image, I can't use SimpleITK which doesn't support
>> it yet (I get the error : Images of Vector Pixel types currently are not
>> supported).
>>
>> So I turn back to ITK and its included python wrapper. So I looked in
>> the nice Examples to see how to open some files, but I'm not able to run
>> a simple example :
>>         ~/src/itk-git/ITK/Examples$ python IO/DicomSliceRead.py
>>         Traceback (most recent call last):
>>           File "IO/DicomSliceRead.py", line 24, in <module>
>>             from InsightToolkit import *
>>           File "/usr/local/lib/ITK-4.1/Python/InsightToolkit.py", line 75, in <module>
>>             from ITKMetricsv4Python import *
>>         ImportError: No module named ITKMetricsv4Python
>>
>> What's wrong, the only installed ITKMetrics file I found in my
>> installation directory was :
>>         /usr/local/lib/cmake/ITK-4.1/Modules/ITKMetricsv4.cmake
>>
>> ITK was already compiled and installed with the python wrapper, so I
>> don't see what eventual step I messed.
>>
>> Kind regards,
>> mathieu
>>
>> _____________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Kitware offers ITK Training Courses, for more information visit:
>> http://www.kitware.com/products/protraining.php
>>
>> Please keep messages on-topic and check the ITK FAQ at:
>> http://www.itk.org/Wiki/ITK_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.itk.org/mailman/listinfo/insight-users
>
>
>
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list