Testing: different results on local machine and docker container

43 views
Skip to first unread message

SebG

unread,
Apr 1, 2022, 6:40:52 AM4/1/22
to deal.II User Group
Dear everyone,

I am using GitHub actions and the deal.II docker container to run some tests of my applications. The tests solve small problems and the output to std::cout is compared with the reference output. However, there is a problem with one test, where the L2 norm of a vector becomes approx. 1.0e+03.

The norm computed on my machine (Ubuntu 21.04 and deal.II 9.3.0) and on the docker container dealii:v9.3.0-focal differ by 4.0e-1 such that the test on the docker container fails. I guess that the difference is due to floating-point arithmetic because it becomes smaller when a coarser mesh is used.

Did you have a similar experience regarding the docker container? Do you think that my test setup is simply not suitable if the results are not reproducible on another machine?

Best regards,
Sebastian

Bruno Turcksin

unread,
Apr 1, 2022, 8:55:43 AM4/1/22
to deal.II User Group
Sebastian,

You should get the same result with Docker and on your machine. I have had a few cases where the result was wrong in docker but correct on my machine. This was always related to a variable that was not initialized. For some reason, on my machine the variable would be set to zero but in docker the value was random. It should be easy to find out where the problem is by comparing intermediate results from docker with the results from your machine.

Best,

Bruno

SebG

unread,
Apr 6, 2022, 2:17:56 PM4/6/22
to deal.II User Group
Dear Bruno,

thanks for your advice. It actually helped to find another error related to a rank one deficient linear system due to a missing pressure boundary condition.

However, this did not help to debug my actual issue. I solved the non-linear PDE system on coarser meshes and realized that the results coincide. On refined mesh, the differences/residuals became larger. The large residuals are caused by the initialization of some component of the solution. I modified the Newton iteration by resetting this component of solution after the first iteration. This resolved the problem. So I guess my test case / algorithmen was simply not robust enough. Anyway lesson learned.

Best wishes,
Sebastian
Reply all
Reply to author
Forward
0 new messages