Skip to content

Commit

Permalink
updates go mosart master
Browse files Browse the repository at this point in the history
  • Loading branch information
Mariana Vertenstein committed Jun 7, 2024
2 parents 410b04a + 5acf6b2 commit c62e82b
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 7 deletions.
4 changes: 2 additions & 2 deletions cime_config/testdefs/testlist_mosart.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@
</test>
<test name="SMS_D_Ld5" grid="f10_f10_mg37" compset="I1850Clm50Bgc" testmods="mosart/default">
<machines>
<machine name="betzy" compiler="intel" category="mosart"></machine>
<machine name="izumi" compiler="nag" category="mosart_noresm"></machine>
<machine name="betzy" compiler="intel" category="mosart_noresm"></machine>
<machine name="izumi" compiler="nag" category="mosart"></machine>
</machines>
<options>
<option name="wallclock">00:20:00</option>
Expand Down
2 changes: 1 addition & 1 deletion cime_config/user_nl_mosart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
!----------------------------------------------------------------------------------
! Users should add all user specific namelist changes below in the form of
! namelist_var = new_namelist_value
! NOTE: namelist variable rtm_tstep CAN ONLY be changed by modifying the value
! NOTE: namelist variable delt_mosart (the time-step) CAN ONLY be changed by modifying the value
! of the xml variable ROF_NCPL in env_run.xml
!----------------------------------------------------------------------------------

Expand Down
48 changes: 48 additions & 0 deletions docs/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,51 @@
===============================================================
Tag name: mosart1_1_01
Originator(s): mvertens
Date: Jun 06, 2024
One-line Summary: major mosart refactor including addition of new halo capability

Removed all references to rtm

files have been renamed and namelists no longer contain rtm in the name

New modularity:

introduced new modules with new derived types and methods
mosart_control_type.F90
mosart_tctl_type.F90
mosart_tparameter_type.F90
mosart_tspatialunit_type.F90
mosart_tstatusflux_type.F90

the new modules modularize a lot of the complexity and variables that were previously found in RunOffMod.F90 and permit decomposition initialization to be more flexible and transparent.

New halo capability

Ability to have halo regions and communication using ESMF. This is needed for computing derivatives in upcoming new additions to MOSART.
New halo namelist - use_halo_option. When this is set to true halos can be activated. See the test_halo subroutine in mosart_control_type.F90 module.
Verified that the results for the halos are bfb identical regardless of the number of processors that are used.
-To set the values for the exclusive region that will be used in halo operations - you need to access the pointer as is done in the test_halo routine in mosart_control_type.F90:
n = 0
do nr = this%begr,this%endr
n = n + 1
this%halo_arrayptr(n) = this%latc(nr)*10. + this%lonc(nr)/100.
end do

call ESMF_ArrayHalo(this%haloArray, routehandle=this%haloHandle, rc=rc)
if (chkerr(rc,__LINE__,u_FILE_u)) return

Issues addressed:
Fixes #93 "if (ierr /= PIO_NOERR)" will not be invoked unless PIO_BCAST_ERROR is explicitly set
Fixes #98 Change namelist items to remove "rtm" in the names of namelist variables
Fixes #97 Remove RTM in more of the MOSART code (filenames, subroutines, variables etc.)
Fixes #99 Add a new mosart_noresm testlist

Testing: standard testing
izumi -- OK
cheyenne -- OK

See https://github.com/ESCOMP/MOSART/pull/76 for more details

===============================================================
Tag name: mosart1_0_49
Originator(s): mvertens
Expand Down
6 changes: 2 additions & 4 deletions src/riverroute/mosart_control_type.F90
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
module mosart_control_type

use shr_kind_mod, only : r8 => shr_kind_r8, CL => SHR_KIND_CL, CS => SHR_KIND_CS
use shr_kind_mod, only : r8 => shr_kind_r8, CS => shr_kind_cs
use shr_sys_mod, only : shr_sys_abort
use shr_const_mod, only : shr_const_pi, shr_const_rearth
use shr_string_mod, only : shr_string_listGetNum, shr_string_listGetName
use shr_mpi_mod, only : shr_mpi_sum, shr_mpi_max
use shr_mpi_mod, only : shr_mpi_sum
use mosart_io, only : ncd_io, ncd_pio_openfile, ncd_pio_closefile
use mosart_vars, only : mainproc, iam, npes, mpicom_rof, iulog, spval, re
use pio, only : file_desc_t, PIO_BCAST_ERROR, pio_seterrorhandling
Expand Down Expand Up @@ -472,7 +471,6 @@ subroutine init_decomp(this, locfn, decomp_option, use_halo_option, &
integer, pointer :: halo_list(:)
integer, pointer :: seqlist(:)
integer, allocatable :: store_halo_index(:)
integer :: nglob
character(len=*),parameter :: subname = '(mosart_control_type: init_decomp) '
!-----------------------------------------------------------------------

Expand Down

0 comments on commit c62e82b

Please sign in to comment.