[Paraview] Problems in running parallel scripts through pvpython

David E DeMarle dave.demarle at kitware.com
Fri Jun 22 11:25:12 EDT 2007


On 22 Jun 2007 13:55:07 -0000, Raashid Baig <raashid.b at rediffmail.com>
wrote:
>
> I have some very fundamentel doubts regarding paraview and its working
> in parallel.
>
> 1. Is it necessary to compile Paraview 3.0.1 from sources in parallel
> to use paraview in parallel, if the binaries are available on n
> different machines will it do the same job ?
>

Yes.
ParaView's server executables require MPI to run in parallel and there are
many different implementations of MPI. For this reason the binaries are
compiled without MPI support. So to run paraview with a parallel server you
must compile paraview from source and enable MPI.

2. I am able to launch pvserver (from the binaries not the compiled
> sources) on 3 different computers using LAM/MPI, is it necessary that
> the computer on which paraview's client will be launched should also
> be within these 3 computer, which were booted through mpirun. If no
> how should I connect to the 3 different severs from paraview ?
>
No the client can be on a different machine which may have a completely
different architecture. The server is conceptually one program with
different parts running on different machines. Start it with a command like
"mpirun -np NUMMACHINES pvserver". Then establish one connection between the
client and the server through the File->Choose Server dialog. Enter in the
machine name of the machine that you run the server on, and then optionally
give it a command line to start the server automatically instead of from the
command line manually.

In the ParaView book it is said that if separate data and render
> servers are running on 2 different clusters (Data Server/ Render
> Server / Client configuration ) the client should connect to the
> master node (or node 0) of both the data server and render server and
> they in turn will connect to the other computers of their respective
> servers.
>
> Nothing is said how to connect when paraview is running in
> Client/Server Mode. Should we connect to the master node of the server
> and the other computers in the server will be controlled by the master
> computer all by itself ? Or we have to do thing on over own ?
>
Yes just connect to the first node of the server (or renderserver and
dataserver) by giving the Choose Server dialog their machine names, and the
servers will take care of themselved through MPI.

> Through GUI we can connect to only one server at a time. If we are
> connected to one server and then connect to a second server the
> connection to the first server is automatically closes.
>

This is an artifact of not having your server built with MPI.

3. How to connect pvpython to server ? No command line argument seems
> to be available with pvpython to connect to a running server. Should
> we use paraview's active connection to connect to a particular server,
> ex. paraview.ActiveConnection = paraview.Connect("10.101.11.71", 11111)
> through script.
>

Yes.

If I try to connect pvpython to a pvserver through script the script
> crashes
>
I am not sure why this crashes for you. Recently there was a bug in creating
displays through pvpython, and we have been doing a great deal of work on
the display architecture in general. If the problem continues after you get
a parallel build built, send another email to the list and we'll try to help
diagnose.

cheers,
Dave DeMarle


----------------------------------------------------------------
> raashid at ogion:~/Desktop/paraview-3.0.1-Linux-x86/bin$ ./pvpython
> Python 2.5 (release25-maint, Dec  9 2006, 14:12:17)
> [GCC 4.1.2 20061115 (prerelease) (Debian 4.1.1-20)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import paraview
> >>> paraview.ActiveConnection = paraview.Connect("10.101.11.71", 11111)
> >>> sphere = paraview.CreateProxy("sources","SphereSource","sources")
> >>> renModule = paraview.CreateRenderWindow()
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkServerConnection.cxx,
> line 67
> vtkServerConnection (0x8260bc0): Server Connection Closed!
>
> raashid at ged:~/Desktop/paraview-3.0.1-Linux-x86/bin$ ./pvserver
> Listen on port: 11111
> Waiting for client...
> Client connected.
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkProcessModule.cxx,
> line 971
> vtkProcessModule (0x8066b00): Cannot create object of type
> "vtkIceTRenderManager".
> while processing
> Message 0 = New
>   Argument 0 = string_value {vtkIceTRenderManager}
>   Argument 1 = id_value {8}
>
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkProcessModule.cxx,
> line 973
> vtkProcessModule (0x8066b00): Aborting execution for debugging purposes.
>
> Aborted
> ----------------------------------------------------------------
>
> If I run the following script through pvpython the same problem occurs
> ------------------------------------------------------------------
> # test2.py
> import paraview
> paraview.ActiveConnection = paraview.Connect("10.101.11.71", 11111)
> # create a sphere and register it under sources.
> sphere = paraview.CreateProxy("sources","SphereSource","sources")
> # create a render module.
> renModule = paraview.CreateRenderWindow()
> renModule.UpdateVTKObjects()
> # create a display
> display = paraview.CreateDisplay(sphere, renModule)
> # reset camera
> renModule.ResetCamera()
> # render.
> renModule.InteractiveRender()
> raw_input("Enter")
>
> raashid at ogion:~/Desktop/paraview-3.0.1-Linux-x86/bin$ ./pvpython test2.py
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkServerConnection.cxx,
> line 67
> vtkServerConnection (0x83e8930): Server Connection Closed!
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 272
> vtkSMCompositeDisplayProxy (0x846d150): Input proxy has no output! Cannot
> create the display
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 1355
> vtkSMCompositeDisplayProxy (0x846d150): Display proxy not created!
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 1282
> vtkSMCompositeDisplayProxy (0x846d150): Objects not created!
>
> Segmentation fault (core dumped)
>
>
>
> On running server the message displayed is :
>
> raashid at ged:~/Desktop/paraview-3.0.1-Linux-x86/bin$ ./pvserver
> Listen on port: 11111
> Waiting for client...
> Client connected.
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkProcessModule.cxx,
> line 971
> vtkProcessModule (0x8066b00): Cannot create object of type
> "vtkIceTRenderManager".
> while processing
> Message 0 = New
>   Argument 0 = string_value {vtkIceTRenderManager}
>   Argument 1 = id_value {8}
>
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkProcessModule.cxx,
> line 973
> vtkProcessModule (0x8066b00): Aborting execution for debugging purposes.
>
> Aborted
>
>
> I had similar doubt which I posted on the mailing list and got a reply
> from Utkarsh Ayachit. As suggested by Utkarsh Ayachit in paraview
> mailing list, Vol 38, Issue 32 a similar script fails in the same
> manner. Utkarsh wrote:-
> "The Distributed stand-alone mode as described in the ParaView book is
> no longer supported by ParaView i.e. to run in parallel, one must run in
> client-server mode. This isn't that cumbersome really,
> instead of"
>   mpirun -np 4 paraview
> we do
>   mpirun -np 4 pvserver
>   paraview (and then connect to the correct server).
>
> Same is true for pvpython.
>
> Here's script to read a file and then render in parallel.
>
> import paraview
> # Create default built in connection
> paraview.ActiveConnection = paraview.Connect("localhost",11111);
>
> # Create the reader proxy.
> # Note that one must create the correct reader based on the type of the
> # file being read.
> reader = paraview.CreateProxy("sources", "ExodusReader", "sources")
> reader.SetFileName("/tmp/somedataset.ex2")
> reader.UpdateVTKObjects()
>
> # Create render window
> renWin = paraview.CreateRenderWindow()
> # Till the view to always render on all processess in parallel and then
> # composite the image together.
> renWin.SetRemoteRenderThreshold(0);
> renWin.UpdateVTKObjects();
>
> # create and add display
> display = paraview.CreateDisplay(reader, renWin)
> # render
> renWin.ResetCamera()
> renWin.StillRender()
>
> I ran mpirun on 3 computers including the computer on which I started the
> pvpython and tried a similar script as suggested in reply
> -----------------------------------------------------------------------
> # test5.py
> import paraview
>
> paraview.ActiveConnection = paraview.Connect("localhost", 11111)
>
> reader = paraview.CreateProxy("sources", "XMLUnstructuredGridReader",
> "sources")
> reader.SetFileName("fire_ug.vtu")
> reader.UpdateVTKObjects()
>
> isosurface_filter = paraview.CreateProxy("filters", "Contour", "filters")
> isosurface_filter.SetInput(reader)
> isosurface_filter.SetContourValues(298.38, 396.84, 495.31, 593.775, 692)
> isosurface_filter.UpdateVTKObjects()
>
> renWin = paraview.CreateRenderWindow()
> renWin.SetRemoteRenderThreshold(0)
> renWin.UpdateVTKObjects()
>
> display1 = paraview.CreateDisplay(isosurface_filter, renWin)
>
> renWin.ResetCamera()
> renWin.StillRender()
> raw_input("Enter")
>
> ------------------------------------------------------------------------
>
> Again this resulted in a crash
>
>
> raashid at ogion:~/Desktop/paraview-3.0.1-Linux-x86/bin$ ./pvpython test5.py
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkServerConnection.cxx,
> line 67
> vtkServerConnection (0x83e8240): Server Connection Closed!
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/Common/vtkServerConnection.cxx,
> line 338
> vtkServerConnection (0x83e8240): Server could failed to gather
> information.
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 272
> vtkSMCompositeDisplayProxy (0x8470430): Input proxy has no output! Cannot
> create the display
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 1355
> vtkSMCompositeDisplayProxy (0x8470430): Display proxy not created!
>
> ERROR: In
> /home/berk/Work/ReleaseBuilds/ParaView3/Servers/ServerManager/vtkSMDataObjectDisplayProxy.cxx,
> line 1282
> vtkSMCompositeDisplayProxy (0x8470430): Objects not created!
>
> Segmentation fault (core dumped)
>
>
> 4. Who does D3 filter work in ParaView3, is its working same as it was
> in the previous version 2.X
>
> I may be missing something very fundamental, can someone please help
> me with this.
>
>
>
>
> [image: 1]<http://adworks.rediff.com/cgi-bin/AdWorks/click.cgi/www.rediff.com/signature-home.htm/1050715198@Middle5/1275197_1268894/1274543/1?PARTNER=3&OAS_QUERY=null+target=new+>
> _______________________________________________
> ParaView mailing list
> ParaView at paraview.org
> http://www.paraview.org/mailman/listinfo/paraview
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/paraview/attachments/20070622/e3812c2e/attachment.html


More information about the ParaView mailing list