Skip to content

Problem with xdmf files not including paths in HDF5 #11

@DaanVanVugt

Description

@DaanVanVugt

Hello, I am trying to run some of the included cases (which run fine) but have a problem visualising the results with Paraview (and with the included postprocessing script).

The xdmf file contains lines like

<DataItem Dimensions="2145 2" Format="HDF">V_from_tstep_0.h5</DataItem>

for every reference to DataItem, while a reference xdmf file should contain a semicolon and then a path, like this example (from https://github.com/MattH688/BERNAISE/blob/master/meshes/mf_flowfocus.xdmf#L6)

<DataItem DataType="Float" Dimensions="9617 3" Format="HDF" Precision="8">mf_flowfocus.h5:/data0</DataItem>

Opening with paraview thus leads to errors like

XDMF Error in /build/paraview/src/ParaView-v5.10.1/VTK/ThirdParty/xdmf2/vtkxdmf2/libsrc/XdmfValuesHDF.cxx line 76 (Can't Open Dataset V_from_tstep_0.h5)
XDMF Error in /build/paraview/src/ParaView-v5.10.1/VTK/ThirdParty/xdmf2/vtkxdmf2/libsrc/XdmfDataItem.cxx line 534 (Reading Values Failed)
XDMF Error in /build/paraview/src/ParaView-v5.10.1/VTK/ThirdParty/xdmf2/vtkxdmf2/libsrc/XdmfGrid.cxx line 755 (Error in Update() of Topology)
(   4.603s) [paraview        ]      vtkXdmfReader.cxx:488    ERR| vtkXdmfReader (0x55b7cb7e40a0): Failed to read data.
(   4.675s) [paraview        ]       vtkExecutive.cxx:752    ERR| vtkPVCompositeDataPipeline (0x55b7cf2f9920): Algorithm vtkFileSeriesReader(0x55b7d40b83a0) returned failure for request: vtkInformation (0x55b7cf36bd20)

Postprocess.py

Errors related to the same problem:

python postprocess.py folder=results_charged_droplet/1/ method=plot save=True                Tue 04 Oct 2022 07:56:27 PM UTC
BERNAISE: Post-processing tool
Sought fields: All
Opening folder: results_charged_droplet/1/
Traceback (most recent call last):
  File "/home/<snip>/BERNAISE/postprocess.py", line 157, in <module>
    main()
  File "/home/<snip>/BERNAISE/postprocess.py", line 145, in main
    ts = TimeSeries(folder, sought_fields=sought_fields)
  File "/home/<snip>/BERNAISE/utilities/TimeSeries.py", line 62, in __init__
    self._load_timeseries(sought_fields)
  File "/home/<snip>/BERNAISE/utilities/TimeSeries.py", line 136, in _load_timeseries
    = parse_xdmf(xml_file, get_mesh_address=True)
  File "/home/<snip>/BERNAISE/common/io.py", line 241, in parse_xdmf
    dset_address = prop[0].text.split(":")[1]
IndexError: list index out of range

Software

name version
BERNAISE (MattH fork) fdeff71 (master)
BERNAISE (this repo) aa45ae5 (master)
HDF5 1.12.2
h5py 3.7.0
dolfin 2019.1.0
python 3.10.7

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions