Skip to content

Commit

Permalink
Add high resolution clm data artifact
Browse files Browse the repository at this point in the history
This commit also modifies the `lm_data_folder_path`
function to accept a new keyword argument: `lowres`,
which determines if the normal (old) artifact or
highres artifact path is returned. This is also added
to the `clm_canopy_parameters` function.
  • Loading branch information
imreddyTeja committed Feb 3, 2025
1 parent 27accf4 commit 477838c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 4 deletions.
7 changes: 7 additions & 0 deletions Artifacts.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ git-tree-sha1 = "3f6873a3e67722bda1fd23f7d5a05f5e2df1fe8c"
sha256 = "830136abec15551a343b7884d657fb6a79b16a37237681a2becf65bd845aa692"
url = "https://caltech.box.com/shared/static/6pu2f6c99g29qawvjjh3j56drkonpd3z.gz"

[clm_data_highres]
git-tree-sha1 = "e68ba26e07c135f66d1ad678795b4a25c929b1b6"

[[clm_data_highres.download]]
sha256 = "2c7e6ba3c11e1e6ef209c7437aa18fb4cf15edd11332527bf0b41495dccbed19"
url = "https://caltech.box.com/shared/static/kk72iah76p99yggm8knu6me8fh9eiid0.gz"

[era5_land_forcing_data2008]
git-tree-sha1 = "93d2e93f491e77cb8fba2a1b8b3946f38bde469e"
[era5_land_forcing_data2008_lowres]
Expand Down
8 changes: 6 additions & 2 deletions src/Artifacts.jl
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,12 @@ end
Return the path to the folder that contains the clm data.
"""
function clm_data_folder_path(; context = nothing)
return @clima_artifact("clm_data", context)
function clm_data_folder_path(; context = nothing, lowres = false)
if lowres
return @clima_artifact("clm_data", context)
else
return @clima_artifact("clm_data_highres", context)
end
end

"""
Expand Down
8 changes: 6 additions & 2 deletions src/simulations/spatial_parameters.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ end
Interpolations.Flat(),
Interpolations.Flat(),
),
lowres = false,
)
Reads spatially varying parameters for the canopy, from NetCDF files
Expand All @@ -38,7 +39,8 @@ The NetCDF files are stored in ClimaArtifacts and more detail on their origin
is provided there. The keyword arguments `regridder_type` and `extrapolation_bc`
affect the regridding by (1) changing how we interpolate to ClimaCore points which
are not in the data, and (2) changing how extrapolate to points beyond the range of the
data.
data. The keyword argument lowres is a flag that determines if the low resolution
or high resolution CLM data artifact is used.
"""
function clm_canopy_parameters(
surface_space;
Expand All @@ -48,9 +50,11 @@ function clm_canopy_parameters(
Interpolations.Flat(),
Interpolations.Flat(),
),
lowres = false,
)
context = ClimaComms.context(surface_space)
clm_artifact_path = ClimaLand.Artifacts.clm_data_folder_path(; context)
clm_artifact_path =
ClimaLand.Artifacts.clm_data_folder_path(; context, lowres)
# Foliage clumping index data derived from MODIS
modis_ci_artifact_path =
ClimaLand.Artifacts.modis_ci_data_folder_path(; context)
Expand Down

0 comments on commit 477838c

Please sign in to comment.