Combining close times from multiple readers


I have simulation where multiple solvers are outputting data at the same simulation rate. The problem is that, time being a floating double, the timesteps are not exactly the same. In the attached picture, you can see that I am effectively doubling the amount of timesteps that I have by having two of each. Is there a way I can combine them based on some “closeness” criteria?

This question has actually come up before. It took me a little while to find it, but here is the original thread on the old email list:

In short, as you said ParaView fails to merge like time steps that don’t have the exact same floating point value. This could be fixed in a filter, but to the best of my knowledge, no one has written one. Fortunately, there is a workaround.

The basic idea is to turn on the Ignore Time feature of one of your inputs. That means that ParaView will only visit the time steps of one of the data files you are reading and ignore the other repeated values. Unfortunately, that almost works, but not quite. The problem is that if the time step in the file you are following has a time step a little before the other, the other reader is likely to load the previous time step rather than the close one. This issue is corrected with the Temporal Shift Scale filter.

So, in summary, here are the steps you can follow that should fix your problem:

  1. Load in both data sets (with times that are supposed to be the same but are just a little bit off).
  2. Add the Temporal Shift Scale filter to one (and only one) of the data sets. Set the Pre Shift to some small positive value that is more than the epsilon difference between the times of the two data sets but less than the amount of time between time steps. Based on your screen shot, 0.00005 should work for you. Apply.
  3. Right click on the Temporal Shift Scale filter in the Pipeline Browser and select the Ignore Time option.

Now when you hit Play, ParaView should visit the time steps of only the data set you didn’t add the Temporal Shift Scale and the other data should be loaded along side it.

Thanks @Kenneth_Moreland! I will give that a try today