You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ps_reg variable in fv_regional_bc.F90 is initialized to -9999999 Pa, which propagates throughout the model. All other boundary arrays were initialized to signalling NaN. Not initializing this one to signalling NaN masked many other bugs.
These are some of the bugs it masked inside the GFDL_atmos_cubed_sphere repository; there are others outside it:
Remapping winds does a two point average of the current point and -9999999.
Remapping winds uses -9999999 as pressure on velocity boundary points beyond the scalar boundary points.
The -9999999 is copied to Atm%ps throughout the domain, beyond the boundary, on all processors that touch the domain boundary.
Due to item 3, the RRFS hasn't been able to run in DEBUG=ON mode since this bug was introduced.
The pressure data is not read in on velocity points outside the scalar boundary. (It can't be, since the the boundary condition files lack that data entirely.)
The blending code blends data beyond boundary regions.
The code accesses i-1 and j-1 indices, but processes the south boundary before the east and west boundary. That means two south boundary processes are accessing uninitialized regions instead of the east and west boundary.
There are other issues, outside the dynamical core, which were masked by this bug. I'll link to those issues once I create or find them.
It should also be noted that many users have found dubious values the model receives from the boundary conditions. These bugs may be the cause. However, we'll have to run parallels of multiple configurations to confirm that.
To Reproduce
Read the code and find the ps_reg=-9999999
Replace that with ps_reg=real_snan
Compile in DEBUG=ON mode.
Run it and see the bugs.
Fix the bugs one by one and see more appear.
Expected behavior
Boundary data should be correct.
The boundary code should not write to non-boundary regions within the domain.
Blending code should not blend data beyond the domain boundary.
The best practice of initializing to real_snan should be followed.
The code should pass in DEBUG=ON
Changing the threads, layout, or task count, should not change the results.
System Environment
The ufs-weather-model build system targets hera.intel and hera.gnu, which use:
OS: CentOS 7.9.2009
Compiler(s): Intel 2022.1.2 and GCC 9.2.0
MPI type, and version: Intel MPI using the SLURM srun launcher
netCDF Version: 4.7.4
Configure options: cmake option "-DDEBUG=ON"
Additional context
None.
The text was updated successfully, but these errors were encountered:
SamuelTrahanNOAA
changed the title
uninitialized, and incorrectly initialized, memory in fv_regional_bc.F90
uninitialized or incorrectly initialized memory in fv_regional_bc.F90
Sep 22, 2022
Describe the bug
The ps_reg variable in fv_regional_bc.F90 is initialized to -9999999 Pa, which propagates throughout the model. All other boundary arrays were initialized to signalling NaN. Not initializing this one to signalling NaN masked many other bugs.
These are some of the bugs it masked inside the GFDL_atmos_cubed_sphere repository; there are others outside it:
There are other issues, outside the dynamical core, which were masked by this bug. I'll link to those issues once I create or find them.
It should also be noted that many users have found dubious values the model receives from the boundary conditions. These bugs may be the cause. However, we'll have to run parallels of multiple configurations to confirm that.
To Reproduce
Expected behavior
System Environment
The ufs-weather-model build system targets hera.intel and hera.gnu, which use:
Additional context
None.
The text was updated successfully, but these errors were encountered: