ParaView Cell Centers possible unstable program behavior

I noticed strange behavior of Cell Centers Filter. It sometimes outputs unpredictable non-reproducible random results. I recorded this on video

. The FE mesh at stages in time has the same topology. See row 4 on spreadsheet view at time index 38. It suddenly and unpredictably gives non-reproducible random coordinates 54.7645 and 3.20815. On subsequent calls it gives 67.5137 and 64.4966. This non-reproducible random changes occur in different cells at different time index. It only affects the coordinates

That is definitely weird. Perhaps this is a race condition in the cell centers filter.

What kind of data is this? Is this a structured grid or an unstructured grid (or something else)?

This is a common 2D finite element mesh exported from Z_Soil geotechnical program. It consists of 100% quad elements

If you click on the Information tab, what does ParaView say the Type of the data is (in the Statistics block)?

Yes, Unstructured Grid

@Andrei, I think I found the problem. I believe you revealed a bug in VTK. I won’t go into details, but I’ve reported the bug here: https://gitlab.kitware.com/paraview/paraview/-/issues/19921

As a workaround, you can add the Clean to Grid filter to your data before you run Cell Centers. When you run Cell Centers on the output of Clean to Grid, you no longer get the errors you are seeing.

1 Like

Many thanks! The Clean to Grid filter with default settings solves the problem