Fix occurrence of time for max/min of diagnostics in clWRF#1208
Conversation
|
jenkins is OK |
|
I put a comment on the Issues thread that there other times that probably
also need
initializing like this.
…On Thu, Jun 11, 2020 at 8:10 AM Dave Gill ***@***.***> wrote:
jenkins is OK
Please find result of the WRF regression test cases in the attachment. This build is for Commit ID: 86567d6, requested by: christopherthomas for PR: #1208. For any query please send e-mail to David Gill.
Test Type | Expected | Received | Failed
= = = = = = = = = = = = = = = = = = = = = = = = = = = =
Number of Tests : 19 18
Number of Builds : 48 46
Number of Simulations : 166 164 0
Number of Comparisons : 105 104 0
Failed Simulations are:
None
Which comparisons are not bit-for-bit:
None
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#1208 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEIZ77E7MMU3A6AZBYOHEYTRWDQVNANCNFSM4N27T2PA>
.
|
|
@dudhia @christopherthomas Christopher, Many of these have the associated "t" (time) variable that ALSO needs to be initialized at the beginning of each collection time. |
|
I only mean the t variables like tq2clmax. There's a few others.
…On Thu, Jun 11, 2020 at 9:44 AM Dave Gill ***@***.***> wrote:
@dudhia <https://github.com/dudhia> @christopherthomas
<https://github.com/christopherthomas>
Jimy,
Good point about other variables.
Christopher,
Here are the other variables in that list:
DO j = j_start(ij), j_end(ij)
DO i = i_start(ij), i_end(ij)
t2clmin(i,j)=t2(i,j)-t273
t2clmax(i,j)=t2(i,j)-t273
t2clmean(i,j)=t2(i,j)-t273
t2clstd(i,j)=(t2(i,j)-t273)*(t2(i,j)-t273)
q2clmin(i,j)=q2(i,j)
q2clmax(i,j)=q2(i,j)
q2clmean(i,j)=q2(i,j)
q2clstd(i,j)=q2(i,j)*q2(i,j)
spduv10clmax(i,j)=sqrt(u10(i,j)*u10(i,j)+v10(i,j)*v10(i,j))
u10clmean(i,j)=u10(i,j)
v10clmean(i,j)=v10(i,j)
spduv10clmean(i,j)=sqrt(u10(i,j)*u10(i,j)+v10(i,j)*v10(i,j))
u10clstd(i,j)=u10(i,j)*u10(i,j)
v10clstd(i,j)=v10(i,j)*v10(i,j)
spduv10clstd(i,j)=u10(i,j)*u10(i,j)+v10(i,j)*v10(i,j)
raincclmax(i,j)=raincv(i,j)/dt
rainncclmax(i,j)=rainncv(i,j)/dt
raincclmean(i,j)=raincv(i,j)/dt
rainncclmean(i,j)=rainncv(i,j)/dt
raincclstd(i,j)=(raincv(i,j)/dt)*(raincv(i,j)/dt)
rainncclstd(i,j)=(rainncv(i,j)/dt)*(rainncv(i,j)/dt)
skintempclmin(i,j)=skintemp(i,j)-t273
skintempclmax(i,j)=skintemp(i,j)-t273
skintempclmean(i,j)=skintemp(i,j)-t273
skintempclstd(i,j)=(skintemp(i,j)-t273)*(skintemp(i,j)-t273)
tt2clmin(i,j) = xtime + dt/60. ! value at end of timestep
tt2clmax(i,j) = xtime + dt/60.
ENDDO
ENDDO
Many of these have the associated "t" (time) variable that ALSO needs to
be initialized at the beginning of each collection time.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1208 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEIZ77EOEA4ICC5KYFZTQM3RWD3WTANCNFSM4N27T2PA>
.
|
|
@davegill
|
|
@christopherthomas @dudhia
|
|
TYPE: bug fix KEYWORDS: TT2MIN, TT2MAX, TQ2MIN, TQ2MAX, TSKINTEMPMIN, TSKINTEMPMAX, TRAINCVMAX, TRAINNCVMAX, TSPDUV10MAX SOURCE: Christopher Thomas (Climate Change Research Centre, UNSW Australia) DESCRIPTION OF CHANGES: ISSUE: LIST OF MODIFIED FILES: TESTS CONDUCTED: RELEASE NOTE: The calculation of TT2MIN, TT2MAX, TQ2MIN, TQ2MAX, TSKINTEMPMIN, TSKINTEMPMAX, TRAINCVMAX, TRAINNCVMAX and TSPDUV10MAX (times of extreme values of T2, Q2, SKINTEMP, RAINCV, RAINNCV and SPDUV10) within the clWRF diagnostics module was occasionally incorrect. At the beginning of each diagnostic period the working values of the extreme value variables (T2MIN, T2MAX, etc) are reinitialized with the current value of of the field (e.g. T2), however the working values of the time variables (TT2MAX, TT2MIN, etc) were not reinitialized with the current time value. Thus if the max or min actually occurred at the beginning of the diagnostic period, then these time variables would contain the value assigned to them in the previous period. |
|
@davegill |
Changes to be committed: modified: phys/module_diag_cl.F
|
@dudhia @weiwangncar @kkeene44 @smileMchen
|
|
@christopherthomas Do you happen to have a figure that shows the wrong output and one that shows the correct result? |
|
@weiwangncar |
I have included your figs in the PR commit message. The figs present a clear picture of what is happening. Thanks for providing them. |
|
@weiwangncar |
|
@christopherthomas Thanks for providing the plots. |
Wei, |

TYPE: bug fix
KEYWORDS: clWRF, maximum, minimum, time, diagnostics
SOURCE: Christopher Thomas (Climate Change Research Centre, UNSW Australia)
DESCRIPTION OF CHANGES:
TT2MAX and TT2MIN are the times at which T2MAX and T2MIN, the max and min values of
T2 within a diagnostic period, are achieved. This bug caused the incorrect computation of
TT2MAX and TT2MIN for cases in which T2MAX or T2MIN occurred at the beginning of the diagnostic period under consideration. At the beginning of each diagnostic period the working
values of T2MAX and T2MIN are reinitialized with the current value of T2, however the working
values of TT2MAX and TT2MIN were not reinitialized with the current time value. Thus if the
max or min actually occurred at the beginning of the diagnostic period, then TT2MAX or
TT2MIN would contain the value assigned to it in the previous period. The bug fix corrects
this by re-initializing TT2MAX and TT2MIN at the beginning of each diagnostic period.
The same initialization of the time of occurrence for the max/min of the 2-m temperature was
applied to these variables: tt2clmin, tt2clmax, tq2clmin, tq2clmax, tspduv10clmax,
traincclmax, trainncclmax, tskintempclmin, tskintempclmax.
ISSUE:
Closes #1193
LIST OF MODIFIED FILES:
M phys/module_diag_cl.F
TESTS CONDUCTED:
changes the TT2MAX and TT2MIN values only for those points/periods for which they were
incorrect, leaving all others unchanged. The values of TT2MAX and TT2MIN produced by the
fix are in agreement with those computed by outputting T2 for all times steps and calculating
TT2MAX and TT2MIN directly (using R). The tests were made using v4.1.2 but the file in
question (module_diag_cl.F) has not changed in v4.2.
24 hr period of simulation.
Left-hand panel = before fix
Right-hand panel = after fix
Values for TT2MAX should range between 1440 and 2880
Note speckling in region south of Australia, also isolated instances elsewhere. In this instance
nothing seems to occur over land but it clearly could. Bug only manifests if the extreme value
occurs at the beginning of the diagnostic period.
RELEASE NOTE: The calculation of the times of minimum and maximum of fields within the clWRF diagnostics module was occasionally incorrect. At the beginning of each diagnostic period the working values of diagnostic was correctly reinitialized with the current value; however the working values of occurrence of the time of the max/min values of the diagnostics were not reinitialized with the current time value. Thus if the max or min actually occurred at the beginning of the diagnostic period, then the reported time would incorrectly contain the value assigned during the previous output period.