pvd collection of pvtu files gives blank output

Hello,

I have many *.pvtu.* files which I am able to open and view as a set. I now want to combine this and form a single time series dataset. I have used the following .pvd file.

<?xml version="1.0"?>
<VTKFile type="Collection" version="0.1" byte_order="LittleEndian" compressor="vtkZLibDataCompressor">
<Collection>
<Dataset timestep="0.0" part="0" file="output.pvtu.0"/>
<Dataset timestep="2.28407e-09" part="1" file="output.pvtu.1"/>
<Dataset timestep="4.56808e-09" part="2" file="output.pvtu.2"/>
<Dataset timestep="6.85196e-09" part="3" file="output.pvtu.3"/>
<Dataset timestep="9.13562e-09" part="4" file="output.pvtu.4"/>
<Dataset timestep="1.1419e-08" part="5" file="output.pvtu.5"/>
<Dataset timestep="1.37021e-08" part="6" file="output.pvtu.6"/>
<Dataset timestep="1.59847e-08" part="7" file="output.pvtu.7"/>
<Dataset timestep="1.82664e-08" part="8" file="output.pvtu.8"/>
<Dataset timestep="2.05473e-08" part="9" file="output.pvtu.9"/>
<Dataset timestep="2.28271e-08" part="10" file="output.pvtu.10"/>
<Dataset timestep="2.51059e-08" part="11" file="output.pvtu.11"/>
<Dataset timestep="2.73836e-08" part="12" file="output.pvtu.12"/>
<Dataset timestep="2.96601e-08" part="13" file="output.pvtu.13"/>
</Collection>
</VTKFile>

When I read this with Paraview 5.6, I get a blank output. I also tried adding group="" in the specification of Dataset but couldn’t succeed. What is wrong with my .pvd file? What changes should I make to get the desired output?

Here is a working .pvd file :

<VTKFile type="Collection" version="1.0" byte_order="LittleEndian" header_type="UInt64">
  <Collection>
    <DataSet timestep="0" part="0" file="pvdoutput/pvdoutput_0_0.pvtu"/>
    <DataSet timestep="0.000100074" part="0" file="pvdoutput/pvdoutput_0_1.pvtu"/>
    <DataSet timestep="0.000199905" part="0" file="pvdoutput/pvdoutput_0_2.pvtu"/>
    <DataSet timestep="0.000299964" part="0" file="pvdoutput/pvdoutput_0_3.pvtu"/>
    <DataSet timestep="0.000400087" part="0" file="pvdoutput/pvdoutput_0_4.pvtu"/>
    <DataSet timestep="0.000499919" part="0" file="pvdoutput/pvdoutput_0_5.pvtu"/>
    <DataSet timestep="0.000599935" part="0" file="pvdoutput/pvdoutput_0_6.pvtu"/>
    <DataSet timestep="0.000700049" part="0" file="pvdoutput/pvdoutput_0_7.pvtu"/>
    <DataSet timestep="0.000800035" part="0" file="pvdoutput/pvdoutput_0_8.pvtu"/>
    <DataSet timestep="0.000900061" part="0" file="pvdoutput/pvdoutput_0_9.pvtu"/>
    <DataSet timestep="0.00100001" part="0" file="pvdoutput/pvdoutput_0_10.pvtu"/>
    <DataSet timestep="0.00109998" part="0" file="pvdoutput/pvdoutput_0_11.pvtu"/>
    <DataSet timestep="0.00119993" part="0" file="pvdoutput/pvdoutput_0_12.pvtu"/>
    <DataSet timestep="0.00129999" part="0" file="pvdoutput/pvdoutput_0_13.pvtu"/>
    <DataSet timestep="0.00140009" part="0" file="pvdoutput/pvdoutput_0_14.pvtu"/>
    <DataSet timestep="0.00150004" part="0" file="pvdoutput/pvdoutput_0_15.pvtu"/>
    <DataSet timestep="0.00159992" part="0" file="pvdoutput/pvdoutput_0_16.pvtu"/>
    <DataSet timestep="0.0017" part="0" file="pvdoutput/pvdoutput_0_17.pvtu"/>
    <DataSet timestep="0.00180007" part="0" file="pvdoutput/pvdoutput_0_18.pvtu"/>
    <DataSet timestep="0.00190002" part="0" file="pvdoutput/pvdoutput_0_19.pvtu"/>
    <DataSet timestep="0.00199999" part="0" file="pvdoutput/pvdoutput_0_20.pvtu"/>
    <DataSet timestep="0.00209993" part="0" file="pvdoutput/pvdoutput_0_21.pvtu"/>
    <DataSet timestep="0.00219992" part="0" file="pvdoutput/pvdoutput_0_22.pvtu"/>
    <DataSet timestep="0.00229999" part="0" file="pvdoutput/pvdoutput_0_23.pvtu"/>
    <DataSet timestep="0.00240005" part="0" file="pvdoutput/pvdoutput_0_24.pvtu"/>
    <DataSet timestep="0.00249994" part="0" file="pvdoutput/pvdoutput_0_25.pvtu"/>
    <DataSet timestep="0.00259992" part="0" file="pvdoutput/pvdoutput_0_26.pvtu"/>
    <DataSet timestep="0.00269998" part="0" file="pvdoutput/pvdoutput_0_27.pvtu"/>
    <DataSet timestep="0.0028" part="0" file="pvdoutput/pvdoutput_0_28.pvtu"/>
    <DataSet timestep="0.00289991" part="0" file="pvdoutput/pvdoutput_0_29.pvtu"/>
    <DataSet timestep="0.00300002" part="0" file="pvdoutput/pvdoutput_0_30.pvtu"/>
    <DataSet timestep="0.00309998" part="0" file="pvdoutput/pvdoutput_0_31.pvtu"/>
    <DataSet timestep="0.00319999" part="0" file="pvdoutput/pvdoutput_0_32.pvtu"/>
    <DataSet timestep="0.00329994" part="0" file="pvdoutput/pvdoutput_0_33.pvtu"/>
    <DataSet timestep="0.00340002" part="0" file="pvdoutput/pvdoutput_0_34.pvtu"/>
    <DataSet timestep="0.00349997" part="0" file="pvdoutput/pvdoutput_0_35.pvtu"/>
    <DataSet timestep="0.00359999" part="0" file="pvdoutput/pvdoutput_0_36.pvtu"/>
    <DataSet timestep="0.00369996" part="0" file="pvdoutput/pvdoutput_0_37.pvtu"/>
    <DataSet timestep="0.00379999" part="0" file="pvdoutput/pvdoutput_0_38.pvtu"/>
    <DataSet timestep="0.00389998" part="0" file="pvdoutput/pvdoutput_0_39.pvtu"/>
    <DataSet timestep="0.00399999" part="0" file="pvdoutput/pvdoutput_0_40.pvtu"/>
    <DataSet timestep="0.00410001" part="0" file="pvdoutput/pvdoutput_0_41.pvtu"/>
    <DataSet timestep="0.00419997" part="0" file="pvdoutput/pvdoutput_0_42.pvtu"/>
    <DataSet timestep="0.00429999" part="0" file="pvdoutput/pvdoutput_0_43.pvtu"/>
  </Collection>
</VTKFile>

I would suggest using ParaView to open your timeseries and then save as a pvd file.

Hi Mathieu,

Thanks for the response. In my case, timestep data is written to a single separate file which only contains two columns corresponding to output counter and time. I have written a python script to read this file and generate a .pvd file. So if I open *.pvtu.* files as a set and save the data as .pvd, I will still be missing on the time data. Is there a way to read the timestep file along with *.pvtu.* file set? I would then not require the .pvd file.

No, but you will be able to generate a correctly formated .pvd file and you could then add your timestep in.

I made a silly mistake! I used Dataset with a small ‘s’ and hence paraview was ignoring all these elements. Sorry for not checking my format.

But now I have another issue. It seems like paraview is unable to ascertain the format of the files since they have an extension .pvtu.n rather than just .pvtu. These are the first two lines of the error message.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/ParaViewCore/VTKExtensions/Default/vtkXMLCollectionReader.cxx, line 444
vtkPVDReader (0x560858045d20): Could not determine the data type for the first dataset. Please make sure this file format is supported.

In the DataSet element, is there a way to specify explicitly that this file is a .pvtu file? How can I resolve this?

Thanks for the quick response and sorry for my negligence in previous post.

filename.pvtu.n is not a valid file format.

use this numbering instead.
filename_n.pvtu

1 Like