Re: [Paraview] [vtkusers] Combining vtk and paraview python scripts

2015-07-22 Thread Jeff Becker
Now that I can load image (uniform rectilinear grid) data using the Python Programmable Source, I'm trying to do this on four gpu nodes (using mpirun -np 4 pvserver). Once I load my image, I thought it would be automatically distributed (equally) to the four nodes, but coloring by process id sh

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-21 Thread Jeff Becker
On 07/20/2015 05:43 PM, Berk Geveci wrote: You probably need to update vtkImageExport and shallow copy its output to the programmable source's output. You also need to add something to the RequestInformation setting the whole extent. You need something like: from paraview import util util.SetO

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-20 Thread Berk Geveci
You probably need to update vtkImageExport and shallow copy its output to the programmable source's output. You also need to add something to the RequestInformation setting the whole extent. You need something like: from paraview import util util.SetOutputWholeExtent(self, [0,nx-1,0,ny-1,0,nz-1])

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-20 Thread Jeff Becker
Hi, On 07/18/2015 05:17 PM, Berk Geveci wrote: To elaborate on what Andy said, you can stick your entire VTK script in side the programmable source. Which you can use in batch mode as well. If you want to keep your VTK script as a reusable code, I recommend making it a module that you import f

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-18 Thread Berk Geveci
To elaborate on what Andy said, you can stick your entire VTK script in side the programmable source. Which you can use in batch mode as well. If you want to keep your VTK script as a reusable code, I recommend making it a module that you import from the programmable source. Best, -berk On Tue, J

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-14 Thread Andy Bauer
All of that functionality is available through pvpython, or pvbatch in parallel. I'd suggest you look into using the GUI's Python trace functionality to help you make that script. pvpython can also be used as an interactive Python shell if you want. On Tue, Jul 14, 2015 at 3:43 PM, Jeff Becker wr

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-14 Thread Jeff Becker
On 07/14/2015 12:20 PM, Andy Bauer wrote: ParaView's Python Programmable Filter and Python Programmable Source use VTK Python wrapping to do the work while making it available in Paraview. Check out http://www.paraview.org/Wiki/Python_Programmable_Filter. Thanks. That's pretty neat, but what

Re: [Paraview] Combining vtk and paraview python scripts

2015-07-14 Thread Andy Bauer
ParaView's Python Programmable Filter and Python Programmable Source use VTK Python wrapping to do the work while making it available in Paraview. Check out http://www.paraview.org/Wiki/Python_Programmable_Filter. On Tue, Jul 14, 2015 at 2:59 PM, Jeff Becker wrote: > Hi. > > As a proof of concep

[Paraview] Combining vtk and paraview python scripts

2015-07-14 Thread Jeff Becker
Hi. As a proof of concept, I have a vtk script that reads some binary data, and produces a vti file. I then have a second script that I generated using ParaView's tracing facility while viewing the data. Now I'd like to combine them, so as to eliminate the intermediate file, i.e., go from bin

Re: [Paraview] Python Scripts and memory

2013-03-26 Thread Berk Geveci
> You do not possibly also have a clue how to get the size of the text field right? Sorry. I don't have an answer for this. Not sure that I understand the question even :-) Hopefully, someone else that is more knowledgeable in this will answer. On Tue, Mar 26, 2013 at 8:44 AM, Dr. Olaf Ippisch <

Re: [Paraview] Python Scripts and memory

2013-03-26 Thread Dr. Olaf Ippisch
Dear Berk, thank you for the fast response and for pointing me to the right point in the a bit scattered Paraview Python documentation. You do not possibly also have a clue how to get the size of the text field right? Best regards, Olaf Am 26.03.13 13:33, schrieb Berk Geveci: > Hi Olaf, > > Giv

Re: [Paraview] Python Scripts and memory

2013-03-26 Thread Berk Geveci
Hi Olaf, Given that there is no memory management in your code, it is not surprising that it leaks :-) One option is to use Delete() to get rid of objects after using them. There is a short section talking about it here: http://paraview.org/Wiki/ParaView/Python_Scripting The even better approach

[Paraview] Python Scripts and memory

2013-03-25 Thread Dr. Olaf Ippisch
Dear Paraview developers and users, I have some problems when using the python interface to paraview. I attached a small program I wrote to visualize data from several time steps of a simulation. Two things are unclear to me: - The program contains a loop over several files to be read from disk a

Re: [Paraview] Python scripts and exit

2012-02-21 Thread Andy Bauer
That worked for me for "bin/pvbatch ". I did get 2 debug leak warnings but no problems exiting. If I comment out exit(), I don't get the leaks. When I ran in parallel I get similar behavior with respect to using exit(). I do have to use the -sym flag (mpirun -np X bin/pvbatch -sym ) though with

[Paraview] Python scripts and exit

2012-02-21 Thread Scott, W Alan
When I run pvbatch, with the following script, pvbatch never exits. Is there a way to get pvbatch to exit? # write a file f = open('/... /working.txt', 'w') f.write('script worked\n') f.close() # exit exit() Thanks, Alan W. Alan Scot

Re: [Paraview] Python scripts with PyQt4

2010-04-21 Thread pat marion
PyQt can be made to work with paraview. Make sure paraview and pyqt use the same version of qt. It works for me using qt 4.6.2 compiled from source, and system pyqt (apt-get install python-qt4.) Don't create a QApplication or call exec_(), paraview already has an application event loop running.

Re: [Paraview] Python scripts with PyQt4

2010-04-17 Thread Berk Geveci
Hi Stefan, I am afraid what you are trying to do is not supported. I am saying "not supported" rather than "impossible" because someone smarter than me may be able to figure it out. We never envisioned it as a use case. I think you have two choices: use C++ to extend ParaView or use PyQt from pyth

[Paraview] Python scripts with PyQt4

2010-04-09 Thread Stefan Kroboth
Hello! I've build a Gui in the QtDesigner and converted it into a *.py file using pyuic4. Then I wrote a small program which loads and shows this Window. This program works fine in Python 2.6 but fails in the ParaView python shell. Since I'm new to Qt I don't know where to look for help. Is it

Re: [Paraview] python scripts

2008-09-24 Thread Patrick Shinpaugh
It was my fault. I had named the scripts by the vis software being used so paraview.py, visit.py, etc. Changing it to pv.py fixed it. Thanks very much for the help, Pat Utkarsh Ayachit wrote: In /home/project is there a "paraview.py" or a directory named "paraview" ? If so, try moving or rena

Re: [Paraview] python scripts

2008-09-24 Thread Utkarsh Ayachit
In /home/project is there a "paraview.py" or a directory named "paraview" ? If so, try moving or renaming that. Utkarsh Patrick Shinpaugh wrote: I created the script you posted. The results of each are displayed below: pvpython ~/paraview-test-path.py ['/home/project', '/usr/local/ParaView-3.

Re: [Paraview] python scripts

2008-09-24 Thread Patrick Shinpaugh
I created the script you posted. The results of each are displayed below: pvpython ~/paraview-test-path.py ['/home/project', '/usr/local/ParaView-3.2.2/lib/paraview-3.2', '/usr/lib/python25.zip', '/usr/lib/python2.5', '/usr/lib/python2.5/plat-linux2', '/usr/lib/python2.5/lib-tk', '/usr/lib/pyth

Re: [Paraview] python scripts

2008-09-24 Thread Utkarsh Ayachit
That's weird. from paraview import servermanager should work from all the 3 locations client, pvbatch or pvpython. Can you try the following script and print your path in all the three applications? import sys print sys.path Utkarsh Patrick Shinpaugh wrote: Hi, I've been writing some python

[Paraview] python scripts

2008-09-24 Thread Patrick Shinpaugh
Hi, I've been writing some python scripts and running them through the paraview GUI. I start the scripts with from paraview import servermanager When I use pvpython or pvbatch to run the same scripts I receive an error: [project] pvpython paraview.py Traceback (most recent call last): Fil