Skip to content
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

Regional BC blending and BCs into GSI #16

Merged
merged 12 commits into from
Apr 8, 2020
Merged

Regional BC blending and BCs into GSI #16

merged 12 commits into from
Apr 8, 2020

Conversation

TomBlack-NOAA
Copy link

@TomBlack-NOAA TomBlack-NOAA commented Mar 12, 2020

do k=1, Atm(n)%npz
do j=lbound(Atm(n)%pt,2),ubound(Atm(n)%pt,2)
do i=lbound(Atm(n)%pt,1),ubound(Atm(n)%pt,1)
if(Atm(n)%pt(i,j,k)>400.)then
Copy link
Collaborator

@junwang-noaa junwang-noaa Apr 3, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be added later, but If we have bad Temperature >400, can we stop model from continue running (call mpp_error)?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you turn on the namelist "range_warn" the call to fv_diag will check the temperature for the data domain. An FMS "NOTE" will be emitted for temperatures outside the range of (150 - 350).

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove this block since I'm sure I put it there for debugging.

@@ -260,6 +311,7 @@ subroutine setup_regional_BC(Atm &
east_bc =.false.
west_bc =.false.
!
write(0,*)' enter setup_regional_BC isd=',isd,' ied=',ied,' jsd=',jsd,' jed=',jed
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We may want to comment this line or make it option whether to print out this line? This could be part of the job error file clean up work.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's just comment out the line. I know it's very valuable for dealing with some MPI-related problems so it's nice to have it sitting there.

@TomBlack-NOAA
Copy link
Author

TomBlack-NOAA commented Apr 3, 2020 via email

@TomBlack-NOAA
Copy link
Author

TomBlack-NOAA commented Apr 3, 2020 via email

Copy link
Collaborator

@bensonr bensonr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are the *_65lyrs and *_NAM_lyrs files test files from previous work? If so, please delete them from the merge. If they are necessary, please document the need for them.

do k=1, Atm(n)%npz
do j=lbound(Atm(n)%pt,2),ubound(Atm(n)%pt,2)
do i=lbound(Atm(n)%pt,1),ubound(Atm(n)%pt,1)
if(Atm(n)%pt(i,j,k)>400.)then
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you turn on the namelist "range_warn" the call to fv_diag will check the temperature for the data domain. An FMS "NOTE" will be emitted for temperatures outside the range of (150 - 350).

Comment on lines 2 to 18
!* GNU General Public License *
!* This file is a part of fvGFS. *
!* *
!* fvGFS is free software; you can redistribute it and/or modify it *
!* and are expected to follow the terms of the GNU General Public *
!* License as published by the Free Software Foundation; either *
!* version 2 of the License, or (at your option) any later version. *
!* *
!* fvGFS is distributed in the hope that it will be useful, but *
!* WITHOUT ANY WARRANTY; without even the implied warranty of *
!* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
!* General Public License for more details. *
!* *
!* For the full text of the GNU General Public License, *
!* write to: Free Software Foundation, Inc., *
!* 675 Mass Ave, Cambridge, MA 02139, USA. *
!* or see: http://www.gnu.org/licenses/gpl.html *
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This license header is outdated. The one being replaced is the correct version. Please fix and push a new udpate for this file.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll replace this with the new header.

Comment on lines 385 to 391
if(is_master()) then
write(0,10011)nrows_blend_user,nrows_blend_in_data
10011 format(' User wants to use ',i3,' blending rows but only ' &
,i3,' blending rows are in the BC file!')
write(0,*)' Aborting!!!'
endif
call abort()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please consider using the FMS error_msg function which when given the FATAL parameter will write an error message to the screen and abort gracefully.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will replace with call to mpp_error.

endif
regional_bc_bounds%je_east_uvs=jed+1
if(south_bc)then
regional_bc_bounds%je_east_uvs=jed-nhalo_model+1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All other uses of nhalo_model have been modified to include nrows_blend in some fashion. Should this one be modified in a similar fashion?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is okay. It is on the east side so the I index must include blending rows extending into the integration domain. Blending on the east side (and west side) is irrelevant to the J dimension.

!
! write(0,*)' opened grid file',trim(filename)
write(0,*)' opened grid file ',trim(filename)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please consider using the standard FMS error_msg function with the NOTE parameter for output of this nature.

Comment on lines 3139 to 3140
! write(0,66811)is_0,ie_0,js_0,je_0
66811 format(' allocated delp_BC(',i3,':',i3,',',i3,':',i3,')')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a debug message that is no longer needed?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most likely. I'll remove it.

Comment on lines 4362 to 4364
write(0,101)
101 format(' iq<1 is not a valid index for q_BC array in retrieve_bc_variable_data')
call abort()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please consider using FMS error_msg with the FATAL parameter to output the message and cleanly abort the model.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will replace with mpp_error.

Comment on lines 845 to 852
! else
! if ( npz <= 64 ) then
! Atm(n)%ak(:) = ak_sj(:)
! Atm(n)%bk(:) = bk_sj(:)
! Atm(n)%ptop = Atm(n)%ak(1)
! else
! call set_eta(npz, ks, Atm(n)%ptop, Atm(n)%ak, Atm(n)%bk)
! endif
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do these lines need to be kept for documentation purposes or can they be removed?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think they can be removed.

tools/fv_eta.F90 Outdated
Comment on lines 756 to 799
! data a60/ 1.7861000000e-01, 1.0805100000e+00, 3.9647100000e+00, &
! 9.7516000000e+00, 1.9816580000e+01, 3.6695950000e+01, &
! 6.2550570000e+01, 9.9199620000e+01, 1.4792505000e+02, &
! 2.0947487000e+02, 2.8422571000e+02, 3.7241721000e+02, &
! 4.7437835000e+02, 5.9070236000e+02, 7.2236063000e+02, &
! 8.7076746000e+02, 1.0378138800e+03, 1.2258877300e+03, &
! 1.4378924600e+03, 1.6772726600e+03, 1.9480506400e+03, &
! 2.2548762700e+03, 2.6030909400e+03, 2.9988059200e+03, &
! 3.4489952300e+03, 3.9616028900e+03, 4.5456641600e+03, &
! 5.2114401700e+03, 5.9705644000e+03, 6.8361981800e+03, &
! 7.8231906000e+03, 8.9482351000e+03, 1.0230010660e+04, &
! 1.1689289750e+04, 1.3348986860e+04, 1.5234111060e+04, &
! 1.7371573230e+04, 1.9789784580e+04, 2.2005564550e+04, &
! 2.3550115120e+04, 2.4468583320e+04, 2.4800548800e+04, &
! 2.4582445070e+04, 2.3849999620e+04, 2.2640519740e+04, &
! 2.0994737150e+04, 1.8957848730e+04, 1.6579413230e+04, &
! 1.4080071030e+04, 1.1753630920e+04, 9.6516996300e+03, &
! 7.7938009300e+03, 6.1769062800e+03, 4.7874276000e+03, &
! 3.6050497500e+03, 2.6059860700e+03, 1.7668328200e+03, &
! 1.0656131200e+03, 4.8226201000e+02, 0.0000000000e+00, &
! 0.0000000000e+00 /


! data b60/ 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 0.0000000000e+00, &
! 0.0000000000e+00, 0.0000000000e+00, 5.0600000000e-03, &
! 2.0080000000e-02, 4.4900000000e-02, 7.9360000000e-02, &
! 1.2326000000e-01, 1.7634000000e-01, 2.3820000000e-01, &
! 3.0827000000e-01, 3.8581000000e-01, 4.6989000000e-01, &
! 5.5393000000e-01, 6.2958000000e-01, 6.9642000000e-01, &
! 7.5458000000e-01, 8.0463000000e-01, 8.4728000000e-01, &
! 8.8335000000e-01, 9.1368000000e-01, 9.3905000000e-01, &
! 9.6020000000e-01, 9.7775000000e-01, 9.9223000000e-01, &
! 1.0000000000e+00 /
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should there be an #ifdef/#else/#endif around this and the NAM level definition below to make it easier to switch back and forth between the two definitions for 60 levels?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe these should be removed.

tools/fv_eta.F90 Outdated
Comment on lines 1347 to 1348
! ks = 37
ks = 19
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as the comment above regarding #ifdef.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Likewise, let's remove it.

Copy link
Collaborator

@bensonr bensonr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I approve the changes.

@DusanJovic-NOAA DusanJovic-NOAA merged commit 80ce8ce into NOAA-EMC:dev/emc Apr 8, 2020
@TomBlack-NOAA TomBlack-NOAA deleted the blend_DA branch April 28, 2020 12:36
XiaqiongZhou-NOAA pushed a commit to XiaqiongZhou-NOAA/GFDL_atmos_cubed_sphere that referenced this pull request Jun 11, 2020
* add option to output omega

*     VLab Issue #68141

    modified:   docs/FV3_citations.bib
    modified:   model/fv_cmp.F90

    1) Add an option (namelist parameter: intqs) to use temperature instead of the liquid frozen
    temperature to calculate saturation mixing ratio in deriving GFDLMP PDF cloud cover.
    2) Add a literature reference.

* Update fv_cmp.F90 to remove a bug introduced in last update.

* change delz from positive value to the original value in the model

* Remove TRANSITION mode

* added documentation for parameter list

* Merging https://github.com/valbonakunkel-noaa/GFDL_atmos_cubed_sphere, branch dev/emc, into ufs_public_release. Squashed commit of the following:

commit 5f7a981
Author: Valbona Kunkel <valbona.kunkel@noaa.gov>
Date:   Wed Jan 22 18:35:10 2020 -0500

    Added to parameters list 4 new parameters

commit 62a32e1
Author: Valbona Kunkel <valbona.kunkel@noaa.gov>
Date:   Tue Dec 17 14:38:28 2019 -0500

    added Doxygen files

commit af03053
Author: Valbona Kunkel <valbona.kunkel@noaa.gov>
Date:   Wed Oct 23 15:11:57 2019 -0400

    corrected parameter list

commit 47bdb2d
Author: Valbona Kunkel <valbona.kunkel@noaa.gov>
Date:   Thu Oct 10 15:20:26 2019 -0400

    add list description of parameters

Co-authored-by: Fanglin Yang <fanglin.yang@noaa.gov>
Co-authored-by: Dusan Jovic <48258889+DusanJovic-NOAA@users.noreply.github.com>
Co-authored-by: Dom Heinzeller <dom.heinzeller@icloud.com>
Co-authored-by: valbonakunkel-noaa <36248012+valbonakunkel-noaa@users.noreply.github.com>
XiaqiongZhou-NOAA pushed a commit to XiaqiongZhou-NOAA/GFDL_atmos_cubed_sphere that referenced this pull request Sep 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants