Skip to content

Make sure the last step is written when using dE_S0S1#184

Merged
danielhollas merged 5 commits intomasterfrom
fix-s1s0-check
Nov 6, 2024
Merged

Make sure the last step is written when using dE_S0S1#184
danielhollas merged 5 commits intomasterfrom
fix-s1s0-check

Conversation

@danielhollas
Copy link
Copy Markdown
Contributor

@danielhollas danielhollas commented Nov 4, 2024

Kudos to Jack Taylor for noticing this bug.

The fix here is a horrible hack --- to make sure that the last step is written to output files when the S1-S0 energy difference drops below the dE_S0S1 threshold, we create a file EXIT instead of stopping directly in the check_S0S1_gap function.
ABIN will then exit at the beginning of the next step in the main loop.

In the end did a less horrible hack via a new global variable STOP_SIMULATION in the mod_general module.

(the first commit here is an unrelated cleanup).

@codecov
Copy link
Copy Markdown

codecov Bot commented Nov 4, 2024

Codecov Report

Attention: Patch coverage is 87.50000% with 1 line in your changes missing coverage. Please review.

Project coverage is 91.90%. Comparing base (7ab1dd6) to head (f10b405).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
src/force_spline.F90 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #184      +/-   ##
==========================================
+ Coverage   91.86%   91.90%   +0.03%     
==========================================
  Files          47       47              
  Lines        6748     6743       -5     
  Branches      758      757       -1     
==========================================
- Hits         6199     6197       -2     
+ Misses        537      534       -3     
  Partials       12       12              
Flag Coverage Δ
unittests 20.42% <0.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/abin.F90 93.84% <100.00%> (+0.71%) ⬆️
src/ekin.F90 100.00% <100.00%> (ø)
src/estimators.F90 95.68% <100.00%> (ø)
src/init.F90 90.50% <ø> (+0.25%) ⬆️
src/modules.F90 100.00% <ø> (ø)
src/surfacehop.F90 95.81% <100.00%> (+0.19%) ⬆️
src/force_spline.F90 0.00% <0.00%> (ø)

@danielhollas danielhollas merged commit 094ba89 into master Nov 6, 2024
@danielhollas danielhollas deleted the fix-s1s0-check branch November 6, 2024 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant