无法检测到vtk python

时间:2013-04-29 01:19:30

标签: python vtk mayavi

VTK工作正常,直到我更新它。我确保打开所有python链接等。

现在,当我运行mayavi2时,我会收到:

dustin@dustin:~$ mayavi2
Traceback (most recent call last):
  File "/usr/local/bin/mayavi2", line 9, in <module>
    load_entry_point('mayavi==4.3.0', 'console_scripts', 'mayavi2')()
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources.py", line 343, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources.py", line 2309, in load_entry_point
    return ep.load()
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources.py", line 2015, in load
    entry = __import__(self.module_name, globals(),globals(), ['__name__'])
  File "/usr/local/lib/python2.7/dist-packages/mayavi/scripts/mayavi2.py", line 457, in <module>
    raise ImportError(msg)
ImportError: libvtkCommonPythonD.so.5.10: cannot open shared object file: No such file or directory
________________________________________________________________________________
Do you have vtk installed properly?

我该如何解决这个问题?

1 个答案:

答案 0 :(得分:2)

我找到了文件libvtkCommonPythonD.so.5.10并将其添加到LD Library Path

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib/vtk-5.10