s_albani@cornell_edu
New Member
Hi!I have a problem while trying to add a new variable to be passed form the land to the atmopshere through the coupler. I am currently using CESM 1.0.5, B2000CN compset.
The new variable is calculated in clm, and I tried to mimic what is done in the release code for "fv" or "ram1".In the coupler, I have added the "l2x" and "x2a" fields in seq_fld_indices.F90 and the "Sl" field in seq_flds_mod.F90, the latter passage by also increasing the size of the "lookup" array from 246 to 247 and adding the new field in the last position at lookup(247,*).I have also edited the associated land component scripts, by defining the "l2x" field in clm_cpl_indices.F90.The new variable is associated to a pointer, defined in clmtype.F90 and allocated in clmtypeInitMod.F90. The pointer is of the form => clm3%g%l%c%p%pps%
The "l2a" field is allocated in clm_atmlnd.F90 and "l2a" is associated to "l2x" in lnd_comp_mct.F90.For the moment the new variable is defined as =fv, (the friction velocity) just to make sure the changes work.
The corresponding steps were made in the cam scripts as well.The model builds and seems to be initialized properly, but fails during the first time step.The part of code where it crashes (identified by flagging the log files) is in ccsm_comp_mod.F90, during the execution of:
"call map_lndl2lndx_mct( cdata_ll, l2x_ll, cdata_lx, l2x_lx) "
!----------------------------------------------------------
! lnd -> cpl
!---------------------------------------------------------- if ((lnd_present.or.rof_present.or.sno_present) .and. lndrun_alarm) then write(logunit,F00) 'SAMUEL lnd -> cpl' !albani
if (iamin_CPLLNDID) then
call t_drvstartf ('DRIVER_L2C',barrier=mpicom_CPLLNDID)
if (lnd_present) then
call t_drvstartf ('driver_l2c_lndl2lndx',barrier=mpicom_CPLLNDID)
call map_lndl2lndx_mct( cdata_ll, l2x_ll, cdata_lx, l2x_lx)
call t_drvstopf ('driver_l2c_lndl2lndx')
endifThe end of lnd.log says:
Successfully read monthly vegetation data for
month 1 dtime_sync= 1800 dtime_clm= 1800 mod = 0
(lnd_init_mct) :Atmospheric input is from a prognostic modelThe cpl.log:
(seq_mct_drv) : Setting fractions
(seq_mct_drv) : Initializing atm/ocn flux component
(seq_mct_drv) : Calling map_lnd2atm_mct
(seq_mct_drv) : Calling map_ocn2atm_mct for mapping o2x_ox to o2x_ax
(seq_mct_drv) : Calling map_ocn2atm_mct for mapping xao_ox to xao_ax
(seq_mct_drv) : Calling map_ice2atm_mct for mapping i2x_ix to i2x_ax
(seq_mct_drv) : Calling mrg_x2a_run_mct
(seq_mct_drv) : Calling atm_init_mct(seq_mct_drv) : Model initialization complete(map_npFixNew4R) compute bilinear weights & indicies for NP region.
(map_npFixNew4R) total npfix points found = 0The first error in the ccsm.log appears here:INFO: 0031-251 task 199 exited: rc=-11
INFO: 0031-251 task 197 exited: rc=-11
339:forrtl: error (78): process killed (SIGTERM)
339:Image PC Routine Line Source
339:libpthread.so.0 00002B40F018E245 Unknown Unknown Unknown
339:libpoe.so 00002B40F8462AE2 Unknown Unknown Unknown
339:libpthread.so.0 00002B40F01867F1 Unknown Unknown Unknown
339:libc.so.6 00002B40F090D70D Unknown Unknown Unknown
339:INFO: 0031-306 pm_atexit: pm_exit_value is 1.Does anybody have an idea of what the problem could be?
Thanks!
The new variable is calculated in clm, and I tried to mimic what is done in the release code for "fv" or "ram1".In the coupler, I have added the "l2x" and "x2a" fields in seq_fld_indices.F90 and the "Sl" field in seq_flds_mod.F90, the latter passage by also increasing the size of the "lookup" array from 246 to 247 and adding the new field in the last position at lookup(247,*).I have also edited the associated land component scripts, by defining the "l2x" field in clm_cpl_indices.F90.The new variable is associated to a pointer, defined in clmtype.F90 and allocated in clmtypeInitMod.F90. The pointer is of the form => clm3%g%l%c%p%pps%
The "l2a" field is allocated in clm_atmlnd.F90 and "l2a" is associated to "l2x" in lnd_comp_mct.F90.For the moment the new variable is defined as =fv, (the friction velocity) just to make sure the changes work.
The corresponding steps were made in the cam scripts as well.The model builds and seems to be initialized properly, but fails during the first time step.The part of code where it crashes (identified by flagging the log files) is in ccsm_comp_mod.F90, during the execution of:
"call map_lndl2lndx_mct( cdata_ll, l2x_ll, cdata_lx, l2x_lx) "
!----------------------------------------------------------
! lnd -> cpl
!---------------------------------------------------------- if ((lnd_present.or.rof_present.or.sno_present) .and. lndrun_alarm) then write(logunit,F00) 'SAMUEL lnd -> cpl' !albani
if (iamin_CPLLNDID) then
call t_drvstartf ('DRIVER_L2C',barrier=mpicom_CPLLNDID)
if (lnd_present) then
call t_drvstartf ('driver_l2c_lndl2lndx',barrier=mpicom_CPLLNDID)
call map_lndl2lndx_mct( cdata_ll, l2x_ll, cdata_lx, l2x_lx)
call t_drvstopf ('driver_l2c_lndl2lndx')
endifThe end of lnd.log says:
Successfully read monthly vegetation data for
month 1 dtime_sync= 1800 dtime_clm= 1800 mod = 0
(lnd_init_mct) :Atmospheric input is from a prognostic modelThe cpl.log:
(seq_mct_drv) : Setting fractions
(seq_mct_drv) : Initializing atm/ocn flux component
(seq_mct_drv) : Calling map_lnd2atm_mct
(seq_mct_drv) : Calling map_ocn2atm_mct for mapping o2x_ox to o2x_ax
(seq_mct_drv) : Calling map_ocn2atm_mct for mapping xao_ox to xao_ax
(seq_mct_drv) : Calling map_ice2atm_mct for mapping i2x_ix to i2x_ax
(seq_mct_drv) : Calling mrg_x2a_run_mct
(seq_mct_drv) : Calling atm_init_mct(seq_mct_drv) : Model initialization complete(map_npFixNew4R) compute bilinear weights & indicies for NP region.
(map_npFixNew4R) total npfix points found = 0The first error in the ccsm.log appears here:INFO: 0031-251 task 199 exited: rc=-11
INFO: 0031-251 task 197 exited: rc=-11
339:forrtl: error (78): process killed (SIGTERM)
339:Image PC Routine Line Source
339:libpthread.so.0 00002B40F018E245 Unknown Unknown Unknown
339:libpoe.so 00002B40F8462AE2 Unknown Unknown Unknown
339:libpthread.so.0 00002B40F01867F1 Unknown Unknown Unknown
339:libc.so.6 00002B40F090D70D Unknown Unknown Unknown
339:INFO: 0031-306 pm_atexit: pm_exit_value is 1.Does anybody have an idea of what the problem could be?
Thanks!