[vtkusers] Problems Installing VTK-Python on OSX

David Gobbi david.gobbi at gmail.com
Fri Mar 4 08:35:31 EST 2016


Hi Ranveer,

The error "PyThreadState_Get: no current thread" almost always means that
VTK was linked to the wrong version of Python.  I know you said that you
checked this, but I recommend that you load CMakeCache.txt into a text
editor and do a thorough search to make sure that "python2" does not appear
anywhere.  My own OS X system builds VTK against Python 3.5.

 - David

On Fri, Mar 4, 2016 at 12:25 AM, Ranveer Aggarwal <ranveeraggarwal at gmail.com
> wrote:

> Hello all,
>
> I have been struggling with this problem for quite some time now. Here's
> what I did.
>
> 1. Downloaded source tar.gz and untarred it.
> 2. Went to the downloaded folder and made a build folder and ran ccmake ..
> in it.
> 3. Set Python Wrapping to on and set Python version as 3.5. Went to
> advanced options and appropriately set all the Python 3.5 libraries.
> 4. Generated the cmake and ran it.
> 5. Ran make and then make install
> 6. Added
> "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/vtk/"
> to PYTHONPATH.
>
> Now, when I run python3 and do an `import vtk`, I get
>
> Fatal Python error: PyThreadState_Get: no current thread
> Segmentation fault: 11
>
> and Python crashes. Any idea why this could be happening? Any help would
> be highly appreciated.
> --
>
> Sincerely,
> Ranveer Aggarwal
> Indian Institute of Technology, Bombay
> http://ranveeraggarwal.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160304/b0fa0548/attachment.html>


More information about the vtkusers mailing list