Skip to content

Commit

Permalink
Update to fix compat with breaking ClimaLand release
Browse files Browse the repository at this point in the history
modified:   Project.toml
modified:   components/land/climaland_bucket.jl
+ Fix unnecessary info statement and
config arg typo
	modified:   config/longrun_configs/amip_target_topo.yml
	modified:   experiments/ClimaEarth/components/atmosphere/climaatmos.jl
  • Loading branch information
akshaysridhar committed Jul 16, 2024
1 parent 3a2e35c commit fd24331
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 29 deletions.
1 change: 0 additions & 1 deletion config/longrun_configs/amip_target_topo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ hourly_checkpoint: true
land_albedo_type: "map_temporal"
mode_name: "amip"
mono_surface: false
hyperdiffusion: "ClimaHyperdiffusion"
netcdf_interpolate_z_over_msl: true
rad: "allskywithclear"
start_date: "20100101"
Expand Down
2 changes: 1 addition & 1 deletion experiments/ClimaEarth/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ AtmosphericProfilesLibrary = "0.1"
ClimaAnalysis = "0.5.4"
ClimaAtmos = "0.27"
ClimaCorePlots = "0.2"
ClimaLand = "0.13"
ClimaLand = "0.14"
ClimaParams = "0.10"
ClimaTimeSteppers = "0.7"
ClimaUtilities = "0.1"
Expand Down
1 change: 0 additions & 1 deletion experiments/ClimaEarth/components/atmosphere/climaatmos.jl
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ function get_atmos_config_dict(coupler_dict::Dict, job_id::String)
atmos_config_repo = coupler_dict["atmos_config_repo"]
# override default or specified configs with coupler arguments, and set the correct atmos config_file
comms_ctx = ClimaComms.context()
@info atmos_config_repo
if atmos_config_repo == "ClimaCoupler"
@assert !isnothing(atmos_config_file) "Must specify `atmos_config_file` within ClimaCoupler."
if ClimaComms.iamroot(comms_ctx)
Expand Down
26 changes: 0 additions & 26 deletions experiments/ClimaEarth/components/land/climaland_bucket.jl
Original file line number Diff line number Diff line change
Expand Up @@ -250,32 +250,6 @@ function Checkpointer.get_model_prog_state(sim::BucketSimulation)
return sim.integrator.u.bucket
end

###
### CL.jl bucket model-specific functions (not explicitly required by ClimaCoupler.jl)
###

# TODO remove this function after ClimaLand v0.8.1 update
function CL.turbulent_fluxes(atmos::CL.CoupledAtmosphere, model::CL.Bucket.BucketModel, Y, p, t)
# coupler has done its thing behind the scenes already
model_name = CL.name(model)
model_cache = getproperty(p, model_name)
return model_cache.turbulent_fluxes
end


function CL.initialize_drivers(a::CL.CoupledAtmosphere{FT}, coords) where {FT}
keys = (:P_liq, :P_snow)
types = ([FT for k in keys]...,)
domain_names = ([:surface for k in keys]...,)
model_name = :drivers
# intialize_vars packages the variables as a Interfacer.named tuple,
# as part of a Interfacer.named tuple with `model_name` as the key.
# Here we just want the variable Interfacer.named tuple itself
vars = CL.initialize_vars(keys, types, domain_names, coords, model_name)
return vars.drivers
end


"""
temp_anomaly_aquaplanet(coord)
Expand Down

0 comments on commit fd24331

Please sign in to comment.