[Rtk-users] Itk and rtk python install issues

Simon Rit simon.rit at creatis.insa-lyon.fr
Tue Jul 14 14:18:08 EDT 2020


Hi,
I think the current RTK package on pypi is outdated wrt to ITK's. Either
you use ITK v5.0.1 or you use the RTK package compiled by the CI. I think this
one
<https://dev.azure.com/simonrit/RTK/_build/results?buildId=621&view=artifacts&type=publishedArtifacts>
for example works. We will upload a new version after the ITK v5.1.1
release planned for the end of this week.
Simon

On Tue, Jul 14, 2020 at 5:49 PM Andrew Mark <amark at magneticinsight.com>
wrote:

> Hello,
>
>
>
> I am an ITK and RTK beginner. I am trying to use itk-rtk (Python). Before
> attempting to build from source, I decided to try the precompiled binaries.
> I set up a clean environment with python3.7 installed (via Miniconda) on
> Windows 10 and ran the following:
>
>
>
> Python -m pip install itk
>
> Python -m pip install itk-rtk
>
>
>
> I verified I could import both packages, and I then attempted to run
> FirstReconstruction.py, which is part of the RTK repo.
>
>
>
> I got a lazy loading error:
> ```
>
> itkPointSetD3 not loaded from module ITKRegistrationCommon because of
> exception:
>
> module 'itk.ITKRegistrationCommonPython' has no attribute 'itkPointSetD3'
>
> Traceback (most recent call last):
>
>   File "FirstReconstruction.py", line 19, in <module>
>
>     geometry = rtk.ThreeDCircularProjectionGeometry.New()
>
>   File "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itkLazy.py",
> line 52, in __getattribute__
>
>     itkBase.LoadModule(module, namespace)
>
>   File "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itkBase.py",
> line 99, in LoadModule
>
>     module = loader.load(swig_module_name)
>
>   File "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itkBase.py",
> line 220, in load
>
>     module.__loader__.exec_module(module)
>
>   File "<frozen importlib._bootstrap_external>", line 728, in exec_module
>
>   File "<frozen importlib._bootstrap>", line 219, in
> _call_with_frames_removed
>
>   File
> "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itk\RTKPython.py",
> line 119, in <module>
>
>     from itkFixedArrayRTKPython import *
>
>   File
> "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itk\Configuration\..\itkFixedArrayRTKPython.py",
>
> line 106, in <module>
>
>     import pyBasePython
>
>   File
> "C:\Users\amark\Miniconda3\envs\mi\lib\site-packages\itk\Configuration\..\pyBasePython.py",
> line 8, in
>
> <module>
>
>     from . import _ITKPyBasePython
>
> ImportError: attempted relative import with no known parent package
>
> ```
>
>
>
> Does anyone have any insight? Once I get this working, could I expect the
> precompiled binaries to allow me to run the CUDA accelerated version of
> this example?
>
>
>
> Thanks!
>
>
>
> Andrew
>
>
> _______________________________________________
> Rtk-users mailing list
> Rtk-users at public.kitware.com
> https://public.kitware.com/mailman/listinfo/rtk-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/rtk-users/attachments/20200714/62fabebd/attachment.htm>


More information about the Rtk-users mailing list