Skip to content

Lift and shift monsoon assessment area#361

Open
pdearnshaw wants to merge 12 commits intomainfrom
343_autoassess_monsoon
Open

Lift and shift monsoon assessment area#361
pdearnshaw wants to merge 12 commits intomainfrom
343_autoassess_monsoon

Conversation

@pdearnshaw
Copy link
Collaborator

@pdearnshaw pdearnshaw commented Feb 9, 2026

This is a draft Pull Request to get a pre-review to make sure the direction of travel is as expected.

Closes #343 .

PR creation checklist for the developer

  • Has <issue_number> above ☝️ been replaced with the issue number?
  • Has main been selected as the base branch?
  • Does the feature branch name follow the format <issue_number>_<short_description_of_feature>?
  • Does the text of the PR title exactly match with the text (not including the issue number) of the issue title?
  • Have appropriate reviewers been added to the PR (once it is ready for review)?
  • Has the PR been assigned to the developer(s)?
  • Have the same labels as on the issue (except for the good first issue label) been added to the PR?
  • Has the Climate Model Evaluation Workflow (CMEW) project been added to the PR?
  • Has the appropriate milestone been added to the PR?

Definition of Done for the developer

  • Does the change in this PR address the above issue / have all acceptance criteria been met?
  • Does the change in this PR follow the requirements in the wiki: Developer Guide (including copyrights)?
  • Have new tests related to the change been added?
  • Do all the GitHub workflow checks pass?
  • Do all the tests run locally and pass? (Note: the tests are not run by the GitHub workflow, see wiki: Run the tests locally)
  • Has the API documentation (e.g. docstrings in Python modules) related to the change been updated appropriately?
  • Has the user documentation (i.e. everything in the doc directory) related to the change been updated appropriately, including the Quick Start section?
  • Do the HTML pages render correctly? (See wiki: Build the documentation locally)

PR creation checklist for the reviewer

  • Has <issue_number> above ☝️ been replaced with the issue number?
  • Has main been selected as the base branch?
  • Does the feature branch name follow the format <issue_number>_<short_description_of_feature>?
  • Does the text of the PR title exactly match with the text (not including the issue number) of the issue title?
  • Have appropriate reviewers been added to the PR (once it is ready for review)?
  • Has the PR been assigned to the developer(s)?
  • Have the same labels as on the issue (except for the good first issue label) been added to the PR?
  • Has the Climate Model Evaluation Workflow (CMEW) project been added to the PR?
  • Has the appropriate milestone been added to the PR?

Definition of Done for the reviewer

  • Does the change in this PR address the above issue / have all acceptance criteria been met?
  • Does the change in this PR follow the requirements in the wiki: Developer Guide (including copyrights)?
  • Have new tests related to the change been added?
  • Do all the GitHub workflow checks pass?
  • Do all the tests run locally and pass? (Note: the tests are not run by the GitHub workflow, see wiki: Run the tests locally)
  • Has the API documentation (e.g. docstrings in Python modules) related to the change been updated appropriately?
  • Has the user documentation (i.e. everything in the doc directory) related to the change been updated appropriately, including the Quick Start section?
  • Do the HTML pages render correctly? (See wiki: Build the documentation locally)

@pdearnshaw pdearnshaw changed the title 343 autoassess monsoon Lift and shift monsoon assessment area Feb 9, 2026
@pdearnshaw pdearnshaw self-assigned this Feb 9, 2026

[scheduling]
[[graph]]
R1 = """
Copy link
Collaborator

Choose a reason for hiding this comment

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

Noddy question: does this overwrite, or append to, the R1 = ... in line 16 of the main flow.cylc file?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It appends to. Use this quite a bit in our model workflows.

Copy link
Member

@ehogan ehogan left a comment

Choose a reason for hiding this comment

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

This looks great @pdearnshaw, thank you! 🥳

I have some minor comments to add when you are ready for them, but my biggest question is whether we want to utilise Rose (i.e. use optional configuration based on the autoassess_area and use a single command in the rose-app.conf file) rather than defining the script within the autoassess.cylc file, for consistency with the rest of CMEW? 🤔 If this feels like a lot of work we can defer this, so we can showcase what works at the demo on Wednesday? 🤔

I have made some suggestions on what I needed to change to get CMEW to run. With these changes, CMEW fails for me as follows:

[FAIL] file:~/cylc-run/CMEW/run55/share/src/AutoAssess=source=git:https://github.com/MetOffice/AutoAssess.git::./::45_update_for_cmew: ls-remote: could not locate 'https://github.com/MetOffice/AutoAssess.git':
[FAIL]     fatal: could not read Username for 'https://github.com/': No such device or address
2026-02-16T09:10:12Z CRITICAL - failed/ERR

I assume this is because the AutoAssess repository is private and I don't have access. We might need to consider how best to solve this (edited to add: we could use a mirror?) / add something to the prerequisites.

--data-dir $DATA_DIR \
--suite-id $CYLC_TASK_PARAM_suite_id
"""
{%- endfor %}
Copy link
Member

Choose a reason for hiding this comment

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

I had to remove this line to get CMEW to run.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This line has been removed.

--ancil-dir $ANCIL_PATH
"""

[[run_area<autoassess_area=australia>]]
Copy link
Member

Choose a reason for hiding this comment

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

I had to remove this section to get CMEW to run.

Copy link
Member

Choose a reason for hiding this comment

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

I would have suggested removing this section anyway, since the issue is for the monsoon assessment area only (but it's great to see that other areas work!) 😊

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The suggestion of using rose apps has resolved this problem. There is only one task defined with parametrisation so whatever logic that prevented this from working with this will have gone away,

--ncpu 1
"""

[[run_area<autoassess_area=mjo>]]
Copy link
Member

Choose a reason for hiding this comment

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

I had to remove this section to get CMEW to run.

Copy link
Member

Choose a reason for hiding this comment

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

I would have suggested removing this section anyway, since the issue is for the monsoon assessment area only (but it's great to see that other areas work!) 😊

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The suggestion of using rose apps has resolved this problem. There is only one task defined with parametrisation so whatever logic that prevented this from working with this will have gone away,

END_DATE = {{ (START_YEAR+NUMBER_OF_YEARS-1)|string + '/12/01' }}

[[install_autoassess]]
inherit = AUTOASSESS, SITE_AA_INSTALL
Copy link
Member

Choose a reason for hiding this comment

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

To remove the error CYLC_TASK_PARAM_autoassess_area: unbound variable:

Suggested change
inherit = AUTOASSESS, SITE_AA_INSTALL
inherit = SITE_AA_INSTALL

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I have re-engineered [[AUTOASSESS]] to not use the parametrised variable so this family can still be used by install_autoassess

@pdearnshaw
Copy link
Collaborator Author

In response to Emma's review I have the following comments, and have tried to reply to specific issues in the code review comments.

The issue over accessing AutoAssess from the GitHub repository has potentially been resolved. The URL used was the HTTPS version due to a misconfigured user authentication key (not authorised for SSO). Once this was resolved the SSH version of the repository URL worked. The Met Office's local mirror bot has also been added to the collaborator list so the AutoAssess repository is also available via local mirror. I have tested both of these and they "work for me"!

I have implemented the AutoAssess scripts as rose apps (all prefixed aa_). As suggested these can make use of optional configurations where appropriate, and this also tidies up the inc/autoassess.cylc file by removing the [[run_area<autoassess_area=some_area>]] sections. By using an "optional" optional configuration (use of brackets to define the optional configuration) we can supply an area assessment's alternative calling command if it exists and leave the default if it doesn't.

I think this PR is ready for another look if and when you are ready Emma?

@pdearnshaw
Copy link
Collaborator Author

pdearnshaw commented Mar 3, 2026

One thing that has cropped up is that the AutoAssess code will not work with the esmvaltool community version of scitools due to the missing mo_pack library. Once this is included in version 2.13 then it should work fine. In the interim, the best choice is to switch to use scitools/default-current.

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.

Lift and shift monsoon assessment area

3 participants