This repository has been archived by the owner on Mar 1, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 78
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LenkaNovak
requested review from
kpamnany,
Zhengyu-Huang,
jiahe23 and
slifer50
September 16, 2020 16:45
kpamnany
suggested changes
Sep 17, 2020
jiahe23
reviewed
Sep 18, 2020
jiahe23
reviewed
Oct 9, 2020
src/Diagnostics/dump_spectra_gcm.jl
Outdated
# Setup dimensions | ||
interpol_dims = dimensions(interpol) | ||
lat = interpol_dims["lat"][1] | ||
level = interpol_dims["level"][1] |
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 think this is the distance from the Earth center. Earth radius should be removed to get the altitude heights.
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.
Yes -- as done here for example.
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.
@LenkaNovak: I added a fix for this here, please verify?
LenkaNovak
force-pushed
the
ln/gcm-spectra
branch
2 times, most recently
from
October 19, 2020 17:21
fa2d679
to
cb65214
Compare
kpamnany
force-pushed
the
ln/gcm-spectra
branch
3 times, most recently
from
October 20, 2020 20:45
718387c
to
01f36e6
Compare
kpamnany
approved these changes
Oct 20, 2020
@LenkaNovak: I think this is good to go. Please take a look and if you're happy, we can merge it. bors try |
Along with test cases and a diagnostics group. Refactor old spectra diagnostics group for Atmos LES. Co-authored-by: Jia <jiahe.gatech@gmail.com> Co-authored-by: K Pamnany <kpamnany@gmail.com>
kpamnany
force-pushed
the
ln/gcm-spectra
branch
from
October 21, 2020 15:44
74baa23
to
8cb6dcd
Compare
bors r+ |
4 tasks
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Co-authored by @jiahe23 , @kpamnany
This code calculates 1d spectra (Fourier transform at each latitude and height) and 2d spectra (spherical harmonic transformation at each height) for the GCM on the fly, or it can be ported to analysis scripts for offline calculations.
It is currently set up to be interpolated using the same output timestep and Gaussian grid as the
atmos_default_diagnostics
group, but these can be set separately (e.g. for less severe wavenumber truncations).Energy spectra are currently calculated using the meridional wind only.
Output is a separate NetCDF file, containing:
"spectrum_1d"[zonal wavenumber, latitude, height, time]
"spectrum_2d"[truncated zonal wavenumber, total wavenumber, height, time]
TODO in a separate PR
The code structure follows Yassine’s 3d turbulence LES spectra, and the spherical harmonic transformation is based on Daniel’s Julian FMS code.
I have
tests/runtests.jl
julia .dev/climaformat.jl .
For review by CLIMA developers
julia .dev/format.jl
has been run in a separate commit.