From a1487af4f832b15a5131c1de51a6a7e2e692fccb Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 17:10:36 -0400 Subject: [PATCH 01/26] Update README.md --- README.md | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index d132b62bb..9513e95ff 100644 --- a/README.md +++ b/README.md @@ -44,20 +44,18 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia ## Why? What's the difference between ClimaOcean and [Oceananigans](https://github.com/CliMA/Oceananigans.jl)? -`ClimaOcean` is for _realistic_ ocean-only and ocean + sea-ice simulations, in a region of the ocean ("regional") or covering the whole Earth. -[Oceananigans](https://github.com/CliMA/Oceananigans.jl) is a lower-level package for simulating the dynamics of ocean-flavored fluids that can be used for _both_ idealized problems and, given enough effort, realistic problems as well. -While "idealized" problems come in multifarious shapes and sizes, "realistic" problems tend to be more narrowly defined, and require +[`Oceananigans`](https://github.com/CliMA/Oceananigans.jl) is a general-purpose package for ocean-flavored fluid dynamics. +`ClimaOcean` _specializes_ `Oceananigans` for a specific application: realistic ocean simulations, and coupled ocean + sea ice simulations. -* Simulating the evolution of specific tracers: ocean temperature (or heat), salinity, and sometimes ocean biogeochemistry. -* Computing fluxes of heat, water vapor, momentum, and trace gases between the ocean and atmosphere (where the atmospheric state is either prescribed or "coupled" and itself evolving) -- and also between sea ice and the atmosphere, when a sea ice component is included. -* Initializing the ocean model with realistic initial conditions derived from observations of the ocean, and realistic bathymetry. - -`ClimaOcean` leverages `Oceananigans` and `ClimaSeaIce` to build `OceanSeaIceModel`s capable of meeting these requirements to simulate the dynamics of specific regions of the Earth's ocean. -So if you're using `ClimaOcean`, it's a very good idea to become proficient in [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl) as well. -Note also that, at least at the moment, `ClimaOcean` is focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. +Realistic ocean simulations require -In summary, if you're interested in realistic, hydrostatic regional or global simulations you may find `ClimaOcean` useful. -Otherwise, you can stick with [Oceananigans](https://github.com/CliMA/Oceananigans.jl). +* Simulating the evolution of ocean temperature and salinity. +* Computing fluxes of heat, water vapor, momentum, and trace gases between the ocean and atmosphere, where the atmospheric state is either prescribed, or evolving in an atmosphere-ocean coupled configuration. +* Defining domain geometry using bathymetry observations. +* Initializing the ocean model with realistic temperature, salinity, and velocity fields. + +`ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). +Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. From a6e31600b4c46aa2de7a812f052d48dde6f664fd Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 17:30:04 -0400 Subject: [PATCH 02/26] Update README.md --- README.md | 37 +++++++++++++++++++++++++++++++------ 1 file changed, 31 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 9513e95ff..f8e3815c2 100644 --- a/README.md +++ b/README.md @@ -44,15 +44,40 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia ## Why? What's the difference between ClimaOcean and [Oceananigans](https://github.com/CliMA/Oceananigans.jl)? -[`Oceananigans`](https://github.com/CliMA/Oceananigans.jl) is a general-purpose package for ocean-flavored fluid dynamics. +`Oceananigans` is a general-purpose package for ocean-flavored fluid dynamics. `ClimaOcean` _specializes_ `Oceananigans` for a specific application: realistic ocean simulations, and coupled ocean + sea ice simulations. -Realistic ocean simulations require +To do this, `ClimaOcean` implements two core abstractions: +* `ocean_simulation`, and +* `OceanSeaIceModel`. -* Simulating the evolution of ocean temperature and salinity. -* Computing fluxes of heat, water vapor, momentum, and trace gases between the ocean and atmosphere, where the atmospheric state is either prescribed, or evolving in an atmosphere-ocean coupled configuration. -* Defining domain geometry using bathymetry observations. -* Initializing the ocean model with realistic temperature, salinity, and velocity fields. +To illustrate how `ClimaOcean` extends `Oceananigans`, consider this simple one-layer near-global model with 1/4 degree resolution, + +```julia +using ClimaOcean +using Oceananigans +using Oceananigans.Units + +grid = LatitudeLongitudeGrid(size=(1440, 560, 1), longitude=(0, 360), latitude=(-70, 70), z=(-3000, 0)) +bathymetry = regrid_bathymetry(grid) +grid = ImmersedBoundaryGrid(grid, PartialCellBottom(bathymetry)) + +ocean = ocean_simulation(; grid) # build ocean component with default advection schemes and turbulence closures +date = DateTimeProlepticGregorian(1993, 1, 1) +set!(ocean.model, T=ECCOMetadata(:temperature; date), S=ECCOMetadata(:salinity; date)) + +atmosphere = JRA55PrescribedAtmosphere() # a prescribed atmosphere based on JRA55 reanalysis +coupled_model = OceanSeaIceModel(ocean; atmosphere) +simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) +run!(simulation) +``` + +`ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. + +`OceanSeaIceModel` provides a framework for coupled modeling that encapsulates the ocean simulation, a prescribed atmosphere, and optionally, a sea ice simulation. +`OceanSeaIceModel` is tasked with the computation of air-sea, air-ice, and ice-ocean fluxes. + +In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, and velocity fields, and prescribed atmospheric states. `ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. From 4e75c0c2ccde661307dca120692857ad93aa821e Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 17:33:53 -0400 Subject: [PATCH 03/26] Update README.md --- README.md | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index f8e3815c2..9d46ac960 100644 --- a/README.md +++ b/README.md @@ -54,20 +54,27 @@ To do this, `ClimaOcean` implements two core abstractions: To illustrate how `ClimaOcean` extends `Oceananigans`, consider this simple one-layer near-global model with 1/4 degree resolution, ```julia -using ClimaOcean using Oceananigans using Oceananigans.Units - -grid = LatitudeLongitudeGrid(size=(1440, 560, 1), longitude=(0, 360), latitude=(-70, 70), z=(-3000, 0)) -bathymetry = regrid_bathymetry(grid) +using DateTime, CFTime +import ClimaOcean + +arch = GPU() +grid = LatitudeLongitudeGrid(arch, + size = (1440, 560, 1), + longitude = (0, 360), + latitude = (-70, 70), + z = (-3000, 0)) +bathymetry = ClimaOcean.regrid_bathymetry(grid) grid = ImmersedBoundaryGrid(grid, PartialCellBottom(bathymetry)) -ocean = ocean_simulation(; grid) # build ocean component with default advection schemes and turbulence closures +ocean = ClimaOcean.ocean_simulation(; grid) # build the default ocean component date = DateTimeProlepticGregorian(1993, 1, 1) -set!(ocean.model, T=ECCOMetadata(:temperature; date), S=ECCOMetadata(:salinity; date)) +set!(ocean.model, T = ClimaOcean.ECCOMetadata(:temperature; date), + S = ClimaOcean.ECCOMetadata(:salinity; date)) -atmosphere = JRA55PrescribedAtmosphere() # a prescribed atmosphere based on JRA55 reanalysis -coupled_model = OceanSeaIceModel(ocean; atmosphere) +atmosphere = ClimaOcean.JRA55PrescribedAtmosphere(arch) # a prescribed atmosphere based on JRA55 reanalysis +coupled_model = ClimaOcean.OceanSeaIceModel(ocean; atmosphere) simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) run!(simulation) ``` From 6e0a348c30546d2f17159beb265dbb6a4f01ff7f Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 17:45:23 -0400 Subject: [PATCH 04/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9d46ac960..7bbdcb7e0 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ To illustrate how `ClimaOcean` extends `Oceananigans`, consider this simple one- ```julia using Oceananigans using Oceananigans.Units -using DateTime, CFTime +using Dates, CFTime import ClimaOcean arch = GPU() From cb7e264bf98e35aad8d378998ae063d2cb8670ea Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 17:52:44 -0400 Subject: [PATCH 05/26] Update README.md --- README.md | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 7bbdcb7e0..222f150a4 100644 --- a/README.md +++ b/README.md @@ -61,19 +61,23 @@ import ClimaOcean arch = GPU() grid = LatitudeLongitudeGrid(arch, - size = (1440, 560, 1), + size = (1440, 560, 10), + halo = (7, 7, 7), longitude = (0, 360), latitude = (-70, 70), z = (-3000, 0)) -bathymetry = ClimaOcean.regrid_bathymetry(grid) -grid = ImmersedBoundaryGrid(grid, PartialCellBottom(bathymetry)) -ocean = ClimaOcean.ocean_simulation(; grid) # build the default ocean component +bathymetry = ClimaOcean.regrid_bathymetry(grid) # builds gridded bathymetry based on ETOPO1 +grid = ImmersedBoundaryGrid(grid, GridFittedBottom(bathymetry)) + +# Build an ocean simulation initialized to the ECCO state estimate on Jan 1, 1993 +ocean = ClimaOcean.ocean_simulation(grid) date = DateTimeProlepticGregorian(1993, 1, 1) set!(ocean.model, T = ClimaOcean.ECCOMetadata(:temperature; date), S = ClimaOcean.ECCOMetadata(:salinity; date)) -atmosphere = ClimaOcean.JRA55PrescribedAtmosphere(arch) # a prescribed atmosphere based on JRA55 reanalysis +# Build and run an OceanSeaIceModel (with no sea ice compoent this time) forced by JRA55 reanalysis +atmosphere = ClimaOcean.JRA55_prescribed_atmosphere(arch) coupled_model = ClimaOcean.OceanSeaIceModel(ocean; atmosphere) simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) run!(simulation) From de30b6f694555b3806d58147182a6ac1846b6ae0 Mon Sep 17 00:00:00 2001 From: glwagner Date: Fri, 4 Oct 2024 18:22:46 -0400 Subject: [PATCH 06/26] Use MinimumTemperatureSeaIce as default --- src/OceanSeaIceModels/ocean_sea_ice_model.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/OceanSeaIceModels/ocean_sea_ice_model.jl b/src/OceanSeaIceModels/ocean_sea_ice_model.jl index b3d7a8006..5e1257742 100644 --- a/src/OceanSeaIceModels/ocean_sea_ice_model.jl +++ b/src/OceanSeaIceModels/ocean_sea_ice_model.jl @@ -69,7 +69,7 @@ function heat_capacity(eos::TEOS10EquationOfState{FT}) where FT return convert(FT, cₚ⁰) end -function OceanSeaIceModel(ocean, sea_ice=nothing; +function OceanSeaIceModel(ocean, sea_ice=MinimumTemperatureSeaIce(); atmosphere = nothing, radiation = nothing, similarity_theory = nothing, From 86a572b47257054df50a1e2768edf82c996e215c Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 18:25:46 -0400 Subject: [PATCH 07/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 222f150a4..407338ee9 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ To do this, `ClimaOcean` implements two core abstractions: * `ocean_simulation`, and * `OceanSeaIceModel`. -To illustrate how `ClimaOcean` extends `Oceananigans`, consider this simple one-layer near-global model with 1/4 degree resolution, +To illustrate how `ClimaOcean` extends `Oceananigans`, we set up a 10-layer near-global model at 1/4 degree resolution, ```julia using Oceananigans From 3f41ccbb72b4f9b19d4801cc03daf98efa50d839 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 18:27:49 -0400 Subject: [PATCH 08/26] Update README.md --- README.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 407338ee9..b724290bf 100644 --- a/README.md +++ b/README.md @@ -83,10 +83,12 @@ simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) run!(simulation) ``` -`ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. +This simulation simulates approximately 8 years per day of wall time on an Nvidia H100. -`OceanSeaIceModel` provides a framework for coupled modeling that encapsulates the ocean simulation, a prescribed atmosphere, and optionally, a sea ice simulation. -`OceanSeaIceModel` is tasked with the computation of air-sea, air-ice, and ice-ocean fluxes. +`ClimaOcean.ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. + +`ClimaOcean.OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. +`OceanSeaIceModel` computes air-sea, air-ice, and ice-ocean fluxes of momentum, heat, and freshwater. In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, and velocity fields, and prescribed atmospheric states. From 8ef0613ff4504b23676dd977d17ba2c905f36f3b Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 18:40:09 -0400 Subject: [PATCH 09/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b724290bf..952bcf63e 100644 --- a/README.md +++ b/README.md @@ -76,7 +76,7 @@ date = DateTimeProlepticGregorian(1993, 1, 1) set!(ocean.model, T = ClimaOcean.ECCOMetadata(:temperature; date), S = ClimaOcean.ECCOMetadata(:salinity; date)) -# Build and run an OceanSeaIceModel (with no sea ice compoent this time) forced by JRA55 reanalysis +# Build and run an OceanSeaIceModel (with no sea ice component) forced by JRA55 reanalysis atmosphere = ClimaOcean.JRA55_prescribed_atmosphere(arch) coupled_model = ClimaOcean.OceanSeaIceModel(ocean; atmosphere) simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) From 3aba336955297d511ab3091d3d9f4d05244030a6 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Fri, 4 Oct 2024 19:02:12 -0400 Subject: [PATCH 10/26] Update README.md --- README.md | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 952bcf63e..3b7071ba2 100644 --- a/README.md +++ b/README.md @@ -47,10 +47,6 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia `Oceananigans` is a general-purpose package for ocean-flavored fluid dynamics. `ClimaOcean` _specializes_ `Oceananigans` for a specific application: realistic ocean simulations, and coupled ocean + sea ice simulations. -To do this, `ClimaOcean` implements two core abstractions: -* `ocean_simulation`, and -* `OceanSeaIceModel`. - To illustrate how `ClimaOcean` extends `Oceananigans`, we set up a 10-layer near-global model at 1/4 degree resolution, ```julia @@ -83,11 +79,11 @@ simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) run!(simulation) ``` -This simulation simulates approximately 8 years per day of wall time on an Nvidia H100. +ClimaOcean's core abstractions are `ocean_simulation` and `ClimaOcean.OceanSeaIceModel`: -`ClimaOcean.ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. +* `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. -`ClimaOcean.OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. +* `OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. `OceanSeaIceModel` computes air-sea, air-ice, and ice-ocean fluxes of momentum, heat, and freshwater. In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, and velocity fields, and prescribed atmospheric states. @@ -95,5 +91,19 @@ In addition to these core abstractions `ClimaOcean` provides convenience feature `ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. - +This simulation achieves approximately 8 years per day of wall time on an Nvidia H100. +Since, for example, `ocean.model` is an Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. +For example, to plot the surface speed at the end of the simulation we write + +```julia +u, v, w = ocean.model.velocities +speed = Field(sqrt(u^2 + v^2)) +compute!(speed) + +using GLMakie +heatmap(view(speed, :, :, ocean.model.grid.Nz), colorrange=(0, 1), nan_color=:gray) +``` + +which produces +image From cfadc07dfc21e918ffac04542bc9e7c352e80640 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:41:29 -0700 Subject: [PATCH 11/26] Update README.md Co-authored-by: Navid C. Constantinou --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 3b7071ba2..404c6f623 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia `Oceananigans` is a general-purpose package for ocean-flavored fluid dynamics. `ClimaOcean` _specializes_ `Oceananigans` for a specific application: realistic ocean simulations, and coupled ocean + sea ice simulations. -To illustrate how `ClimaOcean` extends `Oceananigans`, we set up a 10-layer near-global model at 1/4 degree resolution, +To illustrate how `ClimaOcean` extends `Oceananigans`, we set up a model with 10 vertical levels and a horizontal grid at a 1/4-degree resolution, ```julia using Oceananigans From 66f59a0ee4029d0b4809f4b6d52d478a882e0e8f Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:41:40 -0700 Subject: [PATCH 12/26] Update README.md Co-authored-by: Navid C. Constantinou --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 404c6f623..8745596af 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ run!(simulation) ClimaOcean's core abstractions are `ocean_simulation` and `ClimaOcean.OceanSeaIceModel`: -* `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. +* `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](http://doi.org/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. * `OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. `OceanSeaIceModel` computes air-sea, air-ice, and ice-ocean fluxes of momentum, heat, and freshwater. From 9acf3511cda3f880429cde14d0449aef3e870f31 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:41:48 -0700 Subject: [PATCH 13/26] Update README.md Co-authored-by: Navid C. Constantinou --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8745596af..df15daa7b 100644 --- a/README.md +++ b/README.md @@ -86,7 +86,7 @@ ClimaOcean's core abstractions are `ocean_simulation` and `ClimaOcean.OceanSeaIc * `OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. `OceanSeaIceModel` computes air-sea, air-ice, and ice-ocean fluxes of momentum, heat, and freshwater. -In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, and velocity fields, and prescribed atmospheric states. +In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, ocean velocity fields, and prescribed atmospheric states. `ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. From 43ad0f6645ce1e6aa9bc5cf5253483c32fba4d41 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:41:56 -0700 Subject: [PATCH 14/26] Update README.md Co-authored-by: Navid C. Constantinou --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index df15daa7b..4f6e5ad3b 100644 --- a/README.md +++ b/README.md @@ -91,7 +91,7 @@ In addition to these core abstractions `ClimaOcean` provides convenience feature `ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. -This simulation achieves approximately 8 years per day of wall time on an Nvidia H100. +The simulation above achieves approximately 8 simulated years per day of wall time on an Nvidia H100 GPU. Since, for example, `ocean.model` is an Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. For example, to plot the surface speed at the end of the simulation we write From 3e5c0361d16548337fb5ba450694c2f763f7995f Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:42:11 -0700 Subject: [PATCH 15/26] Update README.md Co-authored-by: Navid C. Constantinou --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4f6e5ad3b..9e49031da 100644 --- a/README.md +++ b/README.md @@ -92,7 +92,7 @@ In addition to these core abstractions `ClimaOcean` provides convenience feature Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. The simulation above achieves approximately 8 simulated years per day of wall time on an Nvidia H100 GPU. -Since, for example, `ocean.model` is an Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. +Since, for example, `ocean.model` is an `Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. For example, to plot the surface speed at the end of the simulation we write ```julia From 65f082a3f89997c576b2d616c867f6f26832a6f6 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:43:01 -0700 Subject: [PATCH 16/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9e49031da..ca108bbec 100644 --- a/README.md +++ b/README.md @@ -92,7 +92,7 @@ In addition to these core abstractions `ClimaOcean` provides convenience feature Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. The simulation above achieves approximately 8 simulated years per day of wall time on an Nvidia H100 GPU. -Since, for example, `ocean.model` is an `Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. +Since `ocean.model` is an `Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. For example, to plot the surface speed at the end of the simulation we write ```julia From 98728211e58dc65b28ce3fe7a2aa2e3cc0ec8b67 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:54:13 -0700 Subject: [PATCH 17/26] Update README.md --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ca108bbec..0ee5b286e 100644 --- a/README.md +++ b/README.md @@ -44,10 +44,11 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia ## Why? What's the difference between ClimaOcean and [Oceananigans](https://github.com/CliMA/Oceananigans.jl)? -`Oceananigans` is a general-purpose package for ocean-flavored fluid dynamics. -`ClimaOcean` _specializes_ `Oceananigans` for a specific application: realistic ocean simulations, and coupled ocean + sea ice simulations. +`Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. +`ClimaOcean` implements a framework for driving realistic Oceananigans simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. -To illustrate how `ClimaOcean` extends `Oceananigans`, we set up a model with 10 vertical levels and a horizontal grid at a 1/4-degree resolution, +In particular, `ClimaOcean` provides `OceanSeaIceModel` that encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. +To illustrate how `OceanSeaIceModel` works, we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: ```julia using Oceananigans From a249e0daa3866ce4a80fee7b63ee27a024592142 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 06:54:33 -0700 Subject: [PATCH 18/26] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0ee5b286e..88bbea88e 100644 --- a/README.md +++ b/README.md @@ -45,9 +45,9 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia ## Why? What's the difference between ClimaOcean and [Oceananigans](https://github.com/CliMA/Oceananigans.jl)? `Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. -`ClimaOcean` implements a framework for driving realistic Oceananigans simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. +`ClimaOcean` implements a framework for driving realistic `Oceananigans` simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. -In particular, `ClimaOcean` provides `OceanSeaIceModel` that encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. +`ClimaOcean` provides `OceanSeaIceModel` that encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. To illustrate how `OceanSeaIceModel` works, we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: ```julia From 9ca9e4e28f3048931754fcae11ab376e8d2d4566 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 07:00:42 -0700 Subject: [PATCH 19/26] Update README.md --- README.md | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index 88bbea88e..e9a6ef643 100644 --- a/README.md +++ b/README.md @@ -47,8 +47,10 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia `Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. `ClimaOcean` implements a framework for driving realistic `Oceananigans` simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. -`ClimaOcean` provides `OceanSeaIceModel` that encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. -To illustrate how `OceanSeaIceModel` works, we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: +### `ClimaOcean's ocean and sea ice coupled model: `OceanSeaIceModel` + +Our system for realistic modeling is anchored by `ClimaOcean.OceanSeaIceModel`, which encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. +To illustrate how `OceanSeaIceModel` works we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: ```julia using Oceananigans @@ -80,20 +82,9 @@ simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) run!(simulation) ``` -ClimaOcean's core abstractions are `ocean_simulation` and `ClimaOcean.OceanSeaIceModel`: - -* `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](http://doi.org/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. - -* `OceanSeaIceModel` provides a framework for coupled modeling with an ocean component, prescribed atmosphere, and optionally, a sea ice component. -`OceanSeaIceModel` computes air-sea, air-ice, and ice-ocean fluxes of momentum, heat, and freshwater. - -In addition to these core abstractions `ClimaOcean` provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, ocean velocity fields, and prescribed atmospheric states. - -`ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). -Note that `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`. - The simulation above achieves approximately 8 simulated years per day of wall time on an Nvidia H100 GPU. -Since `ocean.model` is an `Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage all of Oceananigans features in our scripts. + +Since `ocean.model` is an `Oceananigans.HydrostaticFreeSurfaceModel`, we can leverage `Oceananigans` features in our scripts. For example, to plot the surface speed at the end of the simulation we write ```julia @@ -108,3 +99,12 @@ heatmap(view(speed, :, :, ocean.model.grid.Nz), colorrange=(0, 1), nan_color=:gr which produces image + +### Additional features: a utility for `ocean_simulation`s and data wrangling + +A second core abstraction in ClimaOcean is `ocean_simulation`. `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](http://doi.org/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. + +`ClimaOcean` also provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, ocean velocity fields, and prescribed atmospheric states. + +`ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). +Note that though `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`, realistic nonhydrostatic modeling is also within the scope of this package. From 6ab0a51f94bfb11b27bfb0e9367f18a25a0d96e2 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 07:01:06 -0700 Subject: [PATCH 20/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e9a6ef643..21af51811 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@

- 🌎 Tools for building realistic ocean-only and coupled ocean + sea-ice simulations based on + 🌎 A framework for realistic ocean-only and coupled ocean + sea-ice simulations driven by prescribed atmospheres and based on Oceananigans and ClimaSeaIce.

From e1a7915e8b8ac46c10fff3d340cbb94d937c86c1 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 07:01:44 -0700 Subject: [PATCH 21/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 21af51811..8672ab16d 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia `Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. `ClimaOcean` implements a framework for driving realistic `Oceananigans` simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. -### `ClimaOcean's ocean and sea ice coupled model: `OceanSeaIceModel` +### `ClimaOcean.OceanSeaIceModel` Our system for realistic modeling is anchored by `ClimaOcean.OceanSeaIceModel`, which encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. To illustrate how `OceanSeaIceModel` works we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: From 0777656a1324431cd44270a2153c9d6632e4a84f Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Tue, 8 Oct 2024 07:02:00 -0700 Subject: [PATCH 22/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8672ab16d..f878c7c08 100644 --- a/README.md +++ b/README.md @@ -47,7 +47,7 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia `Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. `ClimaOcean` implements a framework for driving realistic `Oceananigans` simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. -### `ClimaOcean.OceanSeaIceModel` +### A core abstraction: `ClimaOcean.OceanSeaIceModel` Our system for realistic modeling is anchored by `ClimaOcean.OceanSeaIceModel`, which encapsulates the ocean simulation, sea ice simulation, prescribed atmospheric state, and specifies how the three communicate. To illustrate how `OceanSeaIceModel` works we set up a simulation on a grid with 10 vertical levels and 1/4-degree horizontal resolution: From bfe72b87dd4d77bd99ff3b7df62a537217b8fc4b Mon Sep 17 00:00:00 2001 From: "Navid C. Constantinou" Date: Fri, 11 Oct 2024 06:08:23 +1100 Subject: [PATCH 23/26] ClimaOcean is registered --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f878c7c08..b1779aa97 100644 --- a/README.md +++ b/README.md @@ -29,12 +29,12 @@ ## Installation -To install from a Julia REPL: +`ClimaOcean` is a registered package. To install from a Julia REPL: ```julia julia> using Pkg -julia> Pkg.add(url="https://github.com/CliMA/ClimaOcean.jl.git") +julia> Pkg.add("ClimaOcean") julia> Pkg.instantiate() ``` From 4f7db812f3e68c28a9f6d550f4669630fabe82ab Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Wed, 23 Oct 2024 12:23:30 -0600 Subject: [PATCH 24/26] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b1779aa97..9944a5bb6 100644 --- a/README.md +++ b/README.md @@ -78,7 +78,7 @@ set!(ocean.model, T = ClimaOcean.ECCOMetadata(:temperature; date), # Build and run an OceanSeaIceModel (with no sea ice component) forced by JRA55 reanalysis atmosphere = ClimaOcean.JRA55_prescribed_atmosphere(arch) coupled_model = ClimaOcean.OceanSeaIceModel(ocean; atmosphere) -simulation = Simulation(coupled_model, Δt=10minutes, stop_time=30days) +simulation = Simulation(coupled_model, Δt=5minutes, stop_time=30days) run!(simulation) ``` From ccb61d6da18a1b4cafd5b30f9f26c003e2808d80 Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Wed, 23 Oct 2024 13:38:42 -0600 Subject: [PATCH 25/26] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9944a5bb6..257048340 100644 --- a/README.md +++ b/README.md @@ -93,12 +93,12 @@ speed = Field(sqrt(u^2 + v^2)) compute!(speed) using GLMakie -heatmap(view(speed, :, :, ocean.model.grid.Nz), colorrange=(0, 1), nan_color=:gray) +heatmap(view(speed, :, :, ocean.model.grid.Nz), colorrange=(0, 0.5), colormap=:magma, nan_color=:lightgray) ``` which produces -image +image ### Additional features: a utility for `ocean_simulation`s and data wrangling From 2cb2f5cc7037a6832962b7c6ac87a7b9b16d4e1f Mon Sep 17 00:00:00 2001 From: "Gregory L. Wagner" Date: Wed, 23 Oct 2024 13:41:30 -0600 Subject: [PATCH 26/26] Update README.md --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 257048340..37f9eaab3 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ ## Installation -`ClimaOcean` is a registered package. To install from a Julia REPL: +ClimaOcean is a registered package. To install from a Julia REPL: ```julia julia> using Pkg @@ -44,8 +44,8 @@ For more information, see the [documentation for `Pkg.jl`](https://pkgdocs.julia ## Why? What's the difference between ClimaOcean and [Oceananigans](https://github.com/CliMA/Oceananigans.jl)? -`Oceananigans` is a general-purpose library for ocean-flavored fluid dynamics. -`ClimaOcean` implements a framework for driving realistic `Oceananigans` simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. +Oceananigans is a general-purpose library for ocean-flavored fluid dynamics. +ClimaOcean implements a framework for driving realistic Oceananigans simulations with prescribed atmospheres, and coupling them to prognostic sea ice simulations. ### A core abstraction: `ClimaOcean.OceanSeaIceModel` @@ -104,7 +104,7 @@ which produces A second core abstraction in ClimaOcean is `ocean_simulation`. `ocean_simulation` configures an Oceananigans model for realistic simulations including temperature and salinity, the TEOS-10 equation of state, boundary conditions to store computed air-sea fluxes, the automatically-calibrated turbulence closure `CATKEVerticalDiffusivity`, and the [`WENOVectorInvariant` advection scheme](http://doi.org/10.1029/2023MS004130) for mesoscale-turbulence-resolving simulations. -`ClimaOcean` also provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, ocean velocity fields, and prescribed atmospheric states. +ClimaOcean also provides convenience features for wrangling datasets of bathymetry, ocean temperature, salinity, ocean velocity fields, and prescribed atmospheric states. -`ClimaOcean` is built on top of `Oceananigans` and `ClimaSeaIce`, so it's important that `ClimaOcean` users become proficient with [`Oceananigans`](https://github.com/CliMA/Oceananigans.jl). -Note that though `ClimaOcean` is currently focused on hydrostatic modeling with `Oceananigans`' `HydrostaticFreeSurfaceModel`, realistic nonhydrostatic modeling is also within the scope of this package. +ClimaOcean is built on top of Oceananigans and [ClimaSeaIce](https://github.com/CliMA/ClimaSeaIce.jl), so it's important that ClimaOcean users become proficient with [Oceananigans](https://github.com/CliMA/Oceananigans.jl). +Note that though ClimaOcean is currently focused on hydrostatic modeling with `Oceananigans.HydrostaticFreeSurfaceModel`, realistic nonhydrostatic modeling is also within the scope of this package.