[vtkusers] Re: Examples of vtkMPIController

Charles Law charles.law at kitware.com
Tue Jun 20 07:56:12 EDT 2000


Antonio,

A portion of what you need is now available in VTK.  If told to use MPI, 
the vtkMultiProcessController can be used to distribute a VTK application 
across multiple computers in a cluster.

You can read your image in two ways:
1: Each process has its own reader pointing to the same volume file or 
copies of the volume file.
2: A single process has a reader, and ports are used to connect the reader 
to the pipeline in the other processes.

Each pipeline would have its own pipeline to process its piece of the volume.

The results can be collected at any point.  It sounds like you want to 
collect the results after they have been rendered.  This is possible.  Jim 
Ahrens (ahrens at lanl.gov) has code for compositing renderers in different 
processes back into a single renderer.  His code (binary swap and tree 
compositing) is not in VTK yet, but he plans to make it available.  This 
compositing depends on the zbuffer, so if you are volume rendering, or 
using transparency, then you would have to do more work to composite your 
images (i.e. sort back to front).

Another possibility is illustrated in the 
example:  contrib/examplesCxx/ParallelIso.cxx  The polydata could be 
collected into a single process using ports, and a single renderer could be 
used render the results.

Splitting up the data:  Some filters have the ability to supply their 
results in pieces.  The imaging pipeline has always been able to generate 
an arbitrary extent as a part of its update process.  This notion has been 
extended to unstructured data.  The API is: SetUpdateExtent(int piece, int 
numberOfPieces);  It is up to the source in the pipeline to determine what 
a piece contains.  Not many sources can break up their output yet.  They 
simply return the entire output in the first piece, and the other pieces 
are empty.  vtkSynchronizedTemplates3D and vtkConeSource do split up their 
output and were used to test the pipeline. We are working to increase the 
number of filters that have this feature.

Synchronizing the interactors during distributed rendering:  We have done 
this for a parallel end-user-tool / application we are developing for the 
ASCI/Views parallel VTK initiative, but it is in early stages and is not 
available yet.  All you need to do is to transmit the state of the renderer 
(lights, camera, actors) from your main process to your satellite processes 
at the start of each render.

Charles.



> > At 04:49 PM 6/14/00 +0200, you wrote:
> > >Hello Charles,
> > >where I can find some examples about vtkMPIController ?
> > >I trying to parallelize the visualizzation of CT images on a cluster of  4
> > >PCs.
> > >Can you help me? Thank you.
> > >
> > >Antonio
> >
> >
> > ParallelIso.cxx is the most complex example.
> >
> > It depends on what you mean by "visualization of CT images".
> >
> >
> > Charles.
>
>Hi Charles,
>
>I would like to clearly state my problem.
>I have a CT volume  that I would like to visualize in parallel. I have no
>problem in visualizing it on a single machine using vtk.
>
>I am supposed to use MPI using n+1 nodes (n nodes for parallel computing, one
>node as front end), so that my strategy is as follows :
>
>1) on the front end node partition the volum in n subvolumes, roughly the same
>size;
>2) send using MPI the subvolumes to the n computing nodes (one subvolume per
>node);
>3) let the n computing nodes do in parallel the visualization pipeline (each
>one on its assigned subvolumes);
>4) each one of the n computing nodes sends using MPI its final rendering 
>result
>to the front end node;
>5) the front end node gathers the results from the n computing nodes, places
>them in its rendering window and shows the image.
>
>I am able to do handle n renderWindows, but this is not what i would like to
>achieve: the goal is to visualize the result using a single renderWindow  with
>a unique interactor.
>
>
>I am interested to do something like PDVF (los Alamos project). I have
>already asked James P. Ahrens about PDVF and he told me that their code is
>being added to vtk. When it will be released? This is James reply to my mail:
>
> >The ideas of PDVF are currently being integrated into vtk. The folks at 
> Kitware
> >and I are working on a paper on this subject for Vis '00. After the 
> conference
> >deadline (March 31) there will be more information available.
> >
> >Thanks for your interest,
> >--Jim
>
>I need the capability to send and receive using MPI vtk objects.
>Is that the purpose of vtkMPIController?
>Can I use it to handle multiple processes evenly distributed on a beowulf
>cluster?
>Is there something else in vtk I can use to this end? I tried
>vtkMultiProcessController, but it seems to me that it can just handle several
>processes but all of them must be on the same machine, so that it is of no use
>to me.





More information about the vtkusers mailing list