[Paraview] Use one statefile for multiple time values

Eelco van Vliet eelcovv at gmail.com
Tue Aug 9 15:47:09 EDT 2011


Hi Utkarsh,

This is excellent! I have been putting quite some time in a work around, but
is was making things complicated, so I hope this patch helps.

If I find a bug, does it mean that I can put it to this
paraview.org/Bugside? Because I have two more bugs (at least, that's
what I suspect)
:
1) pythonCalculator does not work in parallel (with mpirun) (I gave a larger
post on this proplem two weeks ago)

2) When running with pvbatch --offscreen-rendering option, it seems that
when looping over a large set of time steps, the memory is not released when
reading time step using the same LegacyVTKReader, even when the Delete is
called on the data object. And even with a del <variable name> (I found on
one of the paraview sites that this actually should free the memory.)
Especially for a large set of time steps this becomes  a problem because my
computer runs out of memory. If I run the same script without
--offscreen-rendering option the problem does not occur, but in that way you
can not submit the script to a cluster.

Would it help if I send the bugs with an example to the Mantis side?

Again many thanks for your patch!

Regards

Eelco


On Tue, Aug 9, 2011 at 7:43 PM, Utkarsh Ayachit <utkarsh.ayachit at kitware.com
> wrote:

> FYI: http://paraview.org/Bug/view.php?id=12489
>
> Utkarsh
>
> On Tue, Aug 9, 2011 at 1:35 PM, Utkarsh Ayachit
> <utkarsh.ayachit at kitware.com> wrote:
> > The problem is indeed in the reader. I've attached  a patch for the
> > issue. It will be committed into git-master soon.
> >
> >
> > Utkarsh
> >
> > On Mon, Aug 8, 2011 at 10:36 AM, Eelco van Vliet <eelcovv at gmail.com>
> wrote:
> >> Hi Utkarsh,
> >>
> >> I am using the LegacyVTKReader. Looking at the reader properties I see
> that
> >> indeed the new filename is in the reader object, but still the first
> file as
> >> defined in the state file is used for plotting.
> >>
> >> Regards
> >> Eelco
> >>
> >>
> >> On Mon, Aug 8, 2011 at 11:46 AM, Eelco van Vliet <eelcovv at gmail.com>
> wrote:
> >>>
> >>> Hello paraviewers,
> >>>
> >>> According to the information I found here
> >>> http://www.itk.org/Wiki/ParaView/Users_Guide/Batch_Processing (bottom
> page)
> >>> it should be able to Load a state file and then to change the file name
> to
> >>> apply the same state on  multi files (for making an animation for
> instance)
> >>>
> >>> sm=servermanager
> >>> sm.Connect()
> >>>
> >>> sm.LoadState(opt.statefile)
> >>> view=GetRenderViews()[0]
> >>> cnt=0
> >>> for time in timesteps:
> >>>    ts=[]
> >>>    ts.append(filelist[cnt])
> >>>    reader.FileNames = ts
> >>>    reader.FileNameChanged()
> >>>    reader.UpdatePipeline()
> >>>
> >>>   format="%%s/%%s/%%s/%%s_t%s%%s" % (opt.timeformat)
> >>>   jpgfile=format %
> >>> (path,opt.casedir,opt.outputdir,opt.imbase,float(time),jpgext)
> >>>   view.ResetCamera()
> >>>   view.StillRender()
> >>>   view.WriteImage(jpgfile,"vtkPNGWriter",1)
> >>>   cnt=cnt+1
> >>>
> >>> However, the scrips keeps showing only the data associate with the
> first
> >>> file in the state file. If I print the properties of the reader with
> >>>  for i in dir(reader):
> >>>       print "reader.%s = %s" % (i,getattr(reader,i))
> >>> I can see that in the reader object the filename indeed has change, but
> >>> the change are not reflected to the newly rendered image. I seems that
> >>> UpdatePipe() does not work.
> >>> Does anybody sees what goes wrong and how I can fix this ?
> >>>
> >>> Many thanks
> >>>
> >>> Regards
> >>>
> >>> Eelco
> >>>
> >>
> >>
> >> _______________________________________________
> >> Powered by www.kitware.com
> >>
> >> Visit other Kitware open-source projects at
> >> http://www.kitware.com/opensource/opensource.html
> >>
> >> Please keep messages on-topic and check the ParaView Wiki at:
> >> http://paraview.org/Wiki/ParaView
> >>
> >> Follow this link to subscribe/unsubscribe:
> >> http://www.paraview.org/mailman/listinfo/paraview
> >>
> >>
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20110809/ea4ecc89/attachment.htm>


More information about the ParaView mailing list