I’m trying to use the functionality of VMTK in the python interpreter (Slicer stable 20210226, Linux. Slicer-VMTK extension installed from the extension manager). When trying to import vtkvmtk I ge the following error:
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "/home/rafael/src/Slicer-stable/build/Slicer-build/NA-MIC/Extensions-29738/SlicerVMTK/lib/Slicer-4.11/qt-loadable-modules/vtkvmtk.py", line 9, in <module>
from .vtkvmtkCommonPython import *
ImportError: attempted relative import with no known parent package
Is this expected? Is there any other way to make use of VMTK in the Slicer python interpreter?
It is just a matter of where Slicer-VMTK installs VMTK DLLs. For example, the DLLs could be in a subdirectory inside the scripted module folder and not directly in the module folder.