CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[General] Time steps, XDMF, and HDF5

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 22, 2014, 16:54
Post Time steps, XDMF, and HDF5
  #1
New Member
 
Nick Fyn
Join Date: Jul 2014
Posts: 1
Rep Power: 0
Atholis is on a distinguished road
Heyo!! I've been having troubles with Paraview's ability on reading timesteps. I'm using HDF5 and XDMF to view data in VisIt and Paraview. VisIt doesn't need a 'temporal collection' to view time steps, but Paraview does. Two of my xdmf files are below to give an idea on what I'm looking at. Grid is (30, 20, 10) written is staggered format with the original first and last values lopped off, which is why my dimensions look odd in the file.
(Please assume any typos in my xmf files are copy errors, the individual files are working fine)

Paraview_1000.xdmf
Code:
<?xml version="1.0" ?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" []>
<Xdmf Version="2.0">
 <Domain>
   <Grid Name="mesh1" GridType="Uniform">
     <Topology TopologyType="3DSMesh" NumberOfElements="9 19 29"/>
     <Geometry GeometryType="X_Y_Z">
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1000_test.h5:/X
       </DataItem>
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1000_test.h5:/Y
       </DataItem>
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1000_test.h5:/Z
       </DataItem>
     </Geometry>
     <Attribute Name="Density" AttributeType="Scalar" Center="Cell">
       <DataItem Dimensions="8 18 28" NumberType="Float" Precision="7" Format="HDF">
        1000_test.h5:/Density
       </DataItem>
 <---------Lot's more data----------->
     </Grid>
 </Domain>
</Xdmf>
Paraview_1001.xdmf
Code:
<?xml version="1.0" ?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" []>
<Xdmf Version="2.0">
 <Domain>
   <Grid Name="mesh1" GridType="Uniform">
     <Topology TopologyType="3DSMesh" NumberOfElements="9 19 29"/>
     <Geometry GeometryType="X_Y_Z">
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1001_test.h5:/X
       </DataItem>
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1001_test.h5:/Y
       </DataItem>
       <DataItem Dimensions="9 19 29" NumberType="Float" Precision="7" Format="HDF">
        1001_test.h5:/Z
       </DataItem>
     </Geometry>
     <Attribute Name="Density" AttributeType="Scalar" Center="Cell">
       <DataItem Dimensions="8 18 28" NumberType="Float" Precision="7" Format="HDF">
        1001_test.h5:/Density
       </DataItem>
     </Attribute>
<------even more data------>
    </Grid>
  </Domain>
</Xdmf>
I've looked online and have seen I need
Code:
GridType="Collection" CollectionType="Temporal"
for it, but I haven't seen anything that gives an example of how the syntax works. Any and all help is appreciated!
Atholis is offline   Reply With Quote

Old   April 29, 2015, 06:30
Default
  #2
Member
 
hadrien calmet
Join Date: Nov 2011
Posts: 34
Rep Power: 15
hadrien51 is on a distinguished road
Hi Atholis
sorry I answer you very late but we deal with this also
If it can help you or some one else

look this example
it is CollectionType="Temporal
with <Time Type="Single" Value=" 0.00850" />
for each time step

Code:
<?xml version="1.0" ?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" [
<!ENTITY InitialHeavyData "data.mesh.h5">
]>
 
 <Xdmf>
  <Domain>
    <Grid Name="fensap" GridType="Collection" CollectionType="Temporal" >
 
    <Grid Name="fensap" Type="Uniform" >
    <Time Type="Single" Value="   0.00850" />
    <Topology Type="Mixed" NumberOfElements="     3848219">
     <DataStructure Dimensions="    19241095" NumberType="Int" Format="HDF" >fensap-mesh.h5:/CONNE </DataStructure>
     </Topology>
     <Geometry GeometryType="XYZ">
     <DataStructure Dimensions="3      778115" NumberType="Float" Presicion="8" Format="HDF" >fensap-mesh.h5:/COORD </DataStructure>
     </Geometry>
     <Attribute Name="VELOC" Center="Node" AttributeType="Vector"> 
     <DataStructure Format="HDF" DataType="Float" Precision="8" Dimensions="3      778115">fensap-0000001.h5:/VELOC </DataStructure>
     </Attribute>
     <Attribute Name="PRESS" Center="Node" AttributeType="Scalar"> 
     <DataStructure Format="HDF" DataType="Float" Precision="8" Dimensions="      778115">fensap-0000001.h5:/PRESS </DataStructure>
     </Attribute>
     </Grid>
 
    <Grid Name="fensap" Type="Uniform" >
    <Time Type="Single" Value="   0.01700" />
    <Topology Type="Mixed" NumberOfElements="     3848219">
     <DataStructure Dimensions="    19241095" NumberType="Int" Format="HDF" >fensap-mesh.h5:/CONNE </DataStructure>
     </Topology>
     <Geometry GeometryType="XYZ">
     <DataStructure Dimensions="3      778115" NumberType="Float" Presicion="8" Format="HDF" >fensap-mesh.h5:/COORD </DataStructure>
     </Geometry>
     <Attribute Name="VELOC" Center="Node" AttributeType="Vector"> 
     <DataStructure Format="HDF" DataType="Float" Precision="8" Dimensions="3      778115">fensap-0000002.h5:/VELOC </DataStructure>
     </Attribute>
     <Attribute Name="PRESS" Center="Node" AttributeType="Scalar"> 
     <DataStructure Format="HDF" DataType="Float" Precision="8" Dimensions="      778115">fensap-0000002.h5:/PRESS </DataStructure>
     </Attribute>
     </Grid>

    </Grid>
  </Domain>
 </Xdmf>
hadrien51 is offline   Reply With Quote

Reply

Tags
hdf5, paraview, temporal, xdmf


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
HDF5 IO library for OpenFOAM haakon OpenFOAM Programming & Development 41 April 21, 2023 09:30


All times are GMT -4. The time now is 17:55.