Closed lungd closed 5 years ago
@lungd getting a strange sequence of estimated times:
[[ Step 117 (total steps: 60000, t in sim: 0.000585s) dt: 0.000005(in s) time left: 1.08 (in h) ]] [[ Step 118 (total steps: 60000, t in sim: 0.000590s) dt: 0.000005(in s) time left: 52.65 (in min) ]] [[ Step 119 (total steps: 60000, t in sim: 0.000595s) dt: 0.000005(in s) time left: 1.16 (in h) ]] [[ Step 120 (total steps: 60000, t in sim: 0.000600s) dt: 0.000005(in s) time left: 57.14 (in min) ]]
Is it based on timing of just last step or total time to date?
@pgleeson it is a very rough estimation based on timing of the last step (https://github.com/openworm/sibernetic/pull/159/files#diff-33d6ad4c6bbace3e9d070f46ba672d54R362)
Just thought it would be better to record the start time and at time t estimate the time based on: (total lapsed time / steps so far) * steps remaining...
@pgleeson please try out the latest commit
Latest update look good!
Print dt and the calculated remaining time of the simulation after every step, unless it is unlimited
[[ Step 12 (total steps: unlimited, t in sim: 0.00024s) dt: 2e-05]]
[[ Step 11 (total steps: 50000, t in sim: 0.000220s) dt: 0.000020(in s) time left: 1.56 (in h) ]] [[ Step 19 (total steps: 5000, t in sim: 0.000380s) dt: 0.000020(in s) time left: 8.28 (in min) ]] [[ Step 27 (total steps: 50, t in sim: 0.000540s) dt: 0.000020(in s) time left: 0.05 (in min) ]]