diff --git a/Project.toml b/Project.toml index 1b56f605..efd6bdac 100644 --- a/Project.toml +++ b/Project.toml @@ -1,4 +1,4 @@ -name = "OceanLearning" +name = "ParameterEstimocean" uuid = "eca81dc5-87a6-4430-aec8-c76695404a43" license = "MIT" authors = ["Adeline Hillier ", "Gregory L. Wagner ", "Navid C. Constantinou ", "and co-contributors"] diff --git a/README.md b/README.md index e4db2180..0ba48cce 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,14 @@ -# OceanLearning.jl +# ParameterEstimocean.jl A Julia package that leverages [Oceananigans.jl](http://github.com/CliMA/Oceananigans.jl/) and [EnsembleKalmanProcesses.jl](https://github.com/CliMA/EnsembleKalmanProcesses.jl) to calibrate ocean turbulence parametrizations. -Continuous Integration: [![Build Status](https://github.com/CliMA/OceanLearning.jl/workflows/CI/badge.svg)](https://github.com/CliMA/OceanLearning.jl/actions?query=workflow%3ACI+branch%3Amaster) +Continuous Integration: [![Build Status](https://github.com/CliMA/ParameterEstimocean.jl/workflows/CI/badge.svg)](https://github.com/CliMA/ParameterEstimocean.jl/actions?query=workflow%3ACI+branch%3Amaster) -Code Coverage: [![codecov](https://codecov.io/gh/CliMA/OceanLearning.jl/branch/main/graph/badge.svg?token=cPeTALmiPU)](https://codecov.io/gh/CliMA/OceanLearning.jl) +Code Coverage: [![codecov](https://codecov.io/gh/CliMA/ParameterEstimocean.jl/branch/main/graph/badge.svg?token=cPeTALmiPU)](https://codecov.io/gh/CliMA/ParameterEstimocean.jl) -Stable Release Documentation: [![Build Status](https://img.shields.io/badge/documentation-stable%20release-blue)](https://clima.github.io/OceanLearning.jl/stable) +Stable Release Documentation: [![Build Status](https://img.shields.io/badge/documentation-stable%20release-blue)](https://clima.github.io/ParameterEstimocean.jl/stable) -Latest Documentation: [![Build Status](https://img.shields.io/badge/documentation-in%20development-orange)](https://clima.github.io/OceanLearning.jl/dev) +Latest Documentation: [![Build Status](https://img.shields.io/badge/documentation-in%20development-orange)](https://clima.github.io/ParameterEstimocean.jl/dev) Zenodo: [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.5762810.svg)](https://doi.org/10.5281/zenodo.5762810) @@ -20,7 +20,7 @@ registry so you need to install via Github. To install a tagged version of the p ```julia julia>] -(v1.6) pkg> add https://github.com/CliMA/OceanLearning.jl#v0.6.0 +(v1.6) pkg> add https://github.com/CliMA/ParameterEstimocean.jl#v0.6.0 (v1.6) pkg> instantiate ``` @@ -29,7 +29,7 @@ install the version on the `#main` branch (or any other branch or commit), e.g. ```julia julia>] -(v1.6) pkg> add https://github.com/CliMA/OceanLearning.jl#main +(v1.6) pkg> add https://github.com/CliMA/ParameterEstimocean.jl#main (v1.6) pkg> instantiate ``` @@ -38,4 +38,4 @@ julia>] The code is citable via [zenodo](https://zenodo.org). Please cite as: -> Adeline Hillier, Gregory L. Wagner, and Navid C. Constantinou. (2022). CliMA/OceanLearning.jl: OceanLearning.jl v0.10.2 (Version v0.10.2). Zenodo. [http://doi.org/10.5281/zenodo.5762810](http://doi.org/10.5281/zenodo.5762810) +> Adeline Hillier, Gregory L. Wagner, and Navid C. Constantinou. (2022). CliMA/ParameterEstimocean.jl: ParameterEstimocean.jl v0.10.2 (Version v0.10.2). Zenodo. [http://doi.org/10.5281/zenodo.5762810](http://doi.org/10.5281/zenodo.5762810) diff --git a/docs/make.jl b/docs/make.jl index fe764c88..6918814d 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -1,11 +1,11 @@ -pushfirst!(LOAD_PATH, joinpath(@__DIR__, "..")) # add OceanLearning to environment stack +pushfirst!(LOAD_PATH, joinpath(@__DIR__, "..")) # add ParameterEstimocean to environment stack using Documenter, Literate, CairoMakie, # so that Literate.jl does not capture precompilation output or warnings Distributions, - OceanLearning + ParameterEstimocean # Gotta set this environment variable when using the GR run-time on CI machines. # This happens when examples, e.g., use Plots.jl to make plots and movies. @@ -46,7 +46,7 @@ Timer(t -> println(" "), 0, interval=240) format = Documenter.HTML( collapselevel = 2, prettyurls = get(ENV, "CI", nothing) == "true", - canonical = "https://clima.github.io/OceanLearning/dev/", + canonical = "https://clima.github.io/ParameterEstimocean/dev/", ) pages = [ @@ -73,8 +73,8 @@ pages = [ ] makedocs( - sitename = "OceanLearning.jl", - modules = [OceanLearning], + sitename = "ParameterEstimocean.jl", + modules = [ParameterEstimocean], format = format, pages = pages, doctest = true, @@ -83,7 +83,7 @@ makedocs( checkdocs = :exports ) -deploydocs( repo = "github.com/CliMA/OceanLearning.jl", +deploydocs( repo = "github.com/CliMA/ParameterEstimocean.jl", versions = ["stable" => "v^", "v#.#.#", "dev" => "dev"], forcepush = true, devbranch = "main", diff --git a/docs/src/index.md b/docs/src/index.md index 0a426c27..e635ae83 100644 --- a/docs/src/index.md +++ b/docs/src/index.md @@ -1,5 +1,5 @@ -# OceanLearning.jl Documentation +# ParameterEstimocean.jl Documentation ## Overview -OceanLearning provides a framework to calibrate turbulence closure parametrizations for ocean models. +ParameterEstimocean provides a framework to calibrate turbulence closure parametrizations for ocean models. diff --git a/docs/src/installation_instructions.md b/docs/src/installation_instructions.md index 5355335a..2a626025 100644 --- a/docs/src/installation_instructions.md +++ b/docs/src/installation_instructions.md @@ -1,6 +1,6 @@ # Installation instructions -You can install the latest version of OceanLearning.jl via the built-in +You can install the latest version of ParameterEstimocean.jl via the built-in package manager (by pressing `]` in the Julia REPL command prompt) to add the package and also to instantiate/build all the required dependencies @@ -12,7 +12,7 @@ To install a tagged version of the package, e.g., v0.6.0, use ```julia julia>] -(v1.6) pkg> add https://github.com/CliMA/OceanLearning.jl#v0.6.0 +(v1.6) pkg> add https://github.com/CliMA/ParameterEstimocean.jl#v0.6.0 (v1.6) pkg> instantiate ``` @@ -21,6 +21,6 @@ install the version on the `#main` branch (or any other branch or commit), e.g. ```julia julia>] -(v1.6) pkg> add https://github.com/CliMA/OceanLearning.jl#main +(v1.6) pkg> add https://github.com/CliMA/ParameterEstimocean.jl#main (v1.6) pkg> instantiate ``` diff --git a/docs/src/library/internals.md b/docs/src/library/internals.md index fdc5f7a7..6bdcb3e6 100644 --- a/docs/src/library/internals.md +++ b/docs/src/library/internals.md @@ -1,19 +1,19 @@ # Private types and functions -Documentation for `OceanLearning.jl`'s internal interface. +Documentation for `ParameterEstimocean.jl`'s internal interface. -## OceanLearning +## ParameterEstimocean ```@autodocs -Modules = [OceanLearning] +Modules = [ParameterEstimocean] Public = false -Pages = ["OceanLearning.jl"] +Pages = ["ParameterEstimocean.jl"] ``` ## Transformations ```@autodocs -Modules = [OceanLearning.Transformations] +Modules = [ParameterEstimocean.Transformations] Public = false Pages = ["Transformations.jl"] ``` @@ -21,34 +21,34 @@ Pages = ["Transformations.jl"] ## Observations ```@autodocs -Modules = [OceanLearning.Observations] +Modules = [ParameterEstimocean.Observations] Public = false ``` ## Ensemble Simulations ```@autodocs -Modules = [OceanLearning.EnsembleSimulations] +Modules = [ParameterEstimocean.EnsembleSimulations] Public = false ``` ## Parameters ```@autodocs -Modules = [OceanLearning.Parameters] +Modules = [ParameterEstimocean.Parameters] Public = false ``` ## Inverse Problems ```@autodocs -Modules = [OceanLearning.InverseProblems] +Modules = [ParameterEstimocean.InverseProblems] Public = false ``` ## EnsembleKalmanInversions ```@autodocs -Modules = [OceanLearning.EnsembleKalmanInversions] +Modules = [ParameterEstimocean.EnsembleKalmanInversions] Public = false ``` diff --git a/docs/src/library/public.md b/docs/src/library/public.md index 0bab16a7..a3617c52 100644 --- a/docs/src/library/public.md +++ b/docs/src/library/public.md @@ -1,54 +1,54 @@ # Public Documentation -Documentation for `OceanLearning.jl`'s public interface. +Documentation for `ParameterEstimocean.jl`'s public interface. See the Internals section of the manual for internal package docs covering all submodules. -## OceanLearning +## ParameterEstimocean ```@autodocs -Modules = [OceanLearning] +Modules = [ParameterEstimocean] Private = false ``` ## Transformations ```@autodocs -Modules = [OceanLearning.Transformations] +Modules = [ParameterEstimocean.Transformations] Private = false ``` ## Observations ```@autodocs -Modules = [OceanLearning.Observations] +Modules = [ParameterEstimocean.Observations] Private = false ``` ## Ensemble Simulations ```@autodocs -Modules = [OceanLearning.EnsembleSimulations] +Modules = [ParameterEstimocean.EnsembleSimulations] Private = false ``` ## Parameters ```@autodocs -Modules = [OceanLearning.Parameters] +Modules = [ParameterEstimocean.Parameters] Private = false ``` ## Inverse Problems ```@autodocs -Modules = [OceanLearning.InverseProblems] +Modules = [ParameterEstimocean.InverseProblems] Private = false ``` ## EnsembleKalmanInversions ```@autodocs -Modules = [OceanLearning.EnsembleKalmanInversions] +Modules = [ParameterEstimocean.EnsembleKalmanInversions] Private = false ``` diff --git a/examples/calibrate_zonally_averaged_baroclinic_adjustment.jl b/examples/calibrate_zonally_averaged_baroclinic_adjustment.jl index 51266c89..bdd77af1 100644 --- a/examples/calibrate_zonally_averaged_baroclinic_adjustment.jl +++ b/examples/calibrate_zonally_averaged_baroclinic_adjustment.jl @@ -1,7 +1,7 @@ # Calibration of Gent-McWilliams to a baroclinic adjustment problem pushfirst!(LOAD_PATH, joinpath(@__DIR__, "..")) -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units using Oceananigans.Models.HydrostaticFreeSurfaceModels: SliceEnsembleSize @@ -37,7 +37,7 @@ close(file) field_names = (:b, :c, :u, :v) forward_map_names = (:b, :c) -using OceanLearning.Transformations: Transformation +using ParameterEstimocean.Transformations: Transformation transformation = (b = ZScore(), c = ZScore(), @@ -108,10 +108,10 @@ priors = ( free_parameters = FreeParameters(priors) -using OceanLearning.Observations: FieldTimeSeriesCollector +using ParameterEstimocean.Observations: FieldTimeSeriesCollector simulation_fields = fields(simulation.model) -collected_fields = NamedTuple(name => simulation_fields[name] for name in OceanLearning.Observations.forward_map_names(observations)) +collected_fields = NamedTuple(name => simulation_fields[name] for name in ParameterEstimocean.Observations.forward_map_names(observations)) time_series_collector = FieldTimeSeriesCollector(collected_fields, observation_times(observations), architecture=CPU()) calibration = InverseProblem(observations, simulation, free_parameters; time_series_collector) diff --git a/examples/calibrate_zonally_averaged_channel.jl b/examples/calibrate_zonally_averaged_channel.jl index c532ce5b..d904c034 100644 --- a/examples/calibrate_zonally_averaged_channel.jl +++ b/examples/calibrate_zonally_averaged_channel.jl @@ -4,11 +4,11 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, Distributions, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, Distributions, CairoMakie" # ``` -using OceanLearning -using OceanLearning.Observations: FieldTimeSeriesCollector +using ParameterEstimocean +using ParameterEstimocean.Observations: FieldTimeSeriesCollector using Oceananigans using Oceananigans.Units diff --git a/examples/exploring_priors.jl b/examples/exploring_priors.jl index a96114a3..5c8d0c91 100644 --- a/examples/exploring_priors.jl +++ b/examples/exploring_priors.jl @@ -1,6 +1,6 @@ # # Specifying and fine-tuning prior distributions # -# This example shows how to specify priors in `OceanLearning` +# This example shows how to specify priors in `ParameterEstimocean` # and illustrates some of their properties. # # ## Install dependencies @@ -9,12 +9,12 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, Distributions, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, Distributions, CairoMakie" # ``` # # Then we import packages -using OceanLearning +using ParameterEstimocean using CairoMakie using Distributions @@ -31,7 +31,7 @@ using Distributions # # # Prior flavors # -# `OceanLearning` supports three types of prior +# `ParameterEstimocean` supports three types of prior # distributions. The normal prior distribution is provided by `Distributions.jl`, normal_prior = Normal(0.1, 0.1) diff --git a/examples/intro_to_inverse_problems.jl b/examples/intro_to_inverse_problems.jl index 91316da9..fa0815a2 100644 --- a/examples/intro_to_inverse_problems.jl +++ b/examples/intro_to_inverse_problems.jl @@ -11,12 +11,12 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, Distributions, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, Distributions, CairoMakie" # ``` # First we load few things -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Architectures: arch_array @@ -30,7 +30,7 @@ using JLD2 # We reuse some utilities from a previous example to build observations: -examples_path = joinpath(pathof(OceanLearning), "..", "..", "examples") +examples_path = joinpath(pathof(ParameterEstimocean), "..", "..", "examples") include(joinpath(examples_path, "intro_to_observations.jl")) data_path = generate_synthetic_observations() observations = SyntheticObservations(data_path, field_names=:b, transformation=ZScore()) @@ -137,7 +137,7 @@ free_parameters = FreeParameters(priors) # We visualize our prior distributions by plotting a huge number # of samples: -using OceanLearning.Parameters: unconstrained_prior, transform_to_constrained +using ParameterEstimocean.Parameters: unconstrained_prior, transform_to_constrained Nsamples = 50000000 diff --git a/examples/intro_to_observations.jl b/examples/intro_to_observations.jl index f9ccbe78..57fbae8c 100644 --- a/examples/intro_to_observations.jl +++ b/examples/intro_to_observations.jl @@ -9,12 +9,12 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, CairoMakie" # ``` # First we load few things -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units using Oceananigans.TurbulenceClosures: ConvectiveAdjustmentVerticalDiffusivity diff --git a/examples/lesbrary_catke_calibration.jl b/examples/lesbrary_catke_calibration.jl index 7df54f23..0fd0ee2c 100644 --- a/examples/lesbrary_catke_calibration.jl +++ b/examples/lesbrary_catke_calibration.jl @@ -4,12 +4,12 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, CairoMakie" # ``` using Oceananigans using Oceananigans.Units -using OceanLearning +using ParameterEstimocean using LinearAlgebra, CairoMakie, DataDeps using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: @@ -17,7 +17,7 @@ using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: # # Using LESbrary data # -# `OceanLearning.jl` provides paths to synthetic observations +# `ParameterEstimocean.jl` provides paths to synthetic observations # derived from high-fidelity large eddy simulations. In this example, we illustrate # calibration of a turbulence parameterization to one of these simulations: diff --git a/examples/perfect_baroclinic_adjustment_calibration.jl b/examples/perfect_baroclinic_adjustment_calibration.jl index 51af5d84..7d107bb8 100644 --- a/examples/perfect_baroclinic_adjustment_calibration.jl +++ b/examples/perfect_baroclinic_adjustment_calibration.jl @@ -11,12 +11,12 @@ # ```julia # using Pkg -# pkg"add Oceananigans, Distributions, CairoMakie, OceanLearning" +# pkg"add Oceananigans, Distributions, CairoMakie, ParameterEstimocean" # ``` # First we load few things -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units @@ -185,7 +185,7 @@ free_parameters = FreeParameters(priors) # To visualize the prior distributions we randomly sample out values from then and plot the p.d.f. using CairoMakie -using OceanLearning.Parameters: unconstrained_prior, transform_to_constrained +using ParameterEstimocean.Parameters: unconstrained_prior, transform_to_constrained samples(prior) = [transform_to_constrained(prior, x) for x in rand(unconstrained_prior(prior), 10000000)] diff --git a/examples/perfect_catke_calibration.jl b/examples/perfect_catke_calibration.jl index c0fdf938..a044e5bd 100644 --- a/examples/perfect_catke_calibration.jl +++ b/examples/perfect_catke_calibration.jl @@ -4,12 +4,12 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, Distributions, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, Distributions, CairoMakie" # ``` -using OceanLearning, LinearAlgebra, CairoMakie +using ParameterEstimocean, LinearAlgebra, CairoMakie -using OceanLearning.Transformations: Transformation +using ParameterEstimocean.Transformations: Transformation using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: CATKEVerticalDiffusivity, MixingLength, SurfaceTKEFlux # # Perfect observations of CATKE-driven mixing @@ -23,7 +23,7 @@ using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: CATKEVerticalD # to generate the observations. ## Load utilities -examples_path = joinpath(pathof(OceanLearning), "..", "..", "examples") +examples_path = joinpath(pathof(ParameterEstimocean), "..", "..", "examples") include(joinpath(examples_path, "intro_to_inverse_problems.jl")) mixing_length = MixingLength(Cᴬu = 0.0, diff --git a/examples/perfect_convective_adjustment_calibration.jl b/examples/perfect_convective_adjustment_calibration.jl index b84a846f..5fca60ba 100644 --- a/examples/perfect_convective_adjustment_calibration.jl +++ b/examples/perfect_convective_adjustment_calibration.jl @@ -17,13 +17,13 @@ # ```julia # using Pkg -# pkg"add OceanLearning, Oceananigans, Distributions, CairoMakie" +# pkg"add ParameterEstimocean, Oceananigans, Distributions, CairoMakie" # ``` -using OceanLearning, LinearAlgebra, CairoMakie +using ParameterEstimocean, LinearAlgebra, CairoMakie # We reuse some some code from a previous example to generate observations, -examples_path = joinpath(pathof(OceanLearning), "..", "..", "examples") +examples_path = joinpath(pathof(ParameterEstimocean), "..", "..", "examples") include(joinpath(examples_path, "intro_to_inverse_problems.jl")) data_path = generate_synthetic_observations() diff --git a/src/Observations.jl b/src/Observations.jl index dff4024d..d3dc2570 100644 --- a/src/Observations.jl +++ b/src/Observations.jl @@ -18,8 +18,8 @@ using JLD2 import Oceananigans.Fields: set! -using OceanLearning.Utils: field_name_pairs -using OceanLearning.Transformations: Transformation, compute_transformation +using ParameterEstimocean.Utils: field_name_pairs +using ParameterEstimocean.Transformations: Transformation, compute_transformation abstract type AbstractObservation end diff --git a/src/OceanLearning.jl b/src/ParameterEstimocean.jl similarity index 99% rename from src/OceanLearning.jl rename to src/ParameterEstimocean.jl index a20cdc6d..b8b1d2b0 100644 --- a/src/OceanLearning.jl +++ b/src/ParameterEstimocean.jl @@ -1,4 +1,4 @@ -module OceanLearning +module ParameterEstimocean export SyntheticObservations, diff --git a/src/Parameters.jl b/src/Parameters.jl index 2fc3fdb6..7fcd4788 100644 --- a/src/Parameters.jl +++ b/src/Parameters.jl @@ -276,7 +276,7 @@ Example ======= ```jldoctest -julia> using Distributions, OceanLearning +julia> using Distributions, ParameterEstimocean julia> priors = (ν = Normal(1e-4, 1e-5), κ = Normal(1e-3, 1e-5)) (ν = Normal{Float64}(μ=0.0001, σ=1.0e-5), κ = Normal{Float64}(μ=0.001, σ=1.0e-5)) @@ -345,7 +345,7 @@ Example ======= ```jldoctest; filter = [r".*Dict{Symbol.*", r".*:type => Closure.*", r".*:c => 3.*", r".*:subclosure => Dict{Symbol.*"] -julia> using OceanLearning.Parameters: construct_object, dict_properties, closure_with_parameters +julia> using ParameterEstimocean.Parameters: construct_object, dict_properties, closure_with_parameters julia> struct Closure; subclosure; c end @@ -437,7 +437,7 @@ then replaced with the value provided. julia> new_parameters = (a = 12, d = 7) (a = 12, d = 7) -julia> using OceanLearning.Parameters: closure_with_parameters +julia> using ParameterEstimocean.Parameters: closure_with_parameters julia> closure_with_parameters(closure, new_parameters) Closure(ClosureSubModel(12, 2), 3) diff --git a/test/runtests.jl b/test/runtests.jl index 9e91fa7a..35e75546 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -11,7 +11,7 @@ include("test_ensemble_kalman_inversion.jl") include("test_utils.jl") @testset "Doctests" begin - using OceanLearning, Distributions + using ParameterEstimocean, Distributions - doctest(OceanLearning) + doctest(ParameterEstimocean) end diff --git a/test/test_ensemble_column_models.jl b/test/test_ensemble_column_models.jl index 62e3ae28..7b3ae1ca 100644 --- a/test/test_ensemble_column_models.jl +++ b/test/test_ensemble_column_models.jl @@ -1,5 +1,5 @@ using Test -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Models.HydrostaticFreeSurfaceModels: ColumnEnsembleSize using Oceananigans.TurbulenceClosures: ConvectiveAdjustmentVerticalDiffusivity diff --git a/test/test_ensemble_kalman_inversion.jl b/test/test_ensemble_kalman_inversion.jl index 28c53ae8..8ec84f80 100644 --- a/test/test_ensemble_kalman_inversion.jl +++ b/test/test_ensemble_kalman_inversion.jl @@ -8,11 +8,11 @@ using Oceananigans.Units using Oceananigans.Models.HydrostaticFreeSurfaceModels: ColumnEnsembleSize using Oceananigans: fields -using OceanLearning -using OceanLearning.EnsembleKalmanInversions: iterate! -using OceanLearning.EnsembleKalmanInversions: FullEnsembleDistribution, Resampler -using OceanLearning.EnsembleKalmanInversions: resample!, column_has_nan -using OceanLearning.InverseProblems: inverting_forward_map +using ParameterEstimocean +using ParameterEstimocean.EnsembleKalmanInversions: iterate! +using ParameterEstimocean.EnsembleKalmanInversions: FullEnsembleDistribution, Resampler +using ParameterEstimocean.EnsembleKalmanInversions: resample!, column_has_nan +using ParameterEstimocean.InverseProblems: inverting_forward_map data_path = "convective_adjustment_test.jld2" Nensemble = 3 diff --git a/test/test_forward_map.jl b/test/test_forward_map.jl index 9b98f56a..4d332917 100644 --- a/test/test_forward_map.jl +++ b/test/test_forward_map.jl @@ -1,15 +1,15 @@ using Test using LinearAlgebra using Distributions -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units using Oceananigans.Grids: halo_size using Oceananigans.Models.HydrostaticFreeSurfaceModels: ColumnEnsembleSize using Oceananigans.TurbulenceClosures: ConvectiveAdjustmentVerticalDiffusivity -using OceanLearning.Observations: FieldTimeSeriesCollector, initialize_forward_run!, observation_times -using OceanLearning.InverseProblems: transpose_model_output, forward_run!, drop_y_dimension +using ParameterEstimocean.Observations: FieldTimeSeriesCollector, initialize_forward_run!, observation_times +using ParameterEstimocean.InverseProblems: transpose_model_output, forward_run!, drop_y_dimension @testset "Unit tests for forward_map" begin # Test drop_y_dimension diff --git a/test/test_lesbrary_datadeps.jl b/test/test_lesbrary_datadeps.jl index b7f91526..956e5d0e 100644 --- a/test/test_lesbrary_datadeps.jl +++ b/test/test_lesbrary_datadeps.jl @@ -1,6 +1,6 @@ using Test using DataDeps -using OceanLearning +using ParameterEstimocean always_accept = get(ENV, "DATADEPS_ALWAYS_ACCEPT", false) ENV["DATADEPS_ALWAYS_ACCEPT"] = true diff --git a/test/test_lesbrary_forward_map.jl b/test/test_lesbrary_forward_map.jl index 3c1b5071..ebec4e5e 100644 --- a/test/test_lesbrary_forward_map.jl +++ b/test/test_lesbrary_forward_map.jl @@ -2,13 +2,13 @@ using Test using LinearAlgebra using Distributions using DataDeps -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: CATKEVerticalDiffusivity, MixingLength -using OceanLearning.Parameters: unconstrained_prior, transform_to_constrained +using ParameterEstimocean.Parameters: unconstrained_prior, transform_to_constrained @testset "Forward map evaluation with LESbrary observations" begin @testset "Convective-adjustment-based ensemble simulations" begin diff --git a/test/test_parameters.jl b/test/test_parameters.jl index 674adb74..5449549b 100644 --- a/test/test_parameters.jl +++ b/test/test_parameters.jl @@ -1,12 +1,12 @@ using Test -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Models.HydrostaticFreeSurfaceModels: ColumnEnsembleSize using Oceananigans.TurbulenceClosures: ConvectiveAdjustmentVerticalDiffusivity using Oceananigans.TurbulenceClosures.CATKEVerticalDiffusivities: CATKEVerticalDiffusivity, MixingLength, SurfaceTKEFlux using Suppressor: @suppress -using OceanLearning.Parameters: closure_with_parameters, update_closure_ensemble_member! +using ParameterEstimocean.Parameters: closure_with_parameters, update_closure_ensemble_member! const CAVD = ConvectiveAdjustmentVerticalDiffusivity const CATKE = CATKEVerticalDiffusivity diff --git a/test/test_synthetic_observations.jl b/test/test_synthetic_observations.jl index 7248fdf7..57003524 100644 --- a/test/test_synthetic_observations.jl +++ b/test/test_synthetic_observations.jl @@ -1,6 +1,6 @@ using Test using DataDeps -using OceanLearning +using ParameterEstimocean using Oceananigans using Oceananigans.Units using Oceananigans.Models.HydrostaticFreeSurfaceModels: ColumnEnsembleSize diff --git a/test/test_transformations.jl b/test/test_transformations.jl index 72197703..0db63e52 100644 --- a/test/test_transformations.jl +++ b/test/test_transformations.jl @@ -1,6 +1,6 @@ using Test using DataDeps -using OceanLearning +using ParameterEstimocean using Statistics diff --git a/test/test_utils.jl b/test/test_utils.jl index 973dc191..59f4717c 100644 --- a/test/test_utils.jl +++ b/test/test_utils.jl @@ -1,6 +1,6 @@ using Test -using OceanLearning -using OceanLearning.Utils: prettyvector +using ParameterEstimocean +using ParameterEstimocean.Utils: prettyvector @test prettyvector([0, 1, 2]) == "[0, 1, 2]" @test prettyvector(collect(0:20)) == "[0, 1, 2 … 20, 19, 18] (21 elements)"