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

Extend perturbIC functionality #11

Open
3 tasks
atteggiani opened this issue Nov 16, 2024 · 0 comments
Open
3 tasks

Extend perturbIC functionality #11

atteggiani opened this issue Nov 16, 2024 · 0 comments

Comments

@atteggiani
Copy link

Currently, the perturbIC function can only accept a restart dump file (UM Dump File) as input, and perturb its theta field (STASH itemcode = 4).
Although this meets the most likely use case, the function could be easily extended to:

  • work with any type of fields file (Ancil files or Output Fieldsfiles too), perturbing by default its theta field. If the field is not present, an error would get raised.
  • accept a STASH itemcode as command line argument, to choose a different field to perturb (for example if user wants to perturb the surface temperature (STASH itemcode = 24) something like --stash-to-perturb 24 could be passed as an argument)
  • if the input fields file contains only one single field, automatically perturb that field (even if is not THETA and the --stash-to-perturb has not been passed.

This additions would cover some edge use cases of perturbIC, extending its functionality without degrading its current performance.

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

No branches or pull requests

1 participant