UMfile_util is a Python library that provides specific tools to process UM files.
umfile_utils
is released as a conda
package within the accessnri
Anaconda.org channel.
To install it, run:
conda install accessnri::umfile_utils
Apply a random perturbation to a restart file, with an optional seed to control the random generation. This can be useful for simulations that fail due to random divergence or for generating multiple ensemble members in climate experiments.
Run pertubIC --help
for detailed usage information.
Subset a UM file to generate an output containing only selected fields. Options are available to include or exclude specific STASH variables.
Run um_fields_subset --help
for detailed usage information.
Change the time metadata of a UM restart file, without modifying its data content.
Run change_date --help
for detailed usage information
External contributions (not from ACCESS-NRI) are accepted in the form of issues and PRs from forked repos.
For development/testing, it is recommended to install umfile_utils
as a development package within a micromamba
/conda
testing environment.
Note
If you are not part of the ACCESS-NRI, you can fork the repo instead.
git clone [email protected]:ACCESS-NRI/umfile_utils.git
Tip
In the following instructions micromamba
can be replaced with conda
.
cd umfile_utils
micromamba env create -n umfile_utils_dev --file .conda/env_dev.yml
micromamba activate umfile_utils_dev
pip install --no-deps --no-build-isolation -e .
To manually run the tests, from the umfile_utils
directory, you can:
- Activate your micromamba/conda testing environment
- Run the following command:
pytest