Skip to content

Conversation

@stevemullerworth
Copy link
Collaborator

@stevemullerworth stevemullerworth commented Jan 30, 2026

PR Summary

Sci/Tech Reviewer: @alanjhewitt
Code Reviewer: @harry-shepherd

On a new run (NRUN), lfric_atm may read ancillary files some of which contain fixed boundary values. Three of these are dust_mrel, soil_clay and soil_sand, which are used with certain glomap settings. However, continuation runs (CRUNs) do not read such ancillaries. Therefore, the fields need to be written to and read from the checkpoint dump.

Currently, several CRUN tests are therefore running with values for these fields set by initialisation in the code rather than input values. An effect of this is that an NRUN+CRUN will not match the results of an NRUN of the same total length. A failure of a nrun-crun test would show up in the test suite except for the fact that the CRUN in the relevant test is only one timestep long, and differences don't appear in the checksum file till the second timestep.

This fix changes the logic in create_physics_prognostics to additionally read/write these checkpoint fields if glomap_mode is set to dust_and_clim, which affects lfric_atm nwp_gal9 configurations. The change involved some slight reorganisation of the order of the fields to reduce the risk of the checkpoint_flag value being incorrectly overwritten for other fields.

Three of the DA jobs are initialised from checkpoint dumps rather than start dumps. Therefore, the existing checkpoint dumps need to be updated with these fields. Current changes point to an updated file in the developer's data directory. This file would need to be incorporated in BIG_DATA. This new file was generated by using ncks an nco tool to add the three fields to the existing checkpoint dump. I checked with Ian Boutle who was happy with this approach.

Before NRUN/CRUN comparability testing can be improved (to prevent future issues that show up after one timestep) PR #193 also needs to be committed. If #193 is committed, then this issue could extend the length of the nwp_gal9 nrun-crun test to validate this change.

CLA was signed in #193, I expect to merge on main with this change, so won't sign CLA just yet.

Code Quality Checklist

  • I have performed a self-review of my own code
  • My code follows the project's style guidelines
  • Comments have been included that aid understanding and enhance the readability of the code
  • My changes generate no new warnings
  • All automated checks in the CI pipeline have completed successfully

Testing

  • I have tested this change locally, using the LFRic Apps rose-stem suite
  • If any tests fail (rose-stem or CI) the reason is understood and acceptable (e.g. kgo changes)
  • I have added tests to cover new functionality as appropriate (e.g. system tests, unit tests, etc.)
  • Any new tests have been assigned an appropriate amount of compute resource and have been allocated to an appropriate testing group (i.e. the developer tests are for jobs which use a small amount of compute resource and complete in a matter of minutes)

trac.log

Test Suite Results - lfric_apps - checkpoint_dust_forpr2/run3

Suite Information

Item Value
Suite Name checkpoint_dust_forpr2/run3
Suite User steve.mullerworth
Workflow Start 2026-01-30T09:36:39
Groups Run all
Dependency Reference Main Like
casim MetOffice/casim@2025.12.1 True
jules MetOffice/jules@2025.12.1 True
lfric_apps stevemullerworth/lfric_apps@checkpoint_dust False
lfric_core MetOffice/lfric_core@2025.12.1 True
moci MetOffice/moci@2025.12.1 True
SimSys_Scripts MetOffice/SimSys_Scripts@2025.12.1 True
socrates MetOffice/socrates@2025.12.1 True
socrates-spectral MetOffice/socrates-spectral@2025.12.1 True
ukca MetOffice/ukca@2025.12.1 True

Task Information

✅ succeeded tasks - 1454

Security Considerations

  • I have reviewed my changes for potential security issues
  • Sensitive data is properly handled (if applicable)
  • Authentication and authorisation are properly implemented (if applicable)

Performance Impact

  • Performance of the code has been considered and, if applicable, suitable performance measurements have been conducted

AI Assistance and Attribution

  • Some of the content of this change has been produced with the assistance of Generative AI tool name (e.g., Met Office Github Copilot Enterprise, Github Copilot Personal, ChatGPT GPT-4, etc) and I have followed the Simulation Systems AI policy (including attribution labels)

Documentation

  • Where appropriate I have updated documentation related to this change and confirmed that it builds correctly

PSyclone Approval

  • If you have edited any PSyclone-related code (e.g. PSyKAl-lite, Kernel interface, optimisation scripts, LFRic data structure code) then please contact the TCD Team

Sci/Tech Review

  • I understand this area of code and the changes being added
  • The proposed changes correspond to the pull request description
  • Documentation is sufficient (do documentation papers need updating)
  • Sufficient testing has been completed

(Please alert the code reviewer via a tag when you have approved the SR)

Code Review

  • All dependencies have been resolved
  • Related Issues have been properly linked and addressed
  • CLA compliance has been confirmed
  • Code quality standards have been met
  • Tests are adequate and have passed
  • Documentation is complete and accurate
  • Security considerations have been addressed
  • Performance impact is acceptable

@github-actions github-actions bot added the cla-required The CLA has not yet been signed by the author of this PR - added by GA label Jan 30, 2026
@github-actions
Copy link

Hello @stevemullerworth! 👋

Thank you for your contribution. Since this is your first time contributing to this repository, we ask that you sign our Contributor Licence Agreement (CLA).

📄 You can read the CLA here.

To agree to the CLA, please add your details (GitHub username, Real Name, Affiliation, and Date) to the CONTRIBUTORS.md file (create one, if required) in the development branch for this PR. After signing the CLA, you won't need to do this again for future PRs.

@stevemullerworth stevemullerworth added the KGO This PR contains changes to KGO label Jan 30, 2026
@stevemullerworth stevemullerworth marked this pull request as ready for review January 30, 2026 14:18
@github-actions github-actions bot requested a review from alanjhewitt January 30, 2026 14:18
Copy link
Contributor

@alanjhewitt alanjhewitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am happy with the code changes here - they are consistent with the ticket description.

I didnt review the new startdump file, I think Steve may need to get approval from Ian Boutle for this replacement file.

Also, at the time this development is merged tey will need to be put in the official directory.

SciTech approved.

Passing to code review.

@harry-shepherd
Copy link
Contributor

I am happy with the code changes here - they are consistent with the ticket description.

I didnt review the new startdump file, I think Steve may need to get approval from Ian Boutle for this replacement file.

Also, at the time this development is merged tey will need to be put in the official directory.

SciTech approved.

Passing to code review.

@stevemullerworth has got approval from @iboutle regarding this file

@harry-shepherd harry-shepherd added this to the Spring 2026 milestone Feb 3, 2026
@harry-shepherd
Copy link
Contributor

Steve has created a new start dump for this configuration. Following discussion with the SSD team this has been installed in:

$BIG_DATA_DIR/start_dumps/basic-gal/yak/PR202/20210324T0000Z_lfric_ice_dust_t+3.nc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-required The CLA has not yet been signed by the author of this PR - added by GA KGO This PR contains changes to KGO

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants