[vtkusers] newbie problems with vtk4.0/python on irix
P Sherwood
P.Sherwood at dl.ac.uk
Sun Jan 6 06:21:00 EST 2002
Hi,
I am having trouble getting started with VTK & Python on an SGI (R4400
processor, Irix 6.5). I have downloaded and built VTK (version 4.0)
with the python bindings but I am not sure how to prepare Python to
import the vtk modules. I found a comment in
VTK/Wrapping/Python/vtk/README.txt that PYTHON path should include the
VTK/Wrapping/Python directory. When I tried this the higher level
import started, but the lower level kits were not found:
% setenv PYTHONPATH "/scr1/psh/Python-2.2/lib/python2.2:/scr1/psh/vtk/VTK/Wrapping/Python"
% python
Python 2.2 (#2, Jan 5 2002, 16:27:46) [C] on irix6
Type "help", "copyright", "credits" or "license" for more information.
>>> from vtkpython import *
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/scr1/psh/vtk/VTK/Wrapping/Python/vtkpython.py", line 29, in ?
exec "from "+kit_name+" import *"
File "<string>", line 1, in ?
ImportError: No module named libvtkCommonPython
This doesn't seem unreasonable given that no files pertaining to
vtkCommon reside in
I then looked for files that could be loaded for libvtkCommonPython,
the only thing I could find was libvtkCommonPython.so was in the bin
directory, so tried adding this to PYTHONPATH. The load is attempted
but fails as follows:
% setenv PYTHONPATH "/scr1/psh/Python-2.2/lib/python2.2:/scr1/psh/vtk/VTK/Wrapping/Python:/\scr1/psh/vtk/VTK/bin"
% python
Python 2.2 (#2, Jan 5 2002, 16:27:46) [C] on irix6
Type "help", "copyright", "credits" or "license" for more information.
>>> from vtkpython import *
Fatal Python error: Interpreter not initialized (version mismatch?)
Abort (core dumped)
I have tried this with both versions 2.1 and 2.2 or Python, with the
same result. Does anyone have any idea what I am doing wrong?
VTK itself does seem to work (c++ and Tcl/Tk examples seem fine).
many thanks,
Paul Sherwood
======================================================================
Dr Paul Sherwood, email: p.sherwood at daresbury.ac.uk
CLRC Daresbury Lab, tel: +44-1925-603553
Warrington, fax: +44-1925-603634
WA4 4AD, UK. http: http://www.cse.clrc.ac.uk
======================================================================
More information about the vtkusers
mailing list