Changeset 11901 for NEMO/branches
- Timestamp:
- 2019-11-13T18:27:42+01:00 (5 years ago)
- Location:
- NEMO/branches/2019/dev_r11756_SI3restart_XIOS
- Files:
-
- 8 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/cfgs/AGRIF_DEMO/EXPREF/iodef.xml
r9770 r11901 26 26 <context id="2_nemo" src="./2_context_nemo.xml"/> <!-- NEMO --> 27 27 <context id="3_nemo" src="./3_context_nemo.xml"/> <!-- NEMO --> 28 <context id="nemo_rstw" src="./nemo_rstw.xml"/> <!-- NEMO RESTART --> 29 <context id="1_nemo_rstw" src="./1_nemo_rstw.xml"/> <!-- NEMO RESTART --> 30 <context id="2_nemo_rstw" src="./2_nemo_rstw.xml"/> <!-- NEMO RESTART --> 31 <context id="3_nemo_rstw" src="./3_nemo_rstw.xml"/> <!-- NEMO RESTART --> 32 <context id="si3_rst" src="./si3_rst.xml"/> <!-- SI3 restart --> 33 <context id="1_si3_rst" src="./1_si3_rst.xml"/> <!-- SI3 restart --> 34 <context id="2_si3_rst" src="./2_si3_rst.xml"/> <!-- SI3 restart --> 35 <context id="3_si3_rst" src="./3_si3_rst.xml"/> <!-- SI3 restart --> 28 36 </simulation> -
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/src/ICE/icerst.F90
r11893 r11901 220 220 IF(lrxios) THEN 221 221 crixios_context = 'si3_rst' 222 CALL iom_init( crixios_context, TRIM(cn_icerst_indir)//'/'//cn_icerst_in, ld_tmppatch = .false. )223 222 lxios_set = .TRUE. 223 IF( TRIM(Agrif_CFixed()) /= '0') THEN 224 IF(lwp) WRITE(numout,*) 'Enable SI3 restart reading by XIOS for AGRIF' 225 CALL iom_init( crixios_context, & 226 TRIM(cn_icerst_indir)//'/'//TRIM(Agrif_CFixed())//"_"//cn_icerst_in, ld_tmppatch = .false. ) 227 ELSE 228 IF(lwp) WRITE(numout,*) 'Enable SI3 restart reading by XIOS for AGRIF' 229 CALL iom_init( crixios_context, TRIM(cn_icerst_indir)//'/'//cn_icerst_in, ld_tmppatch = .false. ) 230 ENDIF 224 231 ENDIF 225 232 -
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/src/OCE/DOM/domain.F90
r11840 r11901 344 344 WRITE(numout,*) ' NetCDF chunksize (bytes) nn_chunksz = ', nn_chunksz 345 345 WRITE(numout,*) ' IS coupling at the restart step ln_iscpl = ', ln_iscpl 346 IF( TRIM(Agrif_CFixed()) == '0' ) THEN 347 WRITE(numout,*) ' READ restart for a single file using XIOS ln_xios_read =', ln_xios_read 348 WRITE(numout,*) ' Write restart using XIOS nn_wxios = ', nn_wxios 349 ELSE 350 WRITE(numout,*) " AGRIF: nn_wxios will be ingored. See setting for parent" 351 WRITE(numout,*) " AGRIF: ln_xios_read will be ingored. See setting for parent" 352 ENDIF 346 WRITE(numout,*) ' READ restart for a single file using XIOS ln_xios_read =', ln_xios_read 347 WRITE(numout,*) ' Write restart using XIOS nn_wxios = ', nn_wxios 353 348 ENDIF 354 349 … … 427 422 rdt = rn_rdt 428 423 429 IF( TRIM(Agrif_CFixed()) == '0' ) THEN 430 lrxios = ln_xios_read.AND.ln_rstart 424 lrxios = ln_xios_read.AND.ln_rstart 431 425 !set output file type for XIOS based on NEMO namelist 432 IF (nn_wxios > 0) lwxios = .TRUE. 433 nxioso = nn_wxios 434 ENDIF 426 IF (nn_wxios > 0) lwxios = .TRUE. 427 nxioso = nn_wxios 435 428 436 429 #if defined key_netcdf4 -
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/src/OCE/IOM/iom.F90
r11893 r11901 309 309 ! create the file 310 310 clname = TRIM(cexper)//"_"//TRIM(ADJUSTL(clkt))//"_"//TRIM(cn_ocerst_out) 311 !handle AGRIF 312 IF ( .NOT. Agrif_Root() ) clname=TRIM(Agrif_CFixed())//'_'//TRIM(clname) 313 311 314 clpath = TRIM(cn_ocerst_outdir) 312 315 IF( clpath(LEN_TRIM(clpath):) /= '/' ) clpath = TRIM(clpath) // '/' 313 316 IF(lwp) THEN 314 write(numout, *) 'Create restart file atthe step: ', kt317 write(numout, *) 'Create restart file for the step: ', kt 315 318 ENDIF 316 319 CALL iom_set_rstw_active(rst_wfields, TRIM(clpath)//TRIM(clname), nitrstx) … … 327 330 ! create the file 328 331 clname = TRIM(cexper)//"_"//TRIM(ADJUSTL(clkt))//"_"//TRIM(cn_icerst_out) 332 !handle AGRIF 333 IF ( .NOT. Agrif_Root() ) clname=TRIM(Agrif_CFixed())//'_'//TRIM(clname) 334 329 335 clpath = TRIM(cn_icerst_outdir) 330 336 IF( clpath(LEN_TRIM(clpath):) /= '/' ) clpath = TRIM(clpath)//'/' … … 438 444 439 445 !set name of the restart file and enable available fields 440 if(lwp) WRITE(numout,*) 'Setting restart filename (for XIOS) to: ', rst_file446 if(lwp) WRITE(numout,*) 'Setting restart filename (for XIOS) to: ', TRIM(rst_file) 441 447 CALL xios_get_handle("file_definition", filegroup_hdl ) 442 448 CALL xios_add_child(filegroup_hdl, file_hdl, 'rrestart') -
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/src/OCE/IOM/iom_def.F90
r11893 r11901 35 35 INTEGER, PARAMETER, PUBLIC :: jpmax_digits = 5 !: maximum number of digits for the cpu number in the file name 36 36 37 38 !$AGRIF_DO_NOT_TREAT39 INTEGER, PUBLIC :: iom_open_init = 0 !: used to initialize iom_file(:)%nfid to 040 37 !XIOS write restart 41 38 LOGICAL, PUBLIC :: lwxios !: write single file restart using XIOS … … 44 41 LOGICAL, PUBLIC :: lrxios !: read single file restart using XIOS 45 42 LOGICAL, PUBLIC :: lxios_sini = .FALSE. ! is restart in a single file 46 LOGICAL, PUBLIC :: lxios_set = .FALSE. 43 LOGICAL, PUBLIC :: lxios_set = .FALSE. 47 44 48 45 !$AGRIF_DO_NOT_TREAT 46 INTEGER, PUBLIC :: iom_open_init = 0 !: used to initialize iom_file(:)%nfid to 0 49 47 50 48 TYPE, PUBLIC :: file_descriptor -
NEMO/branches/2019/dev_r11756_SI3restart_XIOS/src/OCE/IOM/restart.F90
r11870 r11901 131 131 INTEGER, INTENT(in) :: kt ! ocean time-step 132 132 !!---------------------------------------------------------------------- 133 133 134 IF(lwxios) CALL iom_swap( cwxios_context ) 134 135 CALL iom_rstput( kt, nitrst, numrow, 'rdt' , rdt , ldxios = lwxios) ! dynamics time step … … 207 208 ! restart) 208 209 IF(.NOT.lxios_set) lrxios = lrxios.AND.lxios_sini 209 IF( lrxios ) THEN210 IF( lrxios .AND. (.NOT. lxios_set)) THEN 210 211 crxios_context = 'nemo_rst' 211 IF( .NOT. lxios_set ) THEN 212 IF(lwp) WRITE(numout,*) 'Enable restart reading by XIOS' 213 CALL iom_init( crxios_context, TRIM(clpath)//cn_ocerst_in, ld_tmppatch = .false. ) 214 lxios_set = .TRUE. 212 lxios_set = .TRUE. 213 IF( TRIM(Agrif_CFixed()) /= '0') THEN 214 IF(lwp) WRITE(numout,*) 'Enable restart reading by XIOS for AGRIF' 215 CALL iom_init( crxios_context, TRIM(clpath)//TRIM(Agrif_CFixed())//"_"//cn_ocerst_in, ld_tmppatch = .false. ) 216 ELSE 217 IF(lwp) WRITE(numout,*) 'Enable restart reading by XIOS' 218 CALL iom_init( crxios_context, TRIM(clpath)//cn_ocerst_in, ld_tmppatch = .false. ) 215 219 ENDIF 216 ENDIF217 IF( TRIM(Agrif_CFixed()) /= '0' .AND. lrxios) THEN218 CALL iom_init( crxios_context, TRIM(clpath)//cn_ocerst_in, ld_tmppatch = .false. )219 IF(lwp) WRITE(numout,*) 'Enable restart reading by XIOS for AGRIF'220 lxios_set = .TRUE.221 220 ENDIF 222 221 ENDIF
Note: See TracChangeset
for help on using the changeset viewer.