On Fri, Jan 23, 2009 at 5:40 PM, Moreland, Kenneth <[email protected]>wrote:
> First, I would like to mention that the ParaView binaries come with a > program called pvpython that is basically just a python interpreter with the > paths set up. > > That said, I understand that it is not always practical to use pvpython in > lieu of the default python interpreter, so to actually answer your question, > you also have to add this to your PYTHONPATH > > /home/sree/paraview-3.4.0/Utilities/VTKPythonWrapping > > After that, python should find the paraview module. > Thank you for the quick reply. But in the paraview-3.4 directory, I do not have a Utilities directory. I only have bin/ and lib/ s...@durga:~/paraview-3.4.0$ ls bin lib > > > Although not strictly necessary, I also recommend calling > paraview.servermanager.vtkInitializationHelper.Finalize() right before > your script exits. This will make sure that all the VTK object get cleaned > up nicely and is one of the other things that pvpython will do for you. > > -Ken > > > > On 1/23/09 8:59 AM, "Sreejith Kuttanikkad" <[email protected]> wrote: > > Dear Paraview, > > I can't get python scripting working with paraview. I have downloaded > paraview binary 3.4.0 for linux and set pythonpath by > > export > PYTHONPATH="/home/sree/paraview-3.4.0/lib/paraview-3.4/paraview/:/home/sree/paraview-3.4.0/bin/" > in .bashrc file > > and in python when i printed the paths it showed the paraview paths: > > print sys.path > ['', '/home/sree/paraview-3.4.0/lib/paraview-3.4/paraview', > '/home/sree/paraview-3.4.0/bin'.... ] > > however when i followed commands as given in > http://www.paraview.org/Wiki/ParaView/Python_Scripting > the following error occured. > >>> from paraview import servermanager > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > ImportError: No module named paraview > > what I am missing here.. ? > > thanks, > Sreejith > > > > > > **** Kenneth Moreland > *** Sandia National Laboratories > *********** > *** *** *** email: [email protected] > ** *** ** phone: (505) 844-8919 > *** web: > http://www.cs.unm.edu/~kmorel<http://www.cs.unm.edu/%7Ekmorel> > >
_______________________________________________ ParaView mailing list [email protected] http://www.paraview.org/mailman/listinfo/paraview
