-
Notifications
You must be signed in to change notification settings - Fork 2
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
Tr/minor tempest regridder changes #140
Conversation
ext/TempestRegridderExt.jl
Outdated
@@ -72,10 +72,10 @@ function Regridders.TempestRegridder( | |||
input_file::AbstractString; | |||
regrid_dir::AbstractString, | |||
mono::Bool = true, | |||
outfile_root::AbstractString = "cgll", |
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.
Why is this needed?
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.
There is no real need for this to be a kwarg, or outfile_root
to be changed in general.
Files saved during Regridding currently have a name structure as
hd_outfile_root * "_" * varname * "_" * string(time) * ".hdf5"
but hd_outfile_root
is automatically set to varname
, so the path becomes
varname * "_" * varname * "_" * string(time) * ".hdf5"
, which seems odd to me. The changes/potential changes in this PR came up in this PR
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.
Ah okay! I guess we can directly removed the hd_outfile_root
then
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 agree it's okay to remove it. It would be good to have an organized naming of regridded files when/if we support regridding a file that contains multiple variables. But that can be accomplished using regrid_dir
rather than outfile_root
.
24a4192
to
16eaf38
Compare
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.
Thank you!
This was automatically set to `varname`, which resulted in save paths of the form varname_varname_time.hdf5. This path is never exposed to the user, so there is no interface change.
Add very simple TempestRegridder test Add test for read_available_dates
The functionality of the `yyyymmdd_to_datetime` function is already contained in the Dates package.
16eaf38
to
991b2df
Compare
Purpose
Make TempestRegridder support multiple vars (maybe)This is likely not needed. It should be its own PR if we ever decide it is needed, and the implementation/interface requires planning to reflect the design of InterpolatonsRegridderMake outfile_root a kwarg for TempestRegridderJust remove it.improve on read_available_datesyyyymmdd_to_datetime
with Dates built in parsingTo-do
Content