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

ECCO Restoring for OMIP simulations #89

Merged
merged 676 commits into from
Jul 25, 2024
Merged

Conversation

simone-silvestri
Copy link
Collaborator

@simone-silvestri simone-silvestri commented Jun 20, 2024

This PR reworks the whole ECCO2 module, renaming it to ECCO since it adds three different "versions"

  • ECCO2 daily data
  • ECCO2 monthly averages
  • ECCO4 monthly averages

It also introduces an ECCO_field_time_series with its associated ECCONetCDFbackend and an ECCO_restoring_forcing on top of that to restore prognostic variables to ecco data.
The ECCO data is downloaded from the ecco website by providing an ECCO_USERNAME and an ECCO_PASSWORD as environmental variables

TODOs:

  • make sure that tests pass
  • speed up the restoring (now it is very slow for some reason)
  • put username and password in github secret tokens to allow downloading ecco data for testing / documentation purposes

@@ -116,7 +117,7 @@ function regrid_bathymetry(target_grid;
close(dataset)

# Diagnose target grid information
arch = architecture(target_grid)
arch = child_architecture(architecture(target_grid))
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
arch = child_architecture(architecture(target_grid))
arch = child_architecture(target_grid)

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 ll do a PR in Oceananigans to allow this and correct it in a late PR

# The whole range of dates in the different dataset versions
all_ecco_dates(::ECCO4Monthly) = DateTimeProlepticGregorian(1992, 1, 1) : Month(1) : DateTimeProlepticGregorian(2023, 12, 1)
all_ecco_dates(::ECCO2Monthly) = DateTimeProlepticGregorian(1992, 1, 1) : Month(1) : DateTimeProlepticGregorian(2023, 12, 1)
all_ecco_dates(::ECCO2Daily) = DateTimeProlepticGregorian(1992, 1, 4) : Day(1) : DateTimeProlepticGregorian(2023, 12, 31)
Copy link
Member

Choose a reason for hiding this comment

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

for clarify, you probably want to define things like

const ECCO2_final_time = DateTimeProlepticGregorian(2023, 12, 1)

or something. And put them near the definition of the struct ECCO2Monthly for example. Because these things will change in the future presumably.

@simone-silvestri
Copy link
Collaborator Author

@navidcy there is some problems with the docs (the operation is cancelled for some kind of reason). Can you take a look to see what is happening?

@glwagner
Copy link
Member

Maybe change ECCO_USERNAME and ECCO_PASSWORD to CLIMAOCEAN_ECCO_USERNAME and CLIMAOCEAN_ECCO_PASSWORD to clarify that these are used in clima ocean

@simone-silvestri
Copy link
Collaborator Author

Maybe change ECCO_USERNAME and ECCO_PASSWORD to CLIMAOCEAN_ECCO_USERNAME and CLIMAOCEAN_ECCO_PASSWORD to clarify that these are used in clima ocean

At the moment, ECCO_USERNAME and ECCO_PASSWORD are set on the clima cluster as environment variables. So maybe, after this PR we can open another PR that changes these names in the code and in the setup (in the secret tokens and the clima cluster)

@simone-silvestri
Copy link
Collaborator Author

Given that the tests pass I will merge this PR.
Note that the examples are removed from the docs build here as they are tackled in #104

@simone-silvestri simone-silvestri merged commit 514135f into main Jul 25, 2024
9 checks passed
@simone-silvestri simone-silvestri deleted the ss/omip-with-restoring branch July 25, 2024 14:58
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.

None yet

2 participants