Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • mesonh/mesonh-code
  • quentin.rodier/mesonh-code-fork
  • benoit.vie/mesonh-code
  • joris.pianezze/mesonh-code
  • 8qq4g5s7/mesonh-code
  • jean.baptiste.filippi/meso-nh-fire-code
  • fdl68d9p/mesonh-code-sophia
7 results
Show changes
Commits on Source (4819)
Showing
with 1505 additions and 475 deletions
conf/profile_mesonh
conf/profile_mesonh-*
exe/*
MY_RUN/INTEGRATION_CASES/**/*.des
MY_RUN/INTEGRATION_CASES/**/*.dir
MY_RUN/INTEGRATION_CASES/**/*.hdr
MY_RUN/INTEGRATION_CASES/**/*.nc
MY_RUN/INTEGRATION_CASES/**/ecmwf.OD.????????.??
MY_RUN/INTEGRATION_CASES/**/file_for_xtransfer
MY_RUN/INTEGRATION_CASES/**/OUTPUT_LISTING*
MY_RUN/INTEGRATION_CASES/**/PRESSURE
MY_RUN/KTEST/*/*/*.des
MY_RUN/KTEST/*/*/*.lfi
MY_RUN/KTEST/*/*/*.nc
......@@ -36,10 +44,29 @@ MY_RUN/KTEST/009_ICARTT/001_pgd1/*.asc
MY_RUN/KTEST/009_ICARTT/002_arp2lfi/ecmwf.OD.20040810.18-V2
MY_RUN/KTEST/009_ICARTT/002_arp2lfi/mocage.GLOB22.20040810.18
MY_RUN/KTEST/9??_*
pub/ncl-?.?.?
pub/ncl_ncarg*/
pub/FILEPP/filepp*
!pub/FILEPP/filepp*.tar.gz
pub/FILEPP/FILEPP*
pub/FILEPP/MNH_Expand_*
!pub/FILEPP/MNH_EXPAND_*.tar.gz
src/dir_obj-*
src/LIB/eccodes*
!src/LIB/eccodes*.tar.gz
src/LIB/grib_api*
!src/LIB/grib_api*.tar.gz
src/LIB/hdf5*
!src/LIB/hdf5*.tar.gz
src/LIB/HDF5Plugin-Zstandard/build
src/LIB/libaec*
!src/LIB/libaec*.tar.gz
src/LIB/netcdf*
!src/LIB/netcdf*.tar.gz
src/LIB/MEGAN*
src/LIB/oasis3-mct*
!src/LIB/oasis3-mct*.tar.gz
src/LIB/toy*
!src/LIB/toy*.tar.gz
src/LIB/zstd*
!src/LIB/zstd*.tar.gz
vscode_mod
vscode_mod/
This diff is collapsed.
!-----------------------------------------------------------------
!--------------- special set of characters for RCS information
!-----------------------------------------------------------------
! $Source$ $Revision$ $Date$
!MNH_LIC Copyright 1994-2019 CNRS, Meteo-France and Universite Paul Sabatier
!MNH_LIC This is part of the Meso-NH software governed by the CeCILL-C licence
!MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
!MNH_LIC for details. version 1.
!-----------------------------------------------------------------
SUBROUTINE COMPRESS_FIELD(XTAB,KX,KY,KNBTOT,KNBUSE)
USE MODD_COMPPAR
USE MODE_SEARCHGRP
#ifdef NAGf95
USE,INTRINSIC :: IEEE_ARITHMETIC
#endif
IMPLICIT NONE
......@@ -38,17 +36,21 @@ INTEGER :: IEXTCOD
CHARACTER(LEN=8),PARAMETER :: KEYWORD='COMPRESS'
REAL,DIMENSION(KNBTOT) :: XWORKTAB
LOGICAL :: LUPREAL,LNAN
#ifndef NAGf95
LOGICAL, EXTERNAL :: IEEE_IS_NAN
#endif
logical :: gnansupport
ILEVNBELT = KX*KY
LUPREAL = .FALSE.
LNAN = .FALSE.
if ( IEEE_SUPPORT_NAN( xtab(1)) ) then
gnansupport=.true.
else
gnansupport=.false.
end if
! Check for NAN and change Upper and Lower bound according to 32bits real limits.
DO JI=1,KNBTOT
IF (IEEE_IS_NAN(XTAB(JI))) THEN
IF ( gnansupport .and. IEEE_IS_NAN(XTAB(JI)) ) THEN
XTAB(JI)=0.
LNAN = .TRUE.
ELSE IF (ABS(XTAB(JI)) > HUGE(1.0_4)) THEN
......
#include <math.h>
#ifdef NO_UNDERSCORE
# define IEEE_IS_NAN ieee_is_nan
#else
# define IEEE_IS_NAN ieee_is_nan_
#endif
int IEEE_IS_NAN(double *x){
return isnan(*x);
}
#!/bin/sh
#!/bin/bash
#
#
usage(){
......
!MNH_LIC Copyright 1994-2018 CNRS, Meteo-France and Universite Paul Sabatier
!MNH_LIC Copyright 1994-2025 CNRS, Meteo-France and Universite Paul Sabatier
!MNH_LIC This is part of the Meso-NH software governed by the CeCILL-C licence
!MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
!MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
!MNH_LIC for details. version 1.
!-----------------------------------------------------------------
! Modifications:
! P. Wautelet 19/09/2019: add possibility to provide a fallback file if some information are not found in the input file
!-----------------------------------------------------------------
program LFI2CDF
USE MODD_CONF, ONLY: CPROGRAM
USE MODD_CONFZ, ONLY: NB_PROCIO_R
USE MODD_DIM_n, ONLY: NIMAX_ll, NJMAX_ll, NKMAX
USE MODD_IO_ll, ONLY: LVERB_OUTLST, LVERB_STDOUT, NIO_ABORT_LEVEL, NIO_VERB, NGEN_ABORT_LEVEL, NGEN_VERB
USE MODD_GRID_n, ONLY: XXHAT, XXHATM, XYHAT, XYHATM
USE MODD_IO, ONLY: LVERB_OUTLST, LVERB_STDOUT, NIO_ABORT_LEVEL, NIO_VERB, NGEN_ABORT_LEVEL, NGEN_VERB
USE MODD_PARAMETERS, ONLY: JPHEXT, JPVEXT
USE MODD_TIMEZ, ONLY: TIMEZ
USE MODE_IO_ll, ONLY: INITIO_ll, SET_CONFIO_ll
USE MODE_FIELD, ONLY: INI_FIELD_LIST
use mode_field, only: Ini_field_list
USE MODE_IO, ONLY: IO_Init, IO_Config_set
use mode_ll
use mode_modeln_handler, only: Goto_model
USE mode_options
USE MODE_SET_GRID, ONLY: INTERP_HORGRID_TO_MASSPOINTS
USE MODE_SPLITTINGZ_ll, ONLY: INI_PARAZ_ll
USE mode_util
USE MODI_VERSION
USE MODN_CONFIO, ONLY: LCDF4, LLFIOUT, LLFIREAD
......@@ -31,7 +39,7 @@ program LFI2CDF
INTEGER :: IINFO_ll ! return code of // routines
INTEGER :: nfiles_out = 0 ! number of output files
CHARACTER(LEN=:),allocatable :: hvarlist
TYPE(TFILE_ELT),DIMENSION(1) :: infiles
TYPE(TFILE_ELT),DIMENSION(2) :: infiles
TYPE(TFILE_ELT),DIMENSION(MAXFILES) :: outfiles
TYPE(workfield), DIMENSION(:), POINTER :: tzreclist
......@@ -43,14 +51,16 @@ program LFI2CDF
CPROGRAM = 'LFICDF'
CALL INITIO_ll()
CALL Goto_model(1)
CALL IO_Init()
CALL VERSION
CALL INI_CST
ALLOCATE(TIMEZ) !Used by IO_WRITE_FIELD
NIO_VERB = NVERB_WARNING
NGEN_VERB = NVERB_WARNING
NIO_VERB = NVERB_INFO
NGEN_VERB = NVERB_INFO
NIO_ABORT_LEVEL = NVERB_FATAL
NGEN_ABORT_LEVEL = NVERB_FATAL
LVERB_OUTLST = .FALSE.
......@@ -73,25 +83,25 @@ program LFI2CDF
LCDF4 = .TRUE.
LLFIOUT = .FALSE.
LLFIREAD = .TRUE.
CALL SET_CONFIO_ll()
CALL IO_Config_set()
ELSE IF (runmode == MODECDF2CDF) THEN
LCDF4 = .TRUE.
LLFIOUT = .FALSE.
LLFIREAD = .FALSE.
CALL SET_CONFIO_ll()
CALL IO_Config_set()
ELSE
LCDF4 = .TRUE.
LLFIOUT = .TRUE.
LLFIREAD = .FALSE.
CALL SET_CONFIO_ll()
CALL IO_Config_set()
END IF
CALL INI_FIELD_LIST(1)
CALL INI_FIELD_LIST()
CALL OPEN_FILES(infiles, outfiles, nfiles_out, hinfile, houtfile, nbvar_infile, options, runmode)
IF (options(OPTLIST)%set) STOP
!Set and initialize parallel variables (necessary to read splitted files)
!Set and initialize parallel variables (necessary to read split files)
CALL SET_JP_ll(1,JPHEXT,JPVEXT,JPHEXT)
CALL SET_DAD0_ll()
CALL SET_DIM_ll(NIMAX_ll, NJMAX_ll, NKMAX)
......@@ -103,6 +113,12 @@ program LFI2CDF
CALL SET_YEND_ll(NJMAX_ll+2*JPHEXT, 1)
CALL INI_PARAZ_ll(IINFO_ll)
! This has to be done after INI_PARAZ_ll and after reading of XXHAT and XYHAT (in OPEN_FILES)
ALLOCATE(XXHATM(NIMAX_ll+2*JPHEXT))
ALLOCATE(XYHATM(NJMAX_ll+2*JPHEXT))
! Interpolations of positions to mass points
CALL INTERP_HORGRID_TO_MASSPOINTS( XXHAT, XYHAT, XXHATM, XYHATM )
IF (runmode == MODELFI2CDF .OR. runmode == MODECDF2CDF) THEN
IF (options(OPTVAR)%set) THEN
! nbvar_tbr is computed from number of requested variables
......@@ -150,7 +166,11 @@ program LFI2CDF
CALL fill_files(infiles,outfiles,tzreclist,nbvar,options)
END IF
CALL CLOSE_FILES(infiles, 1)
if ( options( OPTFALLBACK )%set ) then
CALL CLOSE_FILES(infiles, 2)
else
CALL CLOSE_FILES(infiles, 1)
end if
CALL CLOSE_FILES(outfiles,nfiles_out)
end program LFI2CDF
!MNH_LIC Copyright 2015-2018 CNRS, Meteo-France and Universite Paul Sabatier
!MNH_LIC Copyright 2015-2020 CNRS, Meteo-France and Universite Paul Sabatier
!MNH_LIC This is part of the Meso-NH software governed by the CeCILL-C licence
!MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
!MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
!MNH_LIC for details. version 1.
!-----------------------------------------------------------------
! Modifications:
! P. Wautelet 19/09/2019: add possibility to provide a fallback file if some information are not found in the input file
! P. Wautelet 21/10/2019: add OPTDIR option to set directory for writing outfiles
!-----------------------------------------------------------------
module mode_options
USE MODE_FIELD, ONLY: TYPEUNDEF, TYPEINT, TYPELOG, TYPEREAL, TYPECHAR, TYPEDATE
use modd_field, only: TYPEUNDEF, TYPEINT, TYPELOG, TYPEREAL, TYPECHAR, TYPEDATE
implicit none
integer,parameter :: nbavailoptions = 10
integer,parameter :: NBAVAILOPTIONS = 12
integer,parameter :: MODEUNDEF = -11, MODECDF2CDF = 11, MODELFI2CDF = 12, MODECDF2LFI = 13
integer,parameter :: OPTCOMPRESS = 1, OPTHELP = 2, OPTLIST = 3
integer,parameter :: OPTMERGE = 4, OPTOUTPUT = 5, OPTREDUCE = 6
integer,parameter :: OPTMODE = 7, OPTSPLIT = 8, OPTVAR = 9
integer,parameter :: OPTVERBOSE = 10
integer,parameter :: OPTCOMPRESS = 1, OPTHELP = 2, OPTLIST = 3
integer,parameter :: OPTMERGE = 4, OPTOUTPUT = 5, OPTREDUCE = 6
integer,parameter :: OPTMODE = 7, OPTSPLIT = 8, OPTVAR = 9
integer,parameter :: OPTVERBOSE = 10, OPTFALLBACK = 11, OPTDIR = 12
type option
logical :: set = .false.
......@@ -153,6 +157,17 @@ subroutine init_options(options)
options(OPTVERBOSE)%long_name = "verbose"
options(OPTVERBOSE)%short_name = 'V'
options(OPTVERBOSE)%has_argument = .false.
options(OPTFALLBACK)%long_name = "fallback-file"
options(OPTFALLBACK)%short_name = 'f'
options(OPTFALLBACK)%has_argument = .true.
options(OPTFALLBACK)%type = TYPECHAR
options(OPTDIR)%long_name = "outdir"
options(OPTDIR)%short_name = 'd'
options(OPTDIR)%has_argument = .true.
options(OPTDIR)%type = TYPECHAR
end subroutine init_options
subroutine get_option(options,finished)
......@@ -278,12 +293,6 @@ subroutine check_options(options,infile,runmode)
call help()
end if
!Merge flag only supported if -v is set
if (options(OPTMERGE)%set .AND. .NOT.options(OPTVAR)%set) then
print *,'Error: merge option must be used with var option'
call help()
end if
!Split flag only supported if -v is set
if (options(OPTSPLIT)%set .AND. .NOT.options(OPTVAR)%set) then
options(OPTSPLIT)%set = .false.
......@@ -329,18 +338,21 @@ subroutine help()
!TODO: -l option for cdf2cdf and cdf2lfi
print *,"Usage : lfi2cdf [-h --help] [-l] [-v --var var1[,...]] [-r --reduce-precision]"
print *," [-m --merge number_of_z_levels] [-s --split] [-o --output output-file.nc]"
print *," [-R --runmode mode] [-V --verbose]"
print *," [-R --runmode mode] [-V --verbose] [-f --fallback-file fallback-file]"
print *," [-c --compress compression_level] input-file.lfi"
print *," cdf2cdf [-h --help] [-v --var var1[,...]] [-r --reduce-precision]"
print *," [-m --merge number_of_split_files] [-s --split] [-o --output output-file.nc]"
print *," [-R --runmode mode] [-V --verbose]"
print *," [-R --runmode mode] [-V --verbose] [-f --fallback-file fallback-file]"
print *," [-c --compress compression_level] input-file.nc"
print *," cdf2lfi [-o --output output-file.lfi] [-R --runmode mode] [-V --verbose] input-file.nc"
print *," cdf2lfi [-o --output output-file.lfi] [-R --runmode mode] [-V --verbose]"
print *," [-f --fallback-file fallback-file] input-file.nc"
print *,""
print *,"Options:"
print *," --compress, -c compression_level"
print *," Compress data. The compression level should be in the 1 to 9 interval."
print *," Only supported with the netCDF format (cdf2cdf and lfi2cdf only)"
print *," -f --fallback-file fallback-file"
print *," File to use to read some grid information if not found in input-file"
print *," --help, -h"
print *," Print this text"
print *," --list, -l"
......
This diff is collapsed.
......@@ -14,25 +14,27 @@ INTEGER :: arglen
INTEGER :: inarg
CHARACTER(LEN=50) :: yexe
LOGICAL(KIND=LFI_INT),PARAMETER :: GTRUE = .TRUE.
LOGICAL(KIND=LFI_INT),PARAMETER :: GFALSE = .FALSE.
INTEGER, PARAMETER :: FM_FIELD_SIZE = 16
INTEGER, PARAMETER :: ISRCLU = 11
INTEGER, PARAMETER :: IDESTLU = 12
INTEGER(KIND=LFI_INT), PARAMETER :: ISRCLU = 11
INTEGER(KIND=LFI_INT), PARAMETER :: IDESTLU = 12
INTEGER :: JPHEXT
INTEGER :: iverb
INTEGER :: inap ! nb d'articles prevus (utile a la creation)
INTEGER :: inaf ! nb d'articles presents dans un fichier existant
INTEGER :: inafdest
INTEGER(KIND=LFI_INT) :: iverb
INTEGER(KIND=LFI_INT) :: inap ! nb d'articles prevus (utile a la creation)
INTEGER(KIND=LFI_INT) :: inaf ! nb d'articles presents dans un fichier existant
INTEGER(KIND=LFI_INT) :: inafdest
CHARACTER(LEN=128) :: filename,DESTFNAME
INTEGER :: JI,JJ
INTEGER :: IRESP
INTEGER(KIND=LFI_INT) :: IRESP
CHARACTER(LEN=FM_FIELD_SIZE),DIMENSION(:),ALLOCATABLE :: yrecfm
INTEGER, DIMENSION(:),ALLOCATABLE :: ileng
INTEGER(KIND=LFI_INT), DIMENSION(:),ALLOCATABLE :: ileng
INTEGER(KIND=8), DIMENSION(:),ALLOCATABLE :: iwork
INTEGER :: ilengs
INTEGER :: ipos
INTEGER(KIND=LFI_INT) :: ilengs
INTEGER(KIND=LFI_INT) :: ipos
INTEGER :: sizemax
INTEGER :: IGRID
......@@ -46,7 +48,9 @@ INTEGER :: LFICOMP
INTEGER :: NEWSIZE
INTEGER :: searchndx
INTEGER :: INDDATIM
INARG = IARGC()
!OLD: INARG = IARGC()
INARG = COMMAND_ARGUMENT_COUNT()
#if defined(F90HP)
#define HPINCR 1
......@@ -54,6 +58,9 @@ INARG = IARGC()
#define HPINCR 0
#endif
CALL GET_COMMAND_ARGUMENT(0,yexe)
#if 0
!OLD:
#if defined(FUJI) || defined(NAGf95) || defined(NEC) || defined(HP) || defined(pgf) || defined(G95) || defined(GFORTRAN)
CALL GETARG(0+HPINCR,yexe)
IF (LEN_TRIM(yexe) == 0) THEN
......@@ -63,12 +70,17 @@ INARG = IARGC()
#else
CALL PXFGETARG(0,yexe,arglen,iresp)
#endif
#endif
! PRINT *,yexe, ' avec ',INARG,' arguments.'
IF (INARG == 1) THEN
CALL GET_COMMAND_ARGUMENT(1,filename)
#if 0
!OLD:
#if defined(FUJI) || defined(NAGf95) || defined(NEC) || defined(HP) || defined(pgf) || defined(G95)|| defined(GFORTRAN)
CALL GETARG(1+HPINCR,filename)
#else
CALL PXFGETARG(1,filename,arglen,iresp)
#endif
#endif
ELSE
PRINT *,'Usage : ', TRIM(yexe), ' [fichier lfi]'
......@@ -91,8 +103,8 @@ IDIMY = 0
IDIMZ = 0
GUSEDIM = .FALSE.
CALL LFIOUV(IRESP,ISRCLU,.TRUE.,filename,'OLD',.FALSE.&
& ,.FALSE.,iverb,inap,inaf)
CALL LFIOUV(IRESP,ISRCLU,GTRUE,filename,'OLD',GFALSE&
& ,GFALSE,iverb,inap,inaf)
CALL FMREADLFIN1(ISRCLU,'LFI_COMPRESSED',LFICOMP,iresp)
IF (iresp == 0) THEN
......@@ -139,8 +151,8 @@ END IF
PRINT *,'compressed file : ',DESTFNAME
CALL LFIOUV(IRESP,IDESTLU,.TRUE.,DESTFNAME,'NEW'&
& ,.FALSE.,.FALSE.,iverb,inaf+1,inafdest)
CALL LFIOUV(IRESP,IDESTLU,GTRUE,DESTFNAME,'NEW'&
& ,GFALSE,GFALSE,iverb,inaf+1,inafdest)
CALL LFIPOS(IRESP,ISRCLU)
ALLOCATE(yrecfm(inaf))
......@@ -148,7 +160,7 @@ ALLOCATE(ileng(inaf))
yrecfm(:) = ''
sizemax=0
DO ji=1,inaf
CALL LFICAS(IRESP,ISRCLU,yrecfm(ji),ileng(ji),ipos,.TRUE.)
CALL LFICAS(IRESP,ISRCLU,yrecfm(ji),ileng(ji),ipos,GTRUE)
IF (ileng(ji) > sizemax) sizemax=ileng(ji)
END DO
PRINT *,' Nombre total d''articles dans fichier source :', inaf
......@@ -218,13 +230,13 @@ CALL LFIFER(IRESP,IDESTLU,'KEEP')
CONTAINS
SUBROUTINE FMREADLFIN1(klu,hrecfm,kval,kresp)
INTEGER, INTENT(IN) :: klu ! logical fortran unit au lfi file
CHARACTER(LEN=*),INTENT(IN) :: hrecfm ! article name to be read
INTEGER, INTENT(OUT) :: kval ! integer value for hrecfm article
INTEGER, INTENT(OUT) :: kresp! return code null if OK
INTEGER(KIND=LFI_INT), INTENT(IN) :: klu ! logical fortran unit au lfi file
CHARACTER(LEN=*), INTENT(IN) :: hrecfm ! article name to be read
INTEGER, INTENT(OUT) :: kval ! integer value for hrecfm article
INTEGER(KIND=LFI_INT), INTENT(OUT) :: kresp! return code null if OK
!
INTEGER(KIND=8),DIMENSION(:),ALLOCATABLE::iwork
INTEGER :: iresp,ilenga,iposex,icomlen
INTEGER(KIND=8),DIMENSION(:),ALLOCATABLE :: iwork
INTEGER(KIND=LFI_INT) :: iresp,ilenga,iposex,icomlen
!
CALL LFINFO(iresp,klu,hrecfm,ilenga,iposex)
IF (iresp /=0 .OR. ilenga == 0) THEN
......
......@@ -14,24 +14,26 @@ INTEGER :: arglen
INTEGER :: inarg
CHARACTER(LEN=50) :: yexe
LOGICAL(KIND=LFI_INT),PARAMETER :: GTRUE = .TRUE.
LOGICAL(KIND=LFI_INT),PARAMETER :: GFALSE = .FALSE.
INTEGER, PARAMETER :: FM_FIELD_SIZE = 16
INTEGER, PARAMETER :: ISRCLU = 11
INTEGER, PARAMETER :: IDESTLU = 12
INTEGER :: iverb
INTEGER :: inap ! nb d'articles prevus (utile a la creation)
INTEGER :: inaf ! nb d'articles presents dans un fichier existant
INTEGER :: inafdest
INTEGER(KIND=LFI_INT), PARAMETER :: ISRCLU = 11
INTEGER(KIND=LFI_INT), PARAMETER :: IDESTLU = 12
INTEGER(KIND=LFI_INT) :: iverb
INTEGER(KIND=LFI_INT) :: inap ! nb d'articles prevus (utile a la creation)
INTEGER(KIND=LFI_INT) :: inaf ! nb d'articles presents dans un fichier existant
INTEGER(KIND=LFI_INT) :: inafdest
CHARACTER(LEN=128) :: filename,DESTFNAME
INTEGER :: JI,JJ
INTEGER :: IRESP
INTEGER(KIND=LFI_INT) :: IRESP
CHARACTER(LEN=FM_FIELD_SIZE),DIMENSION(:),ALLOCATABLE :: yrecfm
INTEGER, DIMENSION(:),ALLOCATABLE :: ileng
INTEGER(KIND=LFI_INT), DIMENSION(:),ALLOCATABLE :: ileng
INTEGER(KIND=8), DIMENSION(:),ALLOCATABLE :: iwork,iworknew
INTEGER :: ilengs
INTEGER :: ipos
INTEGER(KIND=LFI_INT) :: ilengs
INTEGER(KIND=LFI_INT) :: ipos
INTEGER :: sizemax
INTEGER :: ICOMLEN
......@@ -43,9 +45,10 @@ INTEGER :: CPT
INTEGER :: LFICOMP
INTEGER :: searchndx
INTEGER :: ITYPCOD
INTEGER :: ITOTAL,ITOTALMAX
INTEGER(KIND=LFI_INT) :: ITOTAL,ITOTALMAX
INARG = IARGC()
!OLD: INARG = IARGC()
INARG = COMMAND_ARGUMENT_COUNT()
#if defined(F90HP)
#define HPINCR 1
......@@ -53,6 +56,9 @@ INARG = IARGC()
#define HPINCR 0
#endif
CALL GET_COMMAND_ARGUMENT(0,yexe)
#if 0
!OLD:
#if defined(FUJI) || defined(NAGf95) || defined(NEC) || defined(HP) || defined(pgf) || defined(G95) || defined(GFORTRAN)
CALL GETARG(0+HPINCR,yexe)
IF (LEN_TRIM(yexe) == 0) THEN
......@@ -62,12 +68,17 @@ INARG = IARGC()
#else
CALL PXFGETARG(0,yexe,arglen,iresp)
#endif
#endif
! PRINT *,yexe, ' avec ',INARG,' arguments.'
IF (INARG == 1) THEN
CALL GET_COMMAND_ARGUMENT(1,filename)
#if 0
!OLD:
#if defined(FUJI) || defined(NAGf95) || defined(NEC) || defined(HP) || defined(pgf) || defined(G95) || defined(GFORTRAN)
CALL GETARG(1+HPINCR,filename)
#else
CALL PXFGETARG(1,filename,arglen,iresp)
#endif
#endif
ELSE
PRINT *,'Usage : ', TRIM(yexe), ' [fichier lfi]'
......@@ -93,8 +104,8 @@ IDIMY = 0
IDIMZ = 0
GUSEDIM = .FALSE.
CALL LFIOUV(IRESP,ISRCLU,.TRUE.,filename,'OLD',.FALSE.&
& ,.FALSE.,iverb,inap,inaf)
CALL LFIOUV(IRESP,ISRCLU,GTRUE,filename,'OLD',GFALSE&
& ,GFALSE,iverb,inap,inaf)
CALL FMREADLFIN1(ISRCLU,'LFI_COMPRESSED',LFICOMP,iresp)
IF (iresp /= 0 .OR. LFICOMP /= 1) THEN
......@@ -104,8 +115,8 @@ IF (iresp /= 0 .OR. LFICOMP /= 1) THEN
END IF
PRINT *,'Uncompressed (but 32 bits REAL precision) file : ',DESTFNAME
CALL LFIOUV(IRESP,IDESTLU,.TRUE.,DESTFNAME,'NEW'&
& ,.FALSE.,.FALSE.,iverb,inaf,inafdest)
CALL LFIOUV(IRESP,IDESTLU,GTRUE,DESTFNAME,'NEW'&
& ,GFALSE,GFALSE,iverb,inaf,inafdest)
CALL LFIPOS(IRESP,ISRCLU)
ALLOCATE(yrecfm(inaf))
......@@ -113,7 +124,7 @@ ALLOCATE(ileng(inaf))
yrecfm(:) = ''
sizemax=0
DO ji=1,inaf
CALL LFICAS(IRESP,ISRCLU,yrecfm(ji),ileng(ji),ipos,.TRUE.)
CALL LFICAS(IRESP,ISRCLU,yrecfm(ji),ileng(ji),ipos,GTRUE)
IF (ileng(ji) > sizemax) sizemax=ileng(ji)
END DO
PRINT *,' Nombre total d''articles dans fichier source :', inaf
......@@ -173,13 +184,13 @@ CALL LFIFER(IRESP,IDESTLU,'KEEP')
CONTAINS
SUBROUTINE FMREADLFIN1(klu,hrecfm,kval,kresp)
INTEGER, INTENT(IN) :: klu ! logical fortran unit au lfi file
CHARACTER(LEN=*),INTENT(IN) :: hrecfm ! article name to be read
INTEGER, INTENT(OUT) :: kval ! integer value for hrecfm article
INTEGER, INTENT(OUT) :: kresp! return code null if OK
INTEGER(KIND=LFI_INT), INTENT(IN) :: klu ! logical fortran unit au lfi file
CHARACTER(LEN=*), INTENT(IN) :: hrecfm ! article name to be read
INTEGER, INTENT(OUT) :: kval ! integer value for hrecfm article
INTEGER(KIND=LFI_INT), INTENT(OUT) :: kresp! return code null if OK
!
INTEGER(KIND=8),DIMENSION(:),ALLOCATABLE::iwork
INTEGER :: iresp,ilenga,iposex,icomlen
INTEGER(KIND=8),DIMENSION(:),ALLOCATABLE :: iwork
INTEGER(KIND=LFI_INT) :: iresp,ilenga,iposex,icomlen
!
CALL LFINFO(iresp,klu,hrecfm,ilenga,iposex)
IF (iresp /=0 .OR. ilenga == 0) THEN
......
#MNH_LIC Copyright 1994-2014 CNRS, Meteo-France and Universite Paul Sabatier
#MNH_LIC Copyright 1994-2025 CNRS, Meteo-France and Universite Paul Sabatier
#MNH_LIC This is part of the Meso-NH software governed by the CeCILL-C licence
#MNH_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
#MNH_LIC for details. version 1.
......@@ -54,7 +54,6 @@ cat > EXSEG1.nam << EOF
&NAM_DYNn
XTSTEP = ${XTSTEP} ,
CPRESOPT = "CRESI",
NITR = 12,
LITRADJ = T,
XRELAX = 1.,
LHORELAX_UVWTH = T,
......
&NAM_CONFZ
NB_PROCIO_W=1 ,
!MPI_BUFFER_SIZE=40
/
&NAM_PGDFILE CPGDFILE="PGD00128" /
&NAM_PGD_SCHEMES CNATURE='ISBA', CSEA='SEAFLX', CTOWN='NONE', CWATER='NONE' /
&NAM_CONF_PROJ XLAT0=-11.5, XLON0=130.7, XRPK=0., XBETA=0. /
&NAM_CONF_PROJ_GRID XLATCEN=-11.5, XLONCEN=130.7, NIMAX=128, NJMAX=128,
XDX=1600.00000, XDY=1600.00000 /
&NAM_COVER YCOVER='ECOCLIMAP_v2.0', YCOVERFILETYPE='DIRECT' /
&NAM_ZS YZS='gtopo30', YZSFILETYPE='DIRECT' /
&NAM_ISBA YCLAY='CLAY_HWSD_MOY', YCLAYFILETYPE='DIRECT',
YSAND='SAND_HWSD_MOY', YSANDFILETYPE='DIRECT' /
......@@ -23,7 +23,7 @@ export PGD_URL
for file in LICENSE_ECOCLIMAP.txt LICENSE_soil_data.txt \
gtopo30.dir gtopo30.hdr \
SAND_HWSD_MOY.hdr SAND_HWSD_MOY.dir CLAY_HWSD_MOY.hdr CLAY_HWSD_MOY.dir \
ECOCLIMAP_v2.0.hdr ECOCLIMAP_v2.0.dir etopo2.nc
ECOCLIMAP_v2.0.hdr ECOCLIMAP_v2.0.dir
do
[ -f $file ] || ( ${WGET} -c -nd $PGD_URL/$file.gz ; gunzip $file.gz ; )
done
......
#!/bin/bash
export MPIRUN="Mpirun -np 4"
PREP_PGD_FILES=${PREP_PGD_FILES:-"$HOME/PREP_PGD_FILES_WWW"} ; export PREP_PGD_FILES
#
if [ ! -d $PREP_PGD_FILES ]
then
cat << EOF
Your directory PREP_PGD_FILES=$PREP_PGD_FILES
containing the files gtopo30*, ECOCLIMAP_v2.0*
doesn't exist ( or was not found !!! )
use the script 'get_pgd_files' to download
this files from the MESONH WEB PAGES !!!
( or change the variable PREP_PGD_FILES ... )
After fixing it , run this script again !!!
EOF
exit 1
else
set -x
#
rm -f OUTPUT_LISTING0 pipe_name
rm -f gtopo30.??? sand_fao.??? clay_fao.???
rm -f SAND_HWSD_MOY.??? ECOCLIMAP_v2.0.??? ecoclimats_v2.???
rm -f PGD00128.*
#
ln -sf $PREP_PGD_FILES/*.dir $PREP_PGD_FILES/*.hdr .
#
time ${MPIRUN} PREP_PGD${XYZ}
fi
&NAM_CONFZ
!NB_PROCIO_R=1 ,
!NB_PROCIO_W=1 ,
!MPI_BUFFER_SIZE=40
/
&NAM_REAL_PGD
CPGD_FILE ="PGD00128" ,
LREAD_ZS =.TRUE., LREAD_GROUND_PARAM =.TRUE.
/
&NAM_DIMn_PRE NIMAX=40, NJMAX=32 /
&NAM_CONF_PRE LCARTESIAN=.FALSE.
CIDEAL='RSOU' CZS='FLAT'
NVERB=0 /
&NAM_CONFn LUSERV= T /
&NAM_LUNITn CINIFILE = "DA0128" , CINIFILEPGD = "PGD00128" /
&NAM_DYNn_PRE
CPRESOPT= 'ZRESI' ,
NITR=4 XRELAX=1. /
&NAM_LBCn_PRE CLBCX= 2*'OPEN' CLBCY= 2*'OPEN' /
&NAM_VPROF_PRE CTYPELOC='IJGRID' NILOC=1 NJLOC=1
CFUNU='ZZZ' CFUNV='ZZZ'
LGEOSBAL=.FALSE. /
&NAM_VER_GRID NKMAX=126, YZGRID_TYPE='FUNCTN',
ZDZGRD=40., ZDZTOP=210., ZZMAX_STRGRD=2500.,
ZSTRGRD=7., ZSTRTOP=7. /
&NAM_GRn_PRE
CSURF='EXTE'
! CSURF='NONE'
/
&NAM_PREP_ISBA XTG_SURF= 311., XTG_ROOT= 303., XTG_DEEP= 302.,
XHUG_SURF= 0.16, XHUG_ROOT= 0.16, XHUG_DEEP= 0.16 /
&NAM_PREP_SEAFLUX XSST_UNIF= 304. /
RSOU
2005 11 30 0
'PUVTHDMR'
0.0000000E+00
100300.0
303.3000
1.9630000E-02
92
100000.0 3.637668 -3.637668
99900.00 2.572220 -4.455216
99100.00 -4.612377 0.4035313
96600.00 5.124864 -0.4483674
93000.00 5.836996 -2.009839
92800.00 5.801031 -2.111402
92500.00 5.466062 -1.464627
85000.00 0.1345103 -1.537459
81400.00 -0.9020693 -1.849517
71800.00 -2.797467 1.304481
70000.00 -4.472232 1.198331
60500.00 -3.289776 -1.464702
59900.00 -3.208611 -1.634869
56900.00 -2.329535 -2.025034
55600.00 -2.105100 -2.257443
50100.00 -0.5325915 -1.987659
50000.00 -0.2679967 -1.519885
49500.00 0.2507798 -2.042438
46700.00 5.466062 1.464627
45300.00 5.594935 2.608961
44800.00 5.450725 2.898202
43700.00 4.994327 3.628591
42200.00 4.561049 4.891127
41900.00 4.387573 5.047325
41800.00 4.298817 5.123130
40000.00 6.305391 5.290851
39000.00 5.970908 4.027428
38600.00 5.671552 3.543979
38300.00 5.346259 3.086664
35500.00 2.976104 3.546782
32700.00 4.455215 2.572220
31400.00 3.712562 4.270814
30700.00 3.086664 5.346259
30000.00 3.540875 5.056894
28800.00 3.786532 4.205370
26700.00 3.329551 2.419061
25000.00 2.797467 1.304481
24400.00 2.819808 1.255459
23800.00 2.841289 1.206056
21400.00 3.424857 1.112804
20000.00 3.478403 0.9320353
19300.00 3.383935 1.231651
17400.00 3.411947 2.301387
15000.00 2.950729 4.214078
12700.00 2.167201 2.875973
10200.00 1.322713 1.576348
10000.00 0.4466614 2.533142
9120.000 -3.306782 3.940869
8700.000 -7.950636 2.130367
8200.000 -8.712269 0.7622259
8000.000 -9.224754 -0.8070621
7600.000 -4.009694 -2.314998
7300.000 -5.066284 -0.8933228
7000.000 -4.196201 -1.956721
6700.000 -1.013257 0.1786647
6400.000 -2.107039 1.475365
6340.000 -2.558960 1.726041
5480.000 -13.17234 2.322640
5300.000 -15.37459 1.345105
5000.000 -12.81216 -1.120920
4900.000 -12.66571 -2.233307
4860.000 -12.25463 -1.504677
4700.000 -10.76221 0.9415731
4500.000 -11.37801 7.966970
3800.000 -25.11183 2.197004
3600.000 -22.54940 -1.972818
3200.000 -22.72465 -4.417223
3000.000 -22.36116 -5.991656
2490.000 -21.48829 -2.258509
2300.000 -21.07936 -0.7361050
2200.000 -20.57776 -1.7989648E-06
2080.000 -19.00834 -0.9961855
2000.000 -17.93702 -1.569287
1600.000 -14.74927 -10.32755
1500.000 -13.52109 -6.304989
1430.000 -16.89510 -4.527030
1400.000 -18.23862 -3.215962
1300.000 -15.46941 -5.630407
1200.000 -5.594935 2.608962
1190.000 -5.671552 3.543979
1100.000 1.786646 10.13257
1050.000 -3.736842 7.333968
1020.000 -5.435582 4.725079
1000.000 -5.594935 2.608962
950.0000 -4.347303 8.176087
900.0000 2.143975 12.15908
889.9999 1.031246 11.78719
800.0000 -4.728969 4.728969
760.0000 2.890712 7.154763
710.0000 8.644947 -3.318484
700.0000 7.487652 -6.282886
600.0000 -4.214078 -2.950729
91
100000.0 303.1000 1.8050000E-02
99900.00 303.1000 1.8040001E-02
99100.00 303.1000 1.7969999E-02
96600.00 303.1000 1.7729999E-02
93000.00 303.0000 1.7370002E-02
92800.00 303.1000 1.6980000E-02
92500.00 303.2000 1.6400000E-02
85000.00 307.1000 1.1190000E-02
81400.00 309.6000 6.6700005E-03
71800.00 312.3000 6.5600001E-03
70000.00 312.9000 6.5400004E-03
60500.00 316.2000 6.1800000E-03
59900.00 318.1000 5.3400006E-03
56900.00 318.7000 4.9899998E-03
55600.00 322.2000 3.3100001E-03
50100.00 325.5000 2.6000000E-03
50000.00 325.5000 2.5800001E-03
49500.00 325.7000 3.1700002E-03
46700.00 328.6000 1.4500001E-03
45300.00 330.1000 9.4000006E-04
44800.00 330.1000 1.9600000E-03
43700.00 331.0000 2.1500003E-03
42200.00 332.2000 1.9400001E-03
41900.00 332.9000 9.6000003E-04
41800.00 333.0000 9.7000005E-04
40000.00 334.2000 1.1600000E-03
39000.00 334.6000 1.0300000E-03
38600.00 335.6000 6.5000000E-04
38300.00 335.8000 6.0000003E-04
35500.00 338.2000 2.5000001E-04
32700.00 340.8000 9.0000009E-05
31400.00 342.0000 5.0000002E-05
30700.00 342.1000 4.0000003E-05
30000.00 342.3000 4.0000003E-05
28800.00 342.3000 1.2000000E-04
26700.00 344.8000 1.0000001E-05
25000.00 345.4000 1.0000001E-05
24400.00 346.3000 2.0000001E-05
23800.00 346.4000 9.0000009E-05
21400.00 348.1000 1.0000001E-05
20000.00 348.8000 1.0000001E-05
19300.00 348.9000 2.0000001E-05
17400.00 351.5000 1.0000001E-05
15000.00 354.0000 7.1596442E-06
12700.00 355.7000 4.4376361E-06
10200.00 364.6000 1.4789329E-06
10000.00 365.4000 1.2422363E-06
9120.000 371.6000 1.2919259E-06
8700.000 379.9000 1.5496893E-06
8200.000 390.6000 1.8819877E-06
8000.000 395.1000 2.0217396E-06
7600.000 404.7000 2.3198761E-06
7300.000 412.3000 2.4844724E-06
7000.000 420.4000 2.4844724E-06
6700.000 431.1000 2.4844724E-06
6400.000 442.4000 2.4844724E-06
6340.000 444.8000 2.4844724E-06
5480.000 467.8000 2.4844724E-06
5300.000 471.0000 2.4844724E-06
5000.000 476.5000 2.4844724E-06
4900.000 477.6000 2.4844724E-06
4860.000 478.0000 2.4844724E-06
4700.000 485.1000 2.4844724E-06
4500.000 494.6000 2.4844724E-06
3800.000 532.9000 2.4844724E-06
3600.000 545.6000 2.4844724E-06
3200.000 574.4000 2.4844724E-06
3000.000 585.1000 2.4844724E-06
2490.000 624.0000 2.4844724E-06
2300.000 648.9000 2.4844724E-06
2200.000 655.4000 2.4844724E-06
2080.000 663.6000 2.4844724E-06
2000.000 673.5000 2.4844724E-06
1600.000 726.4000 2.4844724E-06
1500.000 742.5000 2.4844724E-06
1430.000 750.7000 2.4844724E-06
1400.000 759.0000 2.4844724E-06
1300.000 788.6000 2.4844724E-06
1200.000 821.7000 2.4844724E-06
1190.000 825.2000 2.4844724E-06
1100.000 833.9000 2.4844724E-06
1050.000 839.0000 2.4844724E-06
1020.000 845.3000 2.4844724E-06
1000.000 851.6000 2.4844724E-06
950.0000 877.0000 2.4844724E-06
900.0000 885.6000 2.4844724E-06
889.9999 887.3000 2.4844724E-06
800.0000 926.6000 2.4844724E-06
760.0000 946.0000 2.4844724E-06
710.0000 958.0000 2.4844724E-06
700.0000 963.1000 2.4844724E-06
600.0000 20.30000 2.4844724E-06
#!/bin/bash
NP=${NP:-16}
NPS=${NPS:-4}
export ACC_DEVICE_TYPE=HOST
export MPIRUN="Mpirun -tag-output -report-bindings --mca mpi_cuda_support 0 -map-by ppr:${NPS}:socket -bind-to none -np ${NP} set_core_device_impair"
#
set -x
set -e
#
rm -f OUTPUT_LISTING1 pipe_name file_for_xtransfer
rm -f PGD00128.*
rm -f DA0128.*
#
ln -sf ../001_pgd1/PGD00128.* .
#
time ${MPIRUN} PREP_IDEAL_CASE${XYZ}
#
&NAM_CONFZ
! NB_PROCIO_R=1 ,
! NB_PROCIO_W=1 ,
LMNH_MPI_BSEND = F ,
LMNH_MPI_ALLTOALLV_REMAP=T
! MPI_BUFFER_SIZE = 40
/
&NAM_LUNITn CINIFILE = "DA0128" , CINIFILEPGD = "PGD00128" /
&NAM_CONFn LUSERV = T, LUSERC = T, LUSERR = T, LUSERI = T,
LUSERS = T, LUSERG = T, LUSERH = F, LUSECI = T /
&NAM_DYNn XTSTEP = 10.00000 ,
CPRESOPT = "ZRESI", NITR = 12
!CPRESOPT = "ZSOLV", NITR = 12
XRELAX = 1., LHORELAX_UVWTH = T, LHORELAX_RV = T, LVE_RELAX = T,
NRIMX = 6, NRIMY = 6, XRIMKMAX = 0.0005, XT4DIFU = 4000 /
&NAM_ADVn CUVW_ADV_SCHEME = "WENO_K", CMET_ADV_SCHEME = "PPM_01",
CSV_ADV_SCHEME = "PPM_01" /
&NAM_PARAMn CTURB = "TKEL" ! "NONE" ! "TKEL",
CRAD = "ECMW",
CCLOUD = "ICE3" ! "NONE" ! "ICE3",
CDCONV = "NONE", CSCONV = "NONE" /
&NAM_PARAM_ICEn CSUBG_AUCV_RC = "NONE",
LRED = F
/
&NAM_PARAM_RADn XDTRAD = 1800., XDTRAD_CLONLY = 1800., LCLEAR_SKY = F,
NRAD_COLNBR = 40 /
&NAM_PARAM_MFSHALLn XIMPL_MF = 1, CMF_UPDRAFT = "EDKF", CMF_CLOUD = "NONE",
LMIXUV = T, LMF_FLX = F /
&NAM_LBCn CLBCX = 2*"OPEN", CLBCY = 2*"OPEN", XCPHASE = 20. /
&NAM_TURBn XIMPL = 1., CTURBLEN = "DEAR", CTURBDIM = "3DIM",
LTURB_FLX = F, LTURB_DIAG = F,
LSIG_CONV = F /
&NAM_CH_MNHCn /
&NAM_CONF CCONF = "START", LFLAT = F, CEQNSYS = "DUR",
LLG=F, NMODEL = 1, NVERB = 0, CEXP = "D0128",
CSEG = "DAR01", CSPLIT = "BSPLITTING"
NHALO=1
/
&NAM_DYN XSEGLEN = 14400.0000 ! 150. ! 14400.0000 , LCORIO = T,
LNUMDIFU = F, LNUMDIFTH = F,
XALKTOP = 0.001, XALZBOT = 22000. /
&NAM_BLANK /
&NAM_NESTING /
&NAM_BACKUP
XBAK_TIME(1,1) = 3600.00000 ! 150. ! 3600.00000
XBAK_TIME(1,2) = 7200.00000
XBAK_TIME(1,3) = 10800.0000
XBAK_TIME(1,4) = 14400.0000
XBAK_TIME(1,5) = 18000.0000
XBAK_TIME(1,6) = 21600.0000
/
&NAM_ISBAn /
&NAM_SEAFLUXn /
&NAM_DIAG_SURFn LSURF_BUDGET=T /
&NAM_DIAG_ISBAn /
&NAM_DIAG_SURF_ATMn /
&NAM_NEBn LSIGMAS = F, LSUBG_COND = F /
! *********************************************************************
! *********************************************************************
! ** **
! ** Parameter file for geometric multigrid code **
! ** **
! *********************************************************************
! *********************************************************************
!
! *********************************************************************
! * General parameters
! *********************************************************************
&parameters_general
savefields = .F. ! Save fields to disk?
/
! *********************************************************************
! * General solver parameters
! *********************************************************************
&parameters_solver
LUseO = F ,
LUseT = T ,
solvertype = 1, ! Solver type:
! 1 : Richardson iteration
! 2 : Conjugate gradient
resreduction = 1e-1 ! 1.0d-10 ! Required relative residual reduction
maxiter = 5 ! 50 ! Maximal number of iterations
/
! *********************************************************************
! * Conjugate gradient parameters
! *********************************************************************
&parameters_conjugategradient
verbose = 10, ! Verbosity level
maxiter = 5, ! Maximal number of iterations
resreduction = 1.0e-1, ! Target residual reduction
n_prec = 1 ! Number of smoother applications in
! preconditioner (N.B.: Using 0 is
! inefficient, as the identity is used
! for preconditioning, instead of using
! unpreconditioned CG.)
/
! *********************************************************************
! * Grid parameters
! *********************************************************************
&parameters_grid
n = 128 , ! 64, ! Number of horizontal grid cells
nz = 72, ! Number of vertical grid cells
L = 204800.0 ! 16000.0 metre * 256 pt grille ! 1.0, ! Size in horizontal direction
H = 19200.0 ! 150.0 metre * 128 niveaux ! 0.01, ! Size in vertical direction
vertbc = 2, ! Boundary conditions at top and bottom of the
! atmosphere. 1 = DIRICHLET, 2 = NEUMANN
! Note that Neumann boundary conditions only work
! for coarsening in the horizontal only, as they are
! not yet implemented in the prolongation operator.
graded = .F. ! Is the grid graded in the vertical direction?
/
! *********************************************************************
! * Parallel communication parameters
! *********************************************************************
&parameters_communication
halo_size = 1 ! Size of halos (has to be 1 or 2)
/
! *********************************************************************
! * Model parameters
! *********************************************************************
!
! parameters of the Helmholtz operator
!
! -omega2*(d^2/dy^2 + d^2/dy^2 + lambda2*d^2/dz^2) u + delta u = RHS
!
&parameters_model
omega2 = 1.0,
lambda2 = 1.0 ! 100.0, ! Vertical coupling
delta = 0.0d0 ! Size of constant term
/
! *********************************************************************
! * Smoother parameters
! *********************************************************************
!
! parameters of the smoother
!
&parameters_smoother
smoother = 6, ! Smoother method
! 3 = line SOR
! 4 = line SSOR
! 6 = line Jacobi
ordering = 2, ! Ordering of grid points (for smoother)
! 1 = lexicographic
! 2 = red-black ordering
!rho = 0.6666666666666666d0 ! Overrelaxation parameter
rho = 0.8d0 ! Overrelaxation parameter
/
! *********************************************************************
! * Multigrid parameters
! *********************************************************************
&parameters_multigrid
verbose = 10, ! Verbosity level
n_lev = 8, ! Number of levels
iswitch_cpu_gpu = 100 ! /!\ =100 deactive switch cpu <-> gpu computation | work only with MANAGED Memory + nvhpc
lev_split = 3, ! First level where data is pulled together
n_presmooth = 1, ! Number of presmoothing steps
n_postsmooth = 1, ! Number of postsmoothing steps
n_coarsegridsmooth = 1, ! Number of smoothing steps on coarsest level
prolongation = 2 ! 2 best after modif !! ! Prologation method
! 1 = constant interpolation
! 2 = (tri-) linear interpolation
restriction = 1, ! Restriction method
! 1 = cell average
! 2 = Khalil
coarsegridsolver = 1 ! Solver on coarsest grid
! 1 = use smoother
! 2 = Conjugate gradient
/
#export PGI_ACC_POOL_ALLOC=0
export PGI_ACC_SYNCHRONOUS=1
NP=${NP:-16}
NPS=${NPS:-4}
export MPIRUN=${MPIRUN:-"Mpirun -tag-output -bind-to none -map-by ppr:${NPS}:socket -x PGI_ACC_POOL_ALLOC -x PGI_ACC_SYNCHRONOUS -np ${NP} set_core_device_impair "}
#
set -x
set -e
#
rm -f DA0128.*
rm -f PGD00128.*
rm -f D0128.1.DAR01.* OUTPUT_LISTING* pipe_name
#
ln -sf ../001_pgd1/PGD00128.{des,nc} .
ln -sf ../002_prep_ideal_case/DA0128.{des,nc} .
#
time ${MPIRUN} MESONH${XYZ}
&NAM_CONFIO
LIO_ALLOW_NO_BACKUP = T , LIO_NO_WRITE = T
/
&NAM_CONFZ
! NB_PROCIO_R=1 ,
! NB_PROCIO_W=1 ,
LMNH_MPI_BSEND = F ,
LMNH_MPI_ALLTOALLV_REMAP=T
! MPI_BUFFER_SIZE = 40
!NZ_PROC=1
/
&NAM_LUNITn CINIFILE = "D0128.1.DAR01.004" , CINIFILEPGD = "PGD00128" /
&NAM_CONFn LUSERV = T, LUSERC = T, LUSERR = T, LUSERI = T,
LUSERS = T, LUSERG = T, LUSERH = F, LUSECI = T /
&NAM_DYNn XTSTEP = 10.00000 ,
CPRESOPT = "ZRESI",
!CPRESOPT = "ZSOLV",
NITR = 12,
XRELAX = 1., LHORELAX_UVWTH = T, LHORELAX_RV = T, LVE_RELAX = T,
NRIMX = 6, NRIMY = 6, XRIMKMAX = 0.0005, XT4DIFU = 4000 /
&NAM_ADVn CUVW_ADV_SCHEME = "WENO_K", CMET_ADV_SCHEME = "PPM_01",
CSV_ADV_SCHEME = "PPM_01" /
&NAM_PARAMn CTURB = "TKEL", ! "NONE" , ! "TKEL",
CRAD = "ECMWF",
CCLOUD = "ICE3", ! "NONE" , ! "ICE3",
CDCONV = "NONE", CSCONV = "NONE" /
&NAM_PARAM_ICEn CSUBG_AUCV_RC = "NONE",
LRED = F
/
&NAM_PARAM_RADn XDTRAD = 1800., XDTRAD_CLONLY = 1800., LCLEAR_SKY = F,
NRAD_COLNBR = 40 /
&NAM_PARAM_MFSHALLn XIMPL_MF = 1, CMF_UPDRAFT = "EDKF", CMF_CLOUD = "NONE",
LMIXUV = T, LMF_FLX = F /
&NAM_LBCn CLBCX = 2*"OPEN", CLBCY = 2*"OPEN", XCPHASE = 20. /
&NAM_TURBn XIMPL = 1., CTURBLEN = "DEAR", CTURBDIM = "3DIM",
LTURB_FLX = F, LTURB_DIAG = F,
LSIG_CONV = F /
&NAM_CH_MNHCn /
&NAM_CONF CCONF = "RESTA", LFLAT = F, CEQNSYS = "DUR",
LLG=F, NMODEL = 1, NVERB = 0, CEXP = "D0128",
CSEG = "DAR02", CSPLIT = "BSPLITTING"
NHALO=1
LCHECK = F /
&NAM_DYN XSEGLEN = 1000.0 ! 150.0000 ,
LCORIO = T,
LNUMDIFU = F, LNUMDIFTH = F,
XALKTOP = 0.001, XALZBOT = 22000. /
&NAM_BLANK /
&NAM_NESTING /
&NAM_BACKUP
XBAK_TIME(1,1) = 150.0 ! 3600.00000 ! 75. ! 3600.00000
XBAK_TIME(1,2) = 7200.00000
XBAK_TIME(1,3) = 10800.0000
XBAK_TIME(1,4) = 14400.0000
XBAK_TIME(1,5) = 18000.0000
XBAK_TIME(1,6) = 21600.0000
/
&NAM_ISBAn /
&NAM_SEAFLUXn /
&NAM_DIAG_SURFn LSURF_BUDGET=T /
&NAM_DIAG_ISBAn /
&NAM_DIAG_SURF_ATMn /
&NAM_NEBn LSIGMAS = F, LSUBG_COND = F /