Skip to content

Commit

Permalink
Add missing blocks to the dycore Jacobian
Browse files Browse the repository at this point in the history
  • Loading branch information
dennisYatunin committed Dec 22, 2023
1 parent c621bcb commit f7927db
Show file tree
Hide file tree
Showing 8 changed files with 297 additions and 79 deletions.
9 changes: 7 additions & 2 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ steps:
julia --color=yes --project=examples examples/hybrid/driver.jl
--config_file $CONFIG_PATH/single_column_precipitation_test.yml
artifact_paths: "single_column_precipitation_test/*"
agents:
slurm_mem: 16GB

- group: "Column Examples"
steps:
Expand Down Expand Up @@ -710,6 +712,7 @@ steps:
artifact_paths: "gpu_implicit_barowave_ref/*"
agents:
slurm_gpus: 1
slurm_mem: 16GB

- label: "GPU: compare BW with CPU"
command: >
Expand Down Expand Up @@ -768,7 +771,7 @@ steps:
agents:
slurm_gpus_per_task: 1
slurm_ntasks: 4
slurm_mem: 32G
slurm_mem: 40G

- label: "GPU: GPU moist Held-Suarez"
command:
Expand Down Expand Up @@ -821,6 +824,7 @@ steps:
artifact_paths: "gpu_implicit_barowave/*"
agents:
slurm_gpus: 1
slurm_mem: 16G

- label: "Perf: GPU implicit baro wave moist"
command: >
Expand All @@ -830,6 +834,7 @@ steps:
artifact_paths: "gpu_implicit_barowave_moist/*"
agents:
slurm_gpus: 1
slurm_mem: 16G

- label: "Perf: CPU implicit baro wave"
command: >
Expand Down Expand Up @@ -887,7 +892,7 @@ steps:
$PERF_CONFIG_PATH/flame_perf_target_prognostic_edmfx_aquaplanet.yml
artifact_paths: "flame_perf_target_prognostic_edmfx_aquaplanet/*"
agents:
slurm_mem: 24GB
slurm_mem: 32GB

- label: ":fire: Flame graph: perf target (barowave jfnk)"
command: >
Expand Down
4 changes: 2 additions & 2 deletions perf/flame.jl
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ allocs_limit["flame_perf_target"] = 148_256
allocs_limit["flame_perf_target_tracers"] = 180_512
allocs_limit["flame_perf_target_edmfx"] = 7_005_552
allocs_limit["flame_perf_diagnostics"] = 25_356_928
allocs_limit["flame_perf_target_diagnostic_edmfx"] = 1_311_040
allocs_limit["flame_perf_target_diagnostic_edmfx"] = 1_315_072
allocs_limit["flame_sphere_baroclinic_wave_rhoe_equilmoist_expvdiff"] =
4_018_252_656
allocs_limit["flame_perf_target_threaded"] = 1_276_864
allocs_limit["flame_perf_target_callbacks"] = 37_277_112
allocs_limit["flame_perf_gw"] = 3_226_429_472
allocs_limit["flame_perf_gw"] = 3_226_429_728
allocs_limit["flame_perf_target_prognostic_edmfx_aquaplanet"] = 1_258_848

# Ideally, we would like to track all the allocations, but this becomes too
Expand Down
2 changes: 1 addition & 1 deletion regression_tests/ref_counter.jl
Original file line number Diff line number Diff line change
@@ -1 +1 @@
141
142
3 changes: 3 additions & 0 deletions src/cache/cache.jl
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ end
# This is a constant Coriolis frequency that is only used if space is flat
function build_cache(Y, atmos, params, surface_setup, dt, t_end, start_date)
FT = eltype(params)
CTh = CTh_vector_type(Y.c)

ᶜcoord = Fields.local_geometry_field(Y.c).coordinates
grav = FT(CAP.grav(params))
Expand Down Expand Up @@ -155,6 +156,8 @@ function build_cache(Y, atmos, params, surface_setup, dt, t_end, start_date)
ᶜp_ref,
ᶜT = similar(Y.c, FT),
ᶜf,
ᶜkappa_m = similar(Y.c, FT),
∂ᶜK_∂ᶜuₕ = similar(Y.c, DiagonalMatrixRow{Adjoint{FT, CTh{FT}}}),
∂ᶜK_∂ᶠu₃ = similar(Y.c, BidiagonalMatrixRow{Adjoint{FT, CT3{FT}}}),
# Used by diagnostics such as hfres, evspblw
surface_ct3_unit = CT3.(
Expand Down
2 changes: 1 addition & 1 deletion src/parameters/Parameters.jl
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ for var in fieldnames(TD.Parameters.ThermodynamicsParameters)
@eval $var(ps::ACAP) = TD.Parameters.$var(thermodynamics_params(ps))
end
# Thermodynamics derived parameters
for var in [:molmass_ratio, :R_d, :R_v, :cp_d, :cv_v, :cv_l, :cv_d]
for var in [:molmass_ratio, :R_d, :R_v, :e_int_v0, :cp_d, :cv_v, :cv_l, :cv_d]
@eval $var(ps::ACAP) = TD.Parameters.$var(thermodynamics_params(ps))
end

Expand Down
Loading

0 comments on commit f7927db

Please sign in to comment.