Uh oh!
There was an error while loading. Please reload this page.
Update start and end dates from climatology data set; issue a warning - #157
Conversation
xylar
commented
Mar 25, 2017
@milenaveneziani, this is an implementation of your suggested fix to #149 for the MOC. |
xylar
commented
Mar 25, 2017
TestingI tested this with the QU240 test case. As expected, the file names for the MOC cache files and plots now end at year 2 even when I have the end year set to 50 in the config file. |
milenaveneziani
commented
Mar 25, 2017
great, @xylar, thanks. |
xylar
commented
Mar 25, 2017
Yes, that's a very good idea. I implemented that and am testing it now. |
xylar
commented
Mar 25, 2017
Seems to behave as expected: |
xylar
commented
Mar 25, 2017
Note: the warning will only occur once, since the start and end years have been updated in |
milenaveneziani
commented
Mar 26, 2017
very nice, thanks @xylar! |
After reading in a data set, set the real start and end years based on the data read in.
A new function is added to climatology to update the climatology start and end years to match those of a data set. If the start and/or end year are changed, a warning is issued and the config options are updated.
xylar
commented
Mar 26, 2017
Thanks @milenaveneziani. I just rebased and fixed the conflict. |
milenaveneziani
commented
Mar 27, 2017
@xylar: I have tested this on edison with a newer beta1 run for which I only had 25 years of data available. I requested climos for year 1-60, and everything worked out as expected. |
xylar
commented
Mar 27, 2017
Thanks, @milenaveneziani. I hadn't noticed the weird end of the warning message. The fix might be just to have a very long line for that warning... |
xylar
commented
Mar 27, 2017
Basically, I think this is the expected behavior. I'm a little surprised python doesn't print all lines from |
milenaveneziani
commented
Mar 28, 2017
yeah, I noticed that too. I think if you don't have carriage returns in the line, then it will print the whole line. |
Add a function to update the
startYearandendYearconfig options based on the start and end of a climatology data set. A warning is issued if the start and end years are different from those requested by the user.All analysis tasks for computing climatologies now use this function to make sure plot titles and file names use the start and end years of the data set (as opposed to those requested in the config file). The MOC cache file name now uses the actual start and end years as well.