[petsc-users] HDF5 and ParaView

Matthew Knepley knepley at gmail.com
Thu Jul 9 15:10:34 CDT 2020


On Thu, Jul 9, 2020 at 3:28 PM David Scott <d.scott at epcc.ed.ac.uk> wrote:

> Matt,
>
> I'll have a go at writing Xdmf files.
>
> Am I right in thinking that VTK files are written sequentially?
>

Yes, it is a rightly despised format, suitable only for beggars and serial
jobs :)

  Thanks,

     Matt


> Thanks,
>
> David
>
> On 09/07/2020 20:17, Matthew Knepley wrote:
>
> On Thu, Jul 9, 2020 at 2:51 PM David Scott <d.scott at epcc.ed.ac.uk> wrote:
>
>> Hello,
>>
>> I have written out a Vec using the (Fortran) HDF5 routines provided by
>> PETSc.
>> I now want to import the data into ParaView 5.8.0 and display a contour.
>> I can read the data in using VisItPixieReader but the contour tool is
>> not available. Can I use the HDF5 files produced by PETSc 13.3.3 with
>> ParaView and, if so, how?
>>
>
> When you call VecView(), it just writes an array of real numbers to the
> HDF5 file. If Paraview can use an array
> of real numbers, then you are all set. I don't know how to make Paraview
> do that. What I do is to write an
> Xdmf file that points to the HDF5 file for the data and specifies the mesh
> using XML. Note  that you can have
> a DMDA or DMPlex write VTK files, which Paraview can read directly.
>
>   Thanks,
>
>      Matt
>
>
>> David
>>
>>
>>
>> The University of Edinburgh is a charitable body, registered in Scotland,
>> with registration number SC005336.
>>
>
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which their
> experiments lead.
> -- Norbert Wiener
>
> https://www.cse.buffalo.edu/~knepley/
> <http://www.cse.buffalo.edu/~knepley/>
>
>
>

-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200709/98dc9cb6/attachment.html>


More information about the petsc-users mailing list