MD tutorial script fails randomly
The MD tutorial script that is part of the temperature-dependent phonon example (
3a_run_fcp_md.py) is run as part of the weekly tests.
Sometimes it passes (example), sometimes it doesn't (example).
The underlying issue is related to FCP stability (#256 (closed), #412 (closed)) and hence of much broader concern.
For the more narrow purpose of testing, an irregularly failing test is of course not helpful/acceptable.
Steps to reproduce
As discussed below the test fails "randomly". Hence run test and hope that conditions are perfect.
What is the current bug behavior?
 ValueError: Displacement 3.10284 larger than maximum allowed displacement 3.00000  ValueError: Displacement 3.03632 larger than maximum allowed displacement 3.00000  ValueError: Displacement 3.01153 larger than maximum allowed displacement 3.00000
What is the expected correct behavior?
Test passes every time.
I suspect that the random initialization (flashback?) of the MD is the culprit. Simply the test should be run in exactly the same way every time.
It might be enough to set
numpy.random.seed since both from
numpy.random by default.