-
Notifications
You must be signed in to change notification settings - Fork 27
Use CommonSpaces/Grids #4021
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
base: main
Are you sure you want to change the base?
Use CommonSpaces/Grids #4021
Conversation
a6e453a to
c8ece52
Compare
09527fa to
0d59561
Compare
0d59561 to
5a36b1e
Compare
a878a51 to
1342d7b
Compare
c1b1a4d to
725681b
Compare
7327a63 to
3fbfbfe
Compare
3f51371 to
3d809fd
Compare
dennisYatunin
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great! Excited to have columns that are actually real columns after this PR
src/solver/type_getters.jl
Outdated
| spaces = get_spaces(config.parsed_args, params, config.comms_ctx) | ||
| spaces = get_spaces(grid) | ||
| end | ||
| @info spaces.center_space.grid |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you're planning to leave this in the PR, maybe use @show instead of @info, or add a string to clarify what's being printed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought this log line would replace the existing Resolution stats, but I can extract and log them to keep the existing format:
┌ Info: Resolution stats:
│ Nq = 4
│ h_elem = 6
│ z_elem = 10
│ ncols = 3456
└ ndofs_total = 34560
Here's what this PR prints (different grid from above):
┌ Info: ExtrudedFiniteDifferenceGrid:
│ horizontal:
│ context: SingletonCommsContext using CUDADevice
│ mesh: 100×1-element RectilinearMesh of RectangleDomain: x ∈ [0.0,100000.0] (periodic) × y ∈ [0.0,1000.0] (periodic)
│ quadrature: 4-point Gauss-Legendre-Lobatto quadrature
│ vertical:
└ mesh: 100-element IntervalMesh of IntervalDomain: z ∈ [0.0,21000.0] (:bottom, :top)
9671fce to
be2682e
Compare
be2682e to
6d662df
Compare
src/simulation/grids.jl
Outdated
| @info "Using $(nameof(typeof(topography))) orography" | ||
| end | ||
|
|
||
| if topography isa EarthTopography |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if topo_smoothing
6d662df to
28655e6
Compare
28655e6 to
db2e99d
Compare
Purpose
Use ClimaCore's CommonGrids and CommonSpaces to create spaces.
To-do
Content
hypsography_function_from_topographywhich returns a hypsography function passed to ClimaCore.get_spaces(grid, context)function replaces parsed-args dependentget_spaces(parsed_args, params, comms_ctx)periodic_line_mesh,periodic_rectangle_mesh,make_hybrid_spaces∂ᶜK_∂ᶜuₕfield type fromDiagonalMatrixRow{Adjoint{FT, CTh{FT}}}to use CT12is_columnanddo_dssto match new spaces