[Paraview] Cutting With Python

Berk Geveci berk.geveci at kitware.com
Fri Feb 29 16:50:31 EST 2008


Never use 'a' unless you are writing a python script for the python
programmable filter. Always use proxies. Always means:
  * Stand-alone paraview
  * Client-server paraview
  * batch
  * ...

In the case of batch, client means first node. The python script is
executed only by the first node. The servermanager library is used to
instantiate the VTK objects on all nodes and to modify them. If you
create a VTK object directly from python, it will be available only on
the first node.

There are a few other unlesses (is that a word?) but I am skipping
those for the sake of simplicity.

-berk


On 2/29/08, Kent Eschenberg <eschenbe at psc.edu> wrote:
> Thanks for the information! This should really jump to a list for PV
>  developers, if one existed, since most of you just use it interactively.
>  However, if you plan to use batch mode, read on.
>
>
>  Berk Geveci wrote:
>  >>  1) Why are there items in servermanager that are NOT already proxys? As I
>  >>  understand it servermanager is used only in client-server mode.
>  >
>  > I am not sure I understand the question. Also, servermanager is always
>  > used not only in client-server mode. It is the Model, in paraview's
>  > Model-View architecture. There are a few cases where it is required to
>  > access the client-side VTK objects directly but most of the time, you
>  > should access proxies only.
>
>
> Sorry I wasn't clear. Lets say I am only working with a Python script to be
>  used by pvbatch. There is no client.
>
>  Maybe there is a division here that is not yet clear. From Python its starting
>  to sound like one could use two styles:
>
>  a) Work directly with the server-side VTK objects using the Python wrappers
>  found in servermanager.vtk (e.g., a simple Python version of the C++ routines); or
>
>  b) Work with proxys for the VTK objects found in
>  servermanager.sources/filters/rendering or proxy objects created as Utkarsh
>  described using servermanager.createModule.
>
>  **If** that is correct then
>
>  1) What I did was to try to add something from 'a' directly to a pipeline being
>  built with 'b' and that of course failed.
>
>  2) Are their situations where style 'a' is better/worse than 'b'?
>
>  3) Does 'a' support parallel processing?
>
>  Kent
>  Pittsburgh Supercomputing Center
>
> _______________________________________________
>  ParaView mailing list
>  ParaView at paraview.org
>  http://www.paraview.org/mailman/listinfo/paraview
>


More information about the ParaView mailing list