Skip to content

Commit

Permalink
Merge CICE-Consortium/main and resolve conflicts (June 2024)
Browse files Browse the repository at this point in the history
  • Loading branch information
NickSzapiro-NOAA committed Jun 28, 2024
1 parent 9452de8 commit 8a942e7
Show file tree
Hide file tree
Showing 59 changed files with 1,317 additions and 1,156 deletions.
Binary file modified LICENSE.pdf
Binary file not shown.
10 changes: 5 additions & 5 deletions cice.setup
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ EOF
set thrd = `echo ${pesx} | cut -d x -f 2`
set blckx = `echo ${pesx} | cut -d x -f 3`
set blcky = `echo ${pesx} | cut -d x -f 4`
set mblck = 0
set mblck = -1
if (${task} == 0 || ${thrd} == 0 || ${blckx} == 0 || ${blcky} == 0) then
echo "${0}: ERROR in -p argument, cannot have zeros"
exit -1
Expand All @@ -696,7 +696,7 @@ EOF
set thrd = `echo ${pesx} | cut -d x -f 2`
set blckx = 0
set blcky = 0
set mblck = 0
set mblck = -1
if (${task} == 0 || ${thrd} == 0) then
echo "${0}: ERROR in -p argument, cannot have zeros"
exit -1
Expand All @@ -708,7 +708,7 @@ EOF
set thrd = 1
set blckx = 0
set blcky = 0
set mblck = 0
set mblck = -1
if (${task} == 0) then
echo "${0}: ERROR in -p argument, cannot have zeros"
exit -1
Expand Down Expand Up @@ -757,7 +757,7 @@ EOF
# update pesx based on use defined settings and machine limits to reflect actual value
set pesx = ${task}x${thrd}x${blckx}x${blcky}x${mblck}
if (${mblck} == 0) then
if (${mblck} <= 0) then
set pesx = ${task}x${thrd}x${blckx}x${blcky}
endif
if (${blckx} == 0 || ${blcky} == 0) then
Expand Down Expand Up @@ -838,7 +838,7 @@ EOF
endif
# from basic script dir to case
foreach file (cice.build cice.settings Makefile ice_in makdep.c setup_run_dirs.csh timeseries.csh timeseries.py)
foreach file (cice.build cice.settings Makefile ice_in makdep.c setup_run_dirs.csh ciceplots.csh ciceplots2d.py timeseries.py)
if !(-e ${ICE_SCRIPTS}/$file) then
echo "${0}: ERROR, ${ICE_SCRIPTS}/$file not found"
exit -1
Expand Down
2 changes: 1 addition & 1 deletion cicecore/cicedyn/dynamics/ice_dyn_core1d.F90
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
!===============================================================================
! Copyright (C) 2023, Intel Corporation
! Copyright (C) 2024, Intel Corporation
! Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
! 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
! 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
Expand Down
12 changes: 6 additions & 6 deletions cicecore/cicedyn/dynamics/ice_dyn_evp.F90
Original file line number Diff line number Diff line change
Expand Up @@ -718,8 +718,8 @@ subroutine evp (dt)
field_loc_Eface, field_type_vector)
call ice_timer_stop(timer_bound)

call grid_average_X2Y('S', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('S', vvelN, 'N', vvel, 'U')
call grid_average_X2Y('A', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('A', vvelN, 'N', vvel, 'U')
uvel(:,:,:) = uvel(:,:,:)*uvm(:,:,:)
vvel(:,:,:) = vvel(:,:,:)*uvm(:,:,:)
endif
Expand Down Expand Up @@ -1084,8 +1084,8 @@ subroutine evp (dt)
field_loc_Eface, field_type_vector, &
vvelE)

call grid_average_X2Y('S', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('S', vvelN, 'N', vvel, 'U')
call grid_average_X2Y('A', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('A', vvelN, 'N', vvel, 'U')

uvel(:,:,:) = uvel(:,:,:)*uvm(:,:,:)
vvel(:,:,:) = vvel(:,:,:)*uvm(:,:,:)
Expand Down Expand Up @@ -1275,8 +1275,8 @@ subroutine evp (dt)
field_loc_Nface, field_type_vector, &
uvelN, vvelN)

call grid_average_X2Y('S', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('S', vvelN, 'N', vvel, 'U')
call grid_average_X2Y('A', uvelE, 'E', uvel, 'U')
call grid_average_X2Y('A', vvelN, 'N', vvel, 'U')

uvel(:,:,:) = uvel(:,:,:)*uvm(:,:,:)
vvel(:,:,:) = vvel(:,:,:)*uvm(:,:,:)
Expand Down
3 changes: 3 additions & 0 deletions cicecore/cicedyn/general/ice_forcing.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2276,6 +2276,9 @@ subroutine JRA55_files(yr)
enddo

if (.not.exists) then
write(nu_diag,*) subname,' atm_data_dir = ',trim(atm_data_dir)
write(nu_diag,*) subname,' atm_data_type_prefix = ',trim(atm_data_type_prefix)
write(nu_diag,*) subname,' atm_data_version = ',trim(atm_data_version)
call abort_ice(error_message=subname//' could not find forcing file')
endif

Expand Down
36 changes: 18 additions & 18 deletions cicecore/cicedyn/infrastructure/comm/mpi/ice_gather_scatter.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1836,12 +1836,12 @@ subroutine scatter_global_dbl(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) == my_task+1 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand All @@ -1867,8 +1867,8 @@ subroutine scatter_global_dbl(ARRAY, ARRAY_G, src_task, dst_dist, &
enddo
enddo

endif
enddo
endif
enddo
endif

if (add_mpi_barriers) then
Expand Down Expand Up @@ -2222,12 +2222,12 @@ subroutine scatter_global_real(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) == my_task+1 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand All @@ -2253,8 +2253,8 @@ subroutine scatter_global_real(ARRAY, ARRAY_G, src_task, dst_dist, &
enddo
enddo

endif
enddo
endif
enddo
endif

if (add_mpi_barriers) then
Expand Down Expand Up @@ -2608,12 +2608,12 @@ subroutine scatter_global_int(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) == my_task+1 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand All @@ -2639,8 +2639,8 @@ subroutine scatter_global_int(ARRAY, ARRAY_G, src_task, dst_dist, &
enddo
enddo

endif
enddo
endif
enddo
endif

if (add_mpi_barriers) then
Expand Down
32 changes: 16 additions & 16 deletions cicecore/cicedyn/infrastructure/comm/serial/ice_gather_scatter.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1002,12 +1002,12 @@ subroutine scatter_global_dbl(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) /= 0 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand All @@ -1033,8 +1033,8 @@ subroutine scatter_global_dbl(ARRAY, ARRAY_G, src_task, dst_dist, &
enddo
enddo

endif
enddo
endif
enddo
endif

!-----------------------------------------------------------------------
Expand Down Expand Up @@ -1250,12 +1250,12 @@ subroutine scatter_global_real(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) /= 0 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand All @@ -1281,8 +1281,8 @@ subroutine scatter_global_real(ARRAY, ARRAY_G, src_task, dst_dist, &
enddo
enddo

endif
enddo
endif
enddo
endif

!-----------------------------------------------------------------------
Expand Down Expand Up @@ -1498,12 +1498,12 @@ subroutine scatter_global_int(ARRAY, ARRAY_G, src_task, dst_dist, &
!-----------------------------------------------------------------

if (field_loc == field_loc_noupdate) then
do n=1,nblocks_tot
do n=1,nblocks_tot
if (dst_dist%blockLocation(n) /= 0 .and. &
dst_dist%blockLocalID(n) > 0) then

dst_block = dst_dist%blockLocalID(n)
this_block = get_block(n,n)

if (dst_block > 0) then

! north edge
do j = this_block%jhi+1,ny_block
do i = 1, nx_block
Expand Down
Loading

0 comments on commit 8a942e7

Please sign in to comment.