[vtkusers] Errors running python examples

David Gobbi david.gobbi at gmail.com
Mon Aug 11 21:18:41 EDT 2008


Hi Amit,

There is also a python module directory that must be in the python path. Try

PYTHONPATH=/Users/joshi/Dev/VTK/bin:/Users/joshi/Dev/VTK/Wrapping/Python

It's the vtk directory in VTK/Wrapping/Python that gets loaded by "import vtk".

   David


On Mon, Aug 11, 2008 at 8:59 PM, Amit Joshi <amitjoshi79 at gmail.com> wrote:
>
> I have compiled vtk distribution (4.0) on my macbook (darwin 8.11.1), I was
> wondering why I would be getting an error while running a python example in
> the volumnRendering sample code
>
> when I run python SimpleTextureMap2D.py at the command line I get
>
> Traceback (most recent call last):
>   File "SimpleTextureMap2D.py", line 6, in ?
>     import vtk
> ImportError: No module named vtk
>
> my environment contains PYTHONPATH=/Users/joshi/Dev/VTK/bin which is the
> location containing all the compiled modules (it also has vtkpython binary)
>
> what am I doing wrong ?
>
> -- Amit
>
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>



More information about the vtkusers mailing list