Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Managing om3-peripheral tools #262

Open
dougiesquire opened this issue Feb 3, 2025 · 9 comments
Open

Managing om3-peripheral tools #262

dougiesquire opened this issue Feb 3, 2025 · 9 comments

Comments

@dougiesquire
Copy link
Collaborator

dougiesquire commented Feb 3, 2025

We have an ever-growing set of tools that support setting-up/configuring/running ACCESS-OM3. As some tools are now starting to depend on others, we possibly need to revisit how they, and their inter-dependencies, are managed and maintained.

This issues is to compile a list of OM3-peripheral tools and discuss.

Tools

(please add)

@anton-seaice
Copy link
Contributor

We won't need esmgrids for OM3 post using mom supergrid in cice ACCESS-NRI/CICE#8

I think its worth splitting the list into python tools used routinely when running payu (om3-scripts, make_diag_table, expt_manager) vs stuff used on a more sporadic basis for developing new configurations (e.g. initial conditions and grids).

@anton-seaice
Copy link
Contributor

https://github.com/COSIMA/regional-mom6 is tangentially related / maybe needs considering in this list

@dougiesquire
Copy link
Collaborator Author

https://github.com/COSIMA/regional-mom6 is tangentially related / maybe needs considering in this list

It's already packaged and available via PyPI and conda-forge. It's the random, interdependent (mostly Python) scripts and modules that keep me awake at night.

@minghangli-uni
Copy link
Contributor

minghangli-uni commented Feb 14, 2025

COSIMA/om3-scripts#39 this might overlap with the profiling features in https://github.com/COSIMA/om3-utils, but it provides a simpler and significantly faster approach to handling profiling files. Probably can be added to the above list?

@dougiesquire
Copy link
Collaborator Author

dougiesquire commented Feb 14, 2025

An initial proposal to start discussions is that we split om3-scripts and om3-utils into three Python packages, all in the ACCESS-NRI Github org. Note here I'm just using placeholders for the names of the packages and modules:

Package 1: tools used for creating and manipulating OM inputs
Includes bits of om3-scripts, om3-utils and other scripts around the place

access-om-tools/
├── scripts
│   └── <"dumping ground" for scripts: includes most scripts from om3-scripts, make_diag_table>
├── utils (includes input file parsers from om3-utils plus stuff from om3-scripts/scripts_common)
└── ...

Package 2: tools used for profiling ACCESS models
Includes profiling modules from om3-utils

access-profiling/
├── esmf
│   └── ...
├── fms
│   └── ...
├── utils
└── ...

Package 3(/4): tool(s) for running suits of experiments with Payu
This one is still pretty uncertain as the tool is still being developed/refactored
However, the initial implementation should be moved out of om3-scripts and into it's own package(s)

All these packages should be made available via PyPI/conda and have the usual tests, docs, CI etc

@micaeljtoliveira
Copy link
Contributor

@dougiesquire Thanks for kick-starting the discussion and for the initial proposal.

Regarding package 1, note that the software transformation team needs to have parsers to all relevant files for all models, not only OM3, as we will be profiling and performing scaling tests for all models. As such, I would prefer to split it further and put all the parsing of any relevant configuration files used in the ACCESS models in its own package. That would maximize re-usability, remove duplicated code, and follow a "separation of concerns" approach.

As for package 3, I would again separate things further. A lot of what these tools do follow similar patterns and they could be written in terms of generic workflows. For example, many workflows that we have look like this: given a list of values, modify a parameter in the configuration files, run the model with payu and finally do something with the output. Such generic workflows could then be used as building blocks for both the experiment manager and the scalability/profiling tools.

All these packages should be made available via PyPI/conda and have the usual tests, docs, CI etc

Yes, absolutely.

@micaeljtoliveira
Copy link
Contributor

COSIMA/om3-scripts#39 this might overlap with the profiling features in https://github.com/COSIMA/om3-utils, but it provides a simpler and significantly faster approach to handling profiling files.

The ESMF text-based profiling output is just another type of profiling data and can easily be added to the other existing profiling data parsers that are in om3-utils (or whatever new package those things will be moved to).

@aekiss
Copy link
Contributor

aekiss commented Feb 14, 2025

run_summary and nmltab also include parsers, but they are more end-user-centric so I don't seen an advantage to bundling them up together with everything else that happens to have a parser.

I suppose it could work if their parsing code could be factored out into a general parser package that then becomes a dependency of run_summary and nmltab. But that seems a bit like make-work unless there's a real prospect of code reuse.

@dougiesquire
Copy link
Collaborator Author

We had a meeting about this. My summary as follows, but obviously please feel free to edit/comment if I've got anything wrong.

There is agreement that many small packages with well-defined scope is far better than fewer larger packages. Package scope should take into account functionality, but also who the users are likely to be. We spitballed at least 6 packages/repos:

Scope Users
Package 1 Tools for reading/writing model configuration inputs (referred to as "parsers" in the meeting) ACCESS model devs, software transformation team, Payu, experiment manager tool...
Package 2 Dumping ground for general OM scripts for generating input files ACCESS-OM devs
Package 3 Tools for profiling ACCESS models ACCESS model devs, software transformation team
make_diag_table Tool for writing MOM diag_table from a yaml source ACCESS model devs, research community
Experiment manager: generator Tool to generate suites of Payu configurations (there may be multiple such tools) ACCESS model devs, research community
Experiment manager: runner Tool to run suites of Payu configurations ACCESS model devs, research community

First cab off the rank is "Package 1" since that will contain code used by a number of other packages. In the first instance, Package 1 will just include the existing parsers (for lack of a better term) in om3-utils. Does anyone have a good suggestion for a name for this package? How does access-input-parsers sit with people (yeah, I don't like it either)?

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

No branches or pull requests

5 participants