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

initialize mytask and master_task here #61

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion drivers/nuopc/ocn_import_export.F90
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ subroutine ocn_advertise_fields(gcomp, importState, exportState, flds_scalar_nam
integer , intent(out) :: rc

! local variables
type(ESMF_VM) :: vm
integer :: n
character(CS) :: stdname
character(CS) :: cvalue
Expand All @@ -137,10 +138,16 @@ subroutine ocn_advertise_fields(gcomp, importState, exportState, flds_scalar_nam

if (dbug > 5) call ESMF_LogWrite(subname//' called', ESMF_LOGMSG_INFO)

! pop has not yet initialized my_task and master_task so do it here
master_task = 0
call ESMF_GridCompGet(gcomp, vm=vm, rc=rc)
if (ChkErr(rc,__LINE__,u_FILE_u)) return
call ESMF_VMGet(vm, localPet=my_task, rc=rc)
if (ChkErr(rc,__LINE__,u_FILE_u)) return

!-----------------
! optional input from cice columns due to ice thickness categories
!-----------------

! Note that flds_i2o_per_cat is set by the env_run.xml variable CPL_I2O_PER_CAT
! This xml variable is set by the POP build-namelist
call NUOPC_CompAttributeGet(gcomp, name='flds_i2o_per_cat', value=cvalue, rc=rc)
Expand Down