在m上导入python中的vtk时出错

2024-04-28 23:21:48 发布

您现在位置:Python中文网/ 问答频道 /正文

当我尝试导入vtk时,它不起作用。 我尝试了this method(使用cmake和update环境变量构建vtk—除了“安装后任务”),但是我仍然有:

$python
Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import vtk
  Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  ImportError: No module named vtk

我之前试过了

^{pr2}$

但它返回:

Error: No available formula with the name "python-vtk" 
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
Error: No formulae found in taps.

如何在Mac电脑上以Python代码导入vtk?在


Tags: noincmakeforsearchingerrorthismethod