Changeset 4230 for dynamico_lmdz


Ignore:
Timestamp:
Jan 16, 2020, 3:25:44 PM (5 years ago)
Author:
dubos
Message:

simple_physics : able to run without plugins

Location:
dynamico_lmdz/simple_physics
Files:
2 added
1 deleted
9 edited

Legend:

Unmodified
Added
Removed
  • dynamico_lmdz/simple_physics/config/LMDZ/TEST_PARAM/check.sh

    r4196 r4230  
    22#grep -A 1 'd abs' --no-group-separator gcm.log | grep -v 'd abs'  > gcm.output
    33grep -A 1 'd abs' --no-group-separator gcm.log | grep -v 'd abs' | head > gcm.output
    4 diff -s gcm.output gcm.output.$1
    5 diff gcm.output gcm.output.$1
     4diff -s gcm.output gcm.output.$1 && diff gcm.output gcm.output.$1
  • dynamico_lmdz/simple_physics/config/LMDZ/TEST_PARAM/gcm.output.IRENE

    r4182 r4230  
    1    100762.54565224030        5.0634871262939364E-003  0.99208256187172461     
    2    99914.867101038908        5.0208898556170188E-003  0.99214890623452645     
    3    99253.329187461582        4.9876464645606357E-003  0.99220068520671523     
    4    98952.802170607873        4.9725444772984817E-003  0.99222420853053495     
    5    99084.198759728839        4.9791473765518337E-003  0.99221392358122529     
    6    99371.405615273499        4.9935800033400930E-003  0.99219144309525686     
    7    99701.915155864132        5.0101886627687050E-003  0.99216557381701764     
    8    100002.48069994792        5.0252925860888665E-003  0.99214204886784030     
    9    100291.32387703673        5.0398074407825419E-003  0.99211944194159085     
    10    100564.55205486271        5.0535376155414983E-003  0.99209805763060788     
     1  [INF rad_sw]   100762.54565224030        5.0634871262939364E-003  0.99208256155400709
     2  [INF rad_sw]   99914.880411921549        5.0208905245112245E-003  0.99214890393244037
     3  [INF rad_sw]   99253.356956060161        4.9876478599793451E-003  0.99220068021623176
     4  [INF rad_sw]   98952.829415248460        4.9725458463874229E-003  0.99222420140509127
     5  [INF rad_sw]   99084.107098940629        4.9791427704433027E-003  0.99221392294421296
     6  [INF rad_sw]   99371.272555205171        4.9935733168482163E-003  0.99219144222902989
     7  [INF rad_sw]   99701.658751878960        5.0101757780378784E-003  0.99216557848027787
     8  [INF rad_sw]   100002.12719360919        5.0252748218017141E-003  0.99214205635455444
     9  [INF rad_sw]   100290.17486954234        5.0397497012264576E-003  0.99211950625490253
     10  [INF rad_sw]   100562.38519882695        5.0534287273869697E-003  0.99209819550986678
  • dynamico_lmdz/simple_physics/config/LMDZ/TEST_PARAM/planete.def

    r4178 r4230  
    88aphelie=150.
    99peri_day=0.
    10 obliquit=0.
     10obliquit=23.
    1111Cd_mer=.01
    1212Cd_ter=.01
  • dynamico_lmdz/simple_physics/config/LMDZ/TEST_PARAM/traceur.def

    r4224 r4230  
    1 2
     13
    2214 14 H2Ov
    3310 10 H2Ol
  • dynamico_lmdz/simple_physics/config/LMDZ/USEFUL

    r4208 r4230  
    1 ./build_lmdz_phyparam.sh patch_lmdz
     1./build_lmdz_phyparam.sh patch_lmdz -debug
    22./build_lmdz_phyparam.sh full
    33(cd TEST_PARAM/; time ./gcm.e | tee gcm.log | grep '*    pas ' && ./check.sh IRENE)
     4grep WRN TEST_PARAM/gcm.log | sort -u
  • dynamico_lmdz/simple_physics/config/LMDZ/build_lmdz_phyparam.sh

    r4224 r4230  
    3232    ln -sf $ROOT/phyparam/dynphy_lonlat/* .
    3333    cd $LMDZ
    34     echo "./makelmdz_fcm -rrtm false  -v false -arch local -j 8 -p param -d 32x32x39 gcm" > compile.sh
     34    echo "./makelmdz_fcm $* -rrtm false  -v false -arch local -j 8 -p param -d 32x32x39 gcm" > compile.sh
    3535    chmod +x compile.sh
    3636    ./compile.sh
     
    5858ROOT=$(cd -P ../.. ; pwd)
    5959
    60 cmd_$1
     60CMD=$1
     61shift
     62cmd_$CMD $*
     63
  • dynamico_lmdz/simple_physics/phyparam/physics/iniphyparam_mod.F90

    r4229 r4230  
    4343    CALL read_param('Cd_mer',.01      ,Cd_mer,'Cd_mer')
    4444    CALL read_param('Cd_ter',.01      ,Cd_ter,'Cd_ter')
    45     CALL read_param('I_mer',30000.    ,I_mer,'I_mer')
    46     CALL read_param('I_ter',30000.    ,I_ter,'I_ter')
     45    CALL read_param('I_mer',3000.    ,I_mer,'I_mer')
     46    CALL read_param('I_ter',3000.    ,I_ter,'I_ter')
    4747    CALL read_param('alb_ter',.112    ,alb_ter,'alb_ter')
    4848    CALL read_param('alb_mer',.112    ,alb_mer,'alb_mer')
     
    6969    CALL check_mismatch('R', pr, r)
    7070    CALL check_mismatch('cpp', pcpp, cpp)
     71    LOG_WARN('iniphyparam')
    7172
    7273    WRITELOG(*,*) 'Activation de la physique:'
     
    9293    dtphys=ptimestep
    9394
    94     LOG_INFO('iniphyparama')
     95    LOG_INFO('iniphyparam')
    9596  END SUBROUTINE iniphyparam
    9697
     
    99100    REAL, INTENT(IN) :: a,b
    100101    IF(a /= b) THEN
    101        PRINT *, 'Phys/dyn mismatch for ', name, ' : ',a,b
     102       WRITELOG(*,*) 'Phys/dyn mismatch for ', name, ' : ',a,b
    102103    END IF
    103104  END SUBROUTINE check_mismatch
  • dynamico_lmdz/simple_physics/phyparam/physics/logging.F90

    r4229 r4230  
    5050  SUBROUTINE missing_plugin(name, mod)
    5151    CHARACTER(*), INTENT(IN) :: name, mod
    52     PRINT *, 'FATAL : plugin ', name, ' not provided by the driver program'
    53     PRINT *, '        see ', mod
    54     STOP
     52    WRITE(logging_buf(1),*) 'WARNING : plugin ', name, ' not provided by the driver program'
     53    WRITE(logging_buf(2),*) '        see ', mod
     54    logging_lineno=2
     55    CALL flush_log(log_level_warn, 'missing_plugin')
    5556  END SUBROUTINE missing_plugin
    5657
     
    5960    CHARACTER(*), INTENT(IN) :: tag
    6061#ifndef XCODEML
    61     IF(.NOT.ASSOCIATED(flush_plugin)) flush_plugin => default_flush_plugin
     62    IF(.NOT.ASSOCIATED(flush_plugin)) THEN
     63       flush_plugin => default_flush_plugin
     64       WRITE(*,*) 'WARNING : plugin flush_plugin not provided by the driver program'
     65       WRITE(*,*) '        see logging.F90'
     66    END IF
    6267    IF(logging_lineno>0 .AND. lev<=max_log_level) CALL flush_plugin(lev, TRIM(tag), logging_buf(1:logging_lineno))
    6368    logging_lineno=0
     
    7378    WRITE(prefix,*) '[', dbtag(lev), ' ', tag, ']'
    7479    DO i=1, SIZE(buf)
    75        PRINT *, TRIM(prefix), TRIM(buf(i))
     80       WRITE(*,*) TRIM(prefix), TRIM(buf(i))
    7681    END DO
    7782  END SUBROUTINE default_flush_plugin
     
    8186    logging_lineno = logging_lineno+1
    8287#ifndef XCODEML
    83     IF(.NOT.ASSOCIATED(log_gridpoint_plugin)) log_gridpoint_plugin => default_log_gridpoint
     88    IF(.NOT.ASSOCIATED(log_gridpoint_plugin)) THEN
     89       log_gridpoint_plugin => default_log_gridpoint
     90       WRITE(*,*) 'WARNING : plugin log_gridpoint_plugin not provided by the driver program'
     91       WRITE(*,*) '        see logging.F90'
     92    END IF
    8493    CALL log_gridpoint_plugin(index, logging_buf(logging_lineno))
    8594#endif
  • dynamico_lmdz/simple_physics/phyparam/physics/read_param_mod.F90

    r4229 r4230  
    11MODULE read_param_mod
    2   USE logging, ONLY : missing_plugin
     2#include "use_logging.h"
    33  IMPLICIT NONE
    44  PRIVATE
     
    5454    REAL, INTENT(OUT)        :: val
    5555#ifndef XCODEML
    56     IF(.NOT.ASSOCIATED(read_paramr_plugin)) CALL missing_plugin('read_paramr','read_param_mod')
    57     CALL read_paramr_plugin(name, defval, val, comment)
     56    IF(.NOT.ASSOCIATED(read_paramr_plugin)) THEN
     57       CALL missing_plugin('read_paramr','read_param_mod')
     58       val = defval
     59    ELSE
     60       CALL read_paramr_plugin(name, defval, val, comment)
     61    END IF
    5862#endif
     63    WRITELOG(*,*) name, ' = ', val
     64    LOG_INFO('read_param')
    5965  END SUBROUTINE read_paramr
    6066
     
    6470    INTEGER, INTENT(OUT)     :: val
    6571#ifndef XCODEML
    66     IF(.NOT.ASSOCIATED(read_parami_plugin)) CALL missing_plugin('read_parami','read_param_mod')
    67     CALL read_parami_plugin(name, defval, val, comment)
     72    IF(.NOT.ASSOCIATED(read_parami_plugin)) THEN
     73       CALL missing_plugin('read_parami','read_param_mod')
     74       val = defval
     75    ELSE
     76       CALL read_parami_plugin(name, defval, val, comment)
     77    END IF
    6878#endif
     79    WRITELOG(*,*) name, ' = ', val
     80    LOG_INFO('read_param')
    6981  END SUBROUTINE read_parami
    7082
     
    7486    LOGICAL, INTENT(OUT)     :: val
    7587#ifndef XCODEML
    76     IF(.NOT.ASSOCIATED(read_paramr_plugin)) CALL missing_plugin('read_paramb','read_param_mod')
    77     CALL read_paramb_plugin(name, defval, val, comment)
     88    IF(.NOT.ASSOCIATED(read_paramr_plugin)) THEN
     89       CALL missing_plugin('read_paramb','read_param_mod')
     90       val = defval
     91    ELSE
     92       CALL read_paramb_plugin(name, defval, val, comment)
     93    END IF
    7894#endif
     95    WRITELOG(*,*) name, ' = ', val
     96    LOG_INFO('read_param')
    7997  END SUBROUTINE read_paramb
    80 
     98 
    8199END MODULE read_param_mod
Note: See TracChangeset for help on using the changeset viewer.