[Paraview] Reader for data file containing multiple kinds of data?
Mike Jackson
mike.jackson at imts.us
Fri Jul 25 11:34:03 EDT 2008
I can get some example code of a reader we are finishing up. We also
store our data in HDF5 files. Some of the data is in a custom format,
some is in a "vtkPolyData" ready state, and other is "2D Plot" type
data.
Our Reader is a based on the vtkUnstructuredGridAlgorithm BUT we have
5 output ports.
Ports 0 and 1 are vtkUnstructuredGrid
Port 2 is a vtkMultiBlockDataSet
Ports 3,4,5 are vtkRectilinearGrid
We then created a new reader class for each of the types of data that
is stored in the HDF5 files. In the top level reader, sub pipelines
are setup to read each of the other types of data. At the end of all
the reading the data is shallow copied back into the output objects
for each port.
In ParaView, what we end up getting is a 3D plot of the
UnstructuredGrids and 3 x 2D Plots of all the other data. It actually
worked out pretty good.
Good Luck.
--
Mike Jackson Senior Research Engineer
Innovative Management & Technology Services
On Jul 25, 2008, at 10:31 AM, John R. Cary wrote:
> I have just ordered the ParaView Guide, and the VTK
> Textbook and User's Guide, so answering by reference to
> those will be most welcome.
>
> My data files are hdf5 with a schema described by data
> attributes, so that I can pick out groups in the file
> and classify them as meshes (rectilinear, structured,
> unstructured, ...) or data, with the latter knowing what
> mesh they live on. So the reader cannot derive from,
> e.g., vtkUnstructuredGridAlgorithm (like the example at
> http://www.paraview.org/Wiki/ParaView:Extend), as the
> data is not all on an unstructured grid.
>
> Furthermore, in the end, I suppose once I get this into
> ParaView, the result of opening a file will be the presence
> of several sources in the pipeline browser of ParaView.
>
> While I am waiting for the arrival of the above noted
> books, can someone point me to any starting point, such
> as class that does something similar to this?
>
> Thanks.....John Cary
>
> PS - we currently parse these files with pytables
> and then make 2D plots with matplotlib.
>
>
> _______________________________________________
> ParaView mailing list
> ParaView at paraview.org
> http://www.paraview.org/mailman/listinfo/paraview
>
More information about the ParaView
mailing list