[vtkusers] saving memory for XML writers?

tom fogal tfogal at apollo.sr.unh.edu
Fri Jun 24 11:17:29 EDT 2005

Hi all, I've got a data file convertor that takes a proprietary file
format and outputs VTK XML formats. For a typical 1.6gig input file, it
unfortunately takes almost 6gigs of memory at its peak. I'd like to
lower this significantly so we can use it on workstations.

Just reading in the data file takes about 3gigs (as I would expect).
Then, I build a giant RectilinearGrid, and pass that to an XML writer.
I would like to know if I could build the RectilinearGrid piecemeal,
that is, define a grid, write out the grid, delete grid data, write out
one of the three scalar fields, delete it, write out another field,
delete it, etc.. Basically I would like to keep the program overhead to
sizeof(data) + sizeof(one_field_in(data)). Eventually I hope to fix the
proprietary reader so it can read in a single field at a time...

Does anyone know of a way I could do this, or have any other ideas to
save memory?



More information about the vtkusers mailing list