-
Notifications
You must be signed in to change notification settings - Fork 258
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
Write out valid time as a string in history files #1052
Write out valid time as a string in history files #1052
Comments
See these example files: /scratch2/NCEPDEV/fv3-cam/Dusan.Jovic/ufs/valid_time/control_CubedSphereGrid/atmf000.nc code is in this branch: https://github.com/DusanJovic-NOAA/fv3atm/tree/valid_time |
@DusanJovic-NOAA thank you so much for a quick implementation, this is exactly what I was looking for! Now I can remove a lot of julian day computations and just read the valid time string directly, this is perfect! |
@CoryMartin-NOAA @aerorahul The unit attribute is not strictly correct, I think we should just use 'description' attribute for this variable. Also the name itself (valid_time) is a bit misleading. Variable 'time' is also valid time, it's just represented as number instead as text. so how about this:
|
@DusanJovic-NOAA those changes work for me, you are right, both variables should give you the same time, it's just different formats/representations. |
I updated the sample files (above) to use |
I'm looking at the values of
As you can see there's a slight difference, because this is not actually 00hr output but
So, my suggestion is to store |
Another question is: |
I have no idea why these soil fields are written like they are now. @junwang-noaa |
I don't know either, my guess would be that there were limitations in the past with hon many vertical dimensions could be in the file. It's a bad design, because for outputting RUC LSM data, you need 9 separate soilt, soilw, soilm variables (and there is extra code in |
@CoryMartin-NOAA Soil layers are the vertical dimension for those fields. I don't remember if fv3 has that axis information. We need to check if we need to add the soil layer dimension, then these fields can have a vertical dimension, rather than a 2D dimension |
Thanks @junwang-noaa , if we could write these variables with a vertical dimension that would be great. That is what GEOS does and it would greatly simplify the I/O in FV3-JEDI. |
@junwang-noaa Wouldn't that break downstream programs (upp)? |
Isn't this for tiled cubed sphere output? Does UPP read tiled output already? |
UPP does not read cubed sphere outputs, yet, but the same write routine, the same write FieldBundle, the same Fields in that bundle, the same attributes and dimensions of each field are used for all other output grid types/formats. |
BTW, I suggest we open separate issue, this issue is for adding 'valid time' variable. |
@DusanJovic-NOAA I will open a new issue related to the |
Yes, the upp interface needs to be changed if we make the soil_layer dimension change. |
Description
Currently, UFS write-grid component writes out valid time like so:
This requires routines to compute the valid time using the value of time(t) and the unit string. These are in
w3emc
but is not a trivial thing to do without external libraries.It would be nice to have something akin to the following added:
So that one can easily grab:
2022-02-16T17:11:00Z
This will be useful for a few things, most notably 1) checking in FV3-JEDI that the valid time from a cubed-sphere history file is at the expected time and 2) having an easy variable for plotting model output.
Solution
Add a string representation of the model valid time to the history files.
Alternatives
Add an integer representation of the model valid time to the history files.
Related to
Adding cube-sphere history I/O to FV3-JEDI.
The text was updated successfully, but these errors were encountered: