Skip to content

Remove ClimaLandSimulations #1110

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

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@ steps:
- "julia --project=test -e 'using Pkg; Pkg.develop(;path=\".\"); Pkg.add(\"MPI\"); Pkg.add(\"CUDA\"); Pkg.instantiate(;verbose=true)'"
- "julia --project=test -e 'using Pkg; Pkg.status()'"

- echo "--- Instantiate lib/ClimaLandSimulations"
- "julia --project=lib/ClimaLandSimulations -e 'using Pkg; Pkg.develop(;path=\".\"); Pkg.instantiate(;verbose=true)'"
- "julia --project=lib/ClimaLandSimulations -e 'using Pkg; Pkg.status()'"

agents:
slurm_gpus: 1
# Ensures that we have all the 8 tasks on the same node
Expand Down Expand Up @@ -135,12 +131,6 @@ steps:
env:
CLIMACOMMS_DEVICE: "CUDA"

- group: "ClimaLandSimulations"
steps:
- label: "Ozark figures Makie"
command: "julia --color=yes --project=lib/ClimaLandSimulations lib/ClimaLandSimulations/experiments/ozark.jl"
artifact_paths: "figures/*pdf"

- group: "CPU: global bucket"
steps:
- label: "Global Bucket on CPU (functional albedo)"
Expand Down
36 changes: 0 additions & 36 deletions .github/workflows/ClimaLandSimulations.yml

This file was deleted.

2 changes: 1 addition & 1 deletion docs/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"
BSON = "fbb218c0-5317-5bc6-957e-2ee96dd4b1f0"
CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b"
CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0"
ClimaComms = "3a4d1b5c-c61d-41fd-a00a-5873ba7a1b0d"
ClimaCore = "d414da3d-4745-48bb-8d80-42e94e092884"
ClimaLand = "08f4d4ce-cf43-44bb-ad95-9d2d5f413532"
ClimaLandSimulations = "348a0bd3-1299-4261-8002-d2cd97df6055"
ClimaParams = "5c42b081-d73a-476f-9059-fd94b934656c"
ClimaTimeSteppers = "595c0a79-7f3d-439a-bc5a-b232dc3bde79"
ClimaUtilities = "b3f4f4ca-9299-4f7f-bd9b-81e1242a7513"
Expand Down
17 changes: 1 addition & 16 deletions docs/src/folderstructure.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
- experiments: contains simple runs of `ClimaLand` models. Most of these experiments is run as part of our CI.
- src: contains the code of `ClimaLand` models.
- ext: contains a package extension for Neural Snow and an extension with constructors for model parameters
- lib: contains two packages that extend ClimaLand functionality: ClimaLandSimulations and ClimaLandDashboards
- test: contains [unit tests](https://en.wikipedia.org/wiki/Unit_testing), which are meant to ensure small pieces of ClimaLand source code work as intended before merging pull requests.

and 3 GitHub actions folders. GitHub actions are `.yml` files that define workflows that are run at each pull request.
Expand Down Expand Up @@ -84,20 +83,6 @@ As well as two files:
- ClimaLand.jl: This file is the main Julia module of `ClimaLand.jl` repository. It contains all functions defined in `/src` in a nested way, for example `ClimaLand.X`, `ClimaLand.Soil.X`, `ClimaLand.Canopy.X`, etc. When a Julia user install and uses ClimaLand via `]add ClimaLand, using ClimaLand`, they are loading those functions, and are ready to use ClimaLand codebase.
- Artifacts.jl: Contains functions that return the path of the given artifact name in the current context

## /lib folder

This folder contains a subfolder, `/ClimaLandSimulations`, which contains a library of methods
to easily and conveniently run ClimaLand at a variety of sites and globally. There are 3 subfolders:

- experiments: This folder contains scripts to run ClimaLand at a fluxnet site using ClimaLandSimulations
- src: Contains source code for the ClimaLandSimulations package. There are 3 subfolders and
1 file.
- Dashboards: Contains scripts to create dashboards for running simulations at fluxnet sites
- Fluxnet: Contains scripts to setup a ClimaLand simulation at a fluxnet site
- utilities: Contains utilities used in setup of ClimaLand simulation at a fluxnet sites

- test: Contains tests for the ClimaLandSimulations package

## /ext folder
This folder has one subfolder, `/neural_snow`, which contains tools to create the neural network
for snow and process its data. There are also two files
Expand All @@ -121,4 +106,4 @@ subfolders:
- aqua.jl: Contains code quality assurance tests tha use Aqua.jl
- Project.toml: Specifies dependencies needed for testing
- runtests.jl: When `test` is ran from the package manager, this file is ran. It can also be
manually ran using the `test` environment. This file runs all the other test scripts.
manually ran using the `test` environment. This file runs all the other test scripts.
47 changes: 0 additions & 47 deletions docs/src/standalone/apps.jl
Copy link
Member

Choose a reason for hiding this comment

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

This one should not be removed - it is unrelated to ClimaLandSimulations (it is making ParamViz apps)

Copy link
Member Author

Choose a reason for hiding this comment

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

It is using ClimaLandSimulations for ClimaLandSimulations.Dashboards.fluxnet_app();

I guess we have to move that stuff out

Copy link
Member

Choose a reason for hiding this comment

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

yes - we can remove that line

This file was deleted.

3 changes: 2 additions & 1 deletion docs/tutorials/calibration/minimal_working_example_obs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@
# 3. The prior distribution of these parameters.

# ## Load packages
import ClimaLandSimulations.Fluxnet as CLS # to run the model
import EnsembleKalmanProcesses as EKP # to perform the calibration
import Random # to use the same seed each run in the tutorial, optional
import Logging
Logging.disable_logging(Logging.Warn); # hide julia warnings

include("run_fluxnet.jl")

# ## Write a function returning our model LHF output given the parameters to calibrate
function Ozark_LHF(params) # params is a 2 element Array
g1, sc, pc = params
Expand Down
58 changes: 27 additions & 31 deletions experiments/integrated/fluxnet/met_drivers_FLUXNET.jl
Original file line number Diff line number Diff line change
Expand Up @@ -163,42 +163,38 @@ atmos = ClimaLand.PrescribedAtmosphere(
c_co2 = atmos_co2,
)

function zenith_angle(
t,
start_date;
latitude = lat,
longitude = long,
insol_params::Insolation.Parameters.InsolationParameters{FT} = earth_param_set.insol_params,
) where {FT}
# This should be time in UTC
current_datetime = start_date + Dates.Second(round(t))

# Orbital Data uses Float64, so we need to convert to our sim FT
d, δ, η_UTC =
FT.(
Insolation.helper_instantaneous_zenith_angle(
current_datetime,
start_date,
insol_params,
)
)

FT(
Insolation.instantaneous_zenith_angle(
d,
δ,
η_UTC,
longitude,
latitude,
)[1],
)
end
radiation = ClimaLand.PrescribedRadiativeFluxes(
FT,
SW_IN,
LW_IN,
UTC_DATETIME[1];
θs = zenith_angle,
θs = (t, start_date) ->
let longitude = long,
latitude = lat,
insol_params = earth_param_set.insol_params
# This should be time in UTC
current_datetime = start_date + Dates.Second(round(t))

# Orbital Data uses Float64, so we need to convert to our sim FT
d, δ, η_UTC =
FT.(
Insolation.helper_instantaneous_zenith_angle(
current_datetime,
start_date,
insol_params,
)
)

FT(
Insolation.instantaneous_zenith_angle(
d,
δ,
η_UTC,
longitude,
latitude,
)[1],
)
end,
earth_param_set = earth_param_set,
)

Expand Down
Loading