Changeset 818 for palm/trunk


Ignore:
Timestamp:
Feb 8, 2012 4:11:23 PM (12 years ago)
Author:
maronga
Message:

bugfix: namelist file check now possible for topography and re-enabled. mrungui update (-z option)

Location:
palm/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SCRIPTS/mbuild

    r811 r818  
    128128     # 31/01/12 - BjornM- bugfix for compilation of utility programs on
    129129     #                    multiple localhost branches
     130     # 08/03/12 - BjornM- bugfix: cpp directive for namelist check program
     131     #                    corrected
    130132
    131133
     
    14211423             rm -rf ${mainprog}_sources_check.tar
    14221424
    1423              copts_check="-cpp -D_parallel -D__check"
     1425             copts_check="-cpp -D__parallel -D__check"
    14241426             make  -f Makefile_check $make_options F90=$compiler_name_ser  COPT="$copts_check"
    14251427
     
    14331435             cd $check_depository_path
    14341436             printf "\n\n"
    1435              echo "  *** skipped compilation of mrun GUI (already."       
     1437             echo "  *** skipped compilation of mrun GUI."       
    14361438             printf "\n\n"
    14371439             echo "  *** skipped compilation of check_namelist_files."           
  • palm/trunk/SCRIPTS/mrun

    r815 r818  
    239239     # 03/02/12 - BjornM - namelist file check temporary disabled
    240240     #                     until severel bugs are fixed
     241     # 08/02/12 - BjornM - bugfixes: skipping namelist file check in case of
     242     #                     restart runs. check is now possible with topography
     243     #                     and the -v (silent) option is considered
    241244 
    242245    # VARIABLENVEREINBARUNGEN + DEFAULTWERTE
     
    24042407
    24052408#### PERFORM PARAMETER FILE CHECK (COUPLED RUNS ARE NOT SUPPORTED YET)
    2406  skip_check=true
    2407  if [[ $check_namelist_files == false || $fromhost != $localhost || $run_coupled_model == true ]]
     2409 skip_check=false
     2410 if [[ $check_namelist_files == false || $fromhost != $localhost || $run_coupled_model == true || $restart_run == true ]]
    24082411 then
    24092412    skip_check=true
     
    24632466       printf "\n  +++ no PARIN list entry found for d3f in the configuration file."
    24642467    fi
     2468#   GET TOPOGRAPHY PARAMETER FILE SUFFIX (USUALLY "_P3DF"). THIS FILE MIGHT IS
     2469#   NOT NECESSARILY REQUIRED
     2470    line=""
     2471    found=false
     2472    grep  "d3f" $config_file | grep "TOPOGRAPHY_DATA"  >  $tmp_check
     2473    while read line1
     2474    do
     2475       line="$line1"
     2476       if [[ "$line" != ""  &&  $(echo $line | cut -c1) != "#" ]]
     2477       then
     2478          topo_suffix=`echo $line | tr -s " " | cut -d" " -s -f5`
     2479          found=true
     2480       fi
     2481    done < $tmp_check
     2482
     2483    if [[ $found = false ]]
     2484    then
     2485       printf "\n  +++ no TOPOGRAPHY list entry found in the configuration file."
     2486    fi
    24652487
    24662488    rm -rf ${working_directory}/tmp_check
     
    24982520          printf "\n\n"
    24992521
    2500           while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
    2501           do
    2502              printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
    2503              read  answer
    2504           done
    2505           if [[ $answer = a  ||  $answer = A ]]
    2506           then
    2507              printf "\n  +++ Aborting...."
    2508              locat=normal; exit
     2522          if [[ $silent == false ]]
     2523          then
     2524             while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
     2525             do
     2526                printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
     2527                read  answer
     2528             done
     2529             if [[ $answer = a  ||  $answer = A ]]
     2530             then
     2531                printf "\n  +++ Aborting...."
     2532                locat=normal; exit
     2533             fi
    25092534          fi
    25102535       else
     
    25412566          answer=dummy
    25422567          printf "\n\n"
    2543           while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
    2544           do
    2545              printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
    2546              read  answer
    2547           done
    2548           if [[ $answer = a  ||  $answer = A ]]
    2549           then
    2550              printf "\n  +++ Aborting..."
    2551              rm -rf  $check_sources
    2552              locat=normal; exit
     2568          if [[ $silent == false ]]
     2569          then
     2570             while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
     2571             do
     2572                printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
     2573                read  answer
     2574             done
     2575             if [[ $answer = a  ||  $answer = A ]]
     2576             then
     2577                printf "\n  +++ Aborting..."
     2578                rm -rf  $check_sources
     2579                locat=normal; exit
     2580             else
     2581                skip_check=true
     2582             fi
    25532583          else
    25542584             skip_check=true
     
    25632593    then
    25642594       cp $working_directory/JOBS/$fname/INPUT/${fname}${p3df_suffix} ./PARINF   
     2595    fi
     2596
     2597
     2598    if [[ -f $working_directory/JOBS/$fname/INPUT/${fname}${topo_suffix} && $skip_check == false ]]
     2599    then
     2600       printf "\n  *** adding topography data"
     2601       cp $working_directory/JOBS/$fname/INPUT/${fname}${topo_suffix} ./TOPOGRAPHY_DATA
     2602
     2603#      IN CASE OF TOPOGRAPHY AND HIGH GRID POINT NUMBERS, THE STACK SIZE
     2604#      MUST BE INCREASED. THIS IS DUE TO THE ARRAY nzb_local AND topo_height,
     2605#      WHICH REQUIRE SUFFICIENT MEMORY
     2606       ulimit -s unlimited         
    25652607    fi
    25662608
     
    25772619
    25782620#   SAFETY CHECK: ONLY PROCEED IF THE PARAMETER CHECK PROGRAM WAS PROPERLY COMPILED
    2579     if [[ ! -f check_namelist_files.x ]] then
     2621    if [[ ! -f check_namelist_files.x && $skip_check == false ]] then
    25802622       printf "\n  +++ WARNING: check_namelist_files.x not found."
    25812623       answer=dummy
    25822624       printf "\n\n"
    2583        while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
    2584        do
    2585           printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
    2586           read  answer
    2587        done
    2588        if [[ $answer = a  ||  $answer = A ]]
    2589        then
    2590           printf "\n  +++ Aborting..."
    2591           rm -rf  $check_sources
    2592           locat=normal; exit
    2593        else
    2594           printf "\n  *** Skipping parameter file check."
    2595        fi       
     2625
     2626       if [[ $silent == false ]]
     2627       then
     2628          while [[ "$answer" != c  &&  "$answer" != C  && "$answer" != a  &&  "$answer" != A ]]
     2629          do
     2630             printf " >>> continue anyway (c(ontinue)/a(bort)) ?  "
     2631             read  answer
     2632          done
     2633          if [[ $answer = a  ||  $answer = A ]]
     2634          then
     2635             printf "\n  +++ Aborting..."
     2636             rm -rf  $check_sources
     2637             locat=normal; exit
     2638          else
     2639             printf "\n  *** Skipping parameter file check."
     2640         
     2641          fi
     2642      fi
     2643       
    25962644    elif [[ $skip_check == false ]]
    25972645    then
     
    26942742 fi
    26952743
     2744    # DELETE TEMPORARY DIRECTORY AND FINISH NAMELIST FILE CHECK   
     2745 rm -rf  $check_sources
    26962746 cd $working_directory
    26972747
  • palm/trunk/SOURCE/Makefile_check

    r808 r818  
    44# Current revisions:
    55# ------------------
    6 #
     6# Added all user routines.
    77#
    88# Former revisions:
     
    2727      message.f90 modules.f90 package_parin.f90 parin.f90 poisfft.f90 \
    2828      poisfft_hybrid.f90 singleton.f90 subsidence.f90 temperton_fft.f90 \
     29      user_3d_data_averaging.f90 user_actions.f90 \
     30      user_additional_routines.f90 user_advec_particles.f90 \
    2931      user_check_data_output.f90 user_check_data_output_pr.f90 \
    30       user_check_parameters.f90 user_init.f90 user_init_3d_model.f90 \
    31       user_init_grid.f90 user_init_particles.f90 user_init_plant_canopy.f90 \
    32       user_module.f90 user_parin.f90  \
     32      user_check_parameters.f90 user_data_output_2d.f90 \
     33      user_data_output_3d.f90 user_data_output_dvrp.f90 user_data_output_mask.f90 \
     34      user_define_netcdf_grid.f90 user_dvrp_coltab.f90 user_header.f90 \
     35      user_init.f90 user_init_3d_model.f90 user_init_grid.f90 \
     36      user_init_particles.f90 user_init_plant_canopy.f90 \
     37      user_last_actions.f90 user_module.f90 user_parin.f90 \
     38      user_particle_attributes.f90 user_read_restart_data.f90 \
     39      user_spectra.f90 user_statistics.f90 \
     40
     41
    3342
    3443
     
    3847      modules.o package_parin.o parin.o poisfft.o \
    3948      poisfft_hybrid.o singleton.o subsidence.o temperton_fft.o \
    40       user_check_data_output.o user_check_data_output_pr.o \
    41       user_check_parameters.o user_init.o user_init_3d_model.o \
    42       user_init_grid.o user_init_particles.o user_init_plant_canopy.o \
    43       user_module.o user_parin.o  \
     49      user_3d_data_averaging.o user_actions.o user_additional_routines.o \
     50      user_advec_particles.o user_check_data_output.o \
     51      user_check_data_output_pr.o user_check_parameters.o \
     52      user_data_output_2d.o user_data_output_3d.o user_data_output_mask.o user_data_output_dvrp.o \
     53      user_define_netcdf_grid.o user_dvrp_coltab.o user_header.o \
     54      user_init.o user_init_3d_model.o user_init_grid.o \
     55      user_init_particles.o user_init_plant_canopy.o user_last_actions.o \
     56      user_module.o user_parin.o user_particle_attributes.o \
     57      user_read_restart_data.o user_spectra.o user_statistics.o \
    4458
    4559CC = cc
     
    88102subsidence.o: modules.o
    89103temperton_fft.o: modules.o
     104user_3d_data_averaging.o: modules.o user_module.o
     105user_actions.o: modules.o user_module.o
     106user_additional_routines.o: modules.o user_module.o
     107user_advec_particles.o: modules.o user_module.o
     108user_check_data_output.o: modules.o user_module.o
     109user_check_data_output_pr.o: modules.o user_module.o
     110user_check_parameters.o: modules.o user_module.o
     111user_data_output_2d.o: modules.o user_module.o
     112user_data_output_3d.o: modules.o user_module.o
     113user_data_output_mask.o: modules.o user_module.o
     114user_data_output_dvrp.o: modules.o user_module.o
     115user_define_netcdf_grid.o: modules.o user_module.o
     116user_dvrp_coltab.o: modules.o user_module.o
     117user_header.o: modules.o user_module.o
    90118user_init.o: modules.o user_module.o
    91119user_init_3d_model.o: modules.o user_module.o
     
    93121user_init_particles.o: modules.o user_module.o
    94122user_init_plant_canopy.o: modules.o user_module.o
     123user_last_actions.o: modules.o user_module.o
    95124user_module.o: user_module.f90
    96125user_parin.o: modules.o user_module.o
    97 user_check_parameters.o: modules.o user_module.o
    98 user_check_data_output.o: modules.o user_module.o
    99 user_check_data_output_pr.o: modules.o user_module.o
     126user_particle_attributes.o: modules.o user_module.o
     127user_read_restart_data.o: modules.o user_module.o
     128user_spectra.o: modules.o user_module.o
     129user_statistics.o: modules.o user_module.o
  • palm/trunk/SOURCE/check_namelist_files.f90

    r808 r818  
    353510  CONTINUE
    3636
     37
    3738!
    3839!-- Read control parameters from NAMELIST files and read environment-variables1
     
    4849
    4950
    50 !
    5151!-- Check control parameters and deduce further quantities   
    5252    CALL check_parameters
    5353
    5454
     55
    5556 END PROGRAM check_namelist_files
  • palm/trunk/SOURCE/init_grid.f90

    r810 r818  
    44! Current revisions:
    55! -----------------
    6 !
     6! Bugfix: topo_height is only required if topography is used. It is thus now
     7! allocated in the topography branch
    78!
    89! Former revisions:
     
    3839!
    3940! 555 2010-09-07 07:32:53Z raasch
    40 ! Bugfix: default setting of nzb_local for flat topographie
     41! Bugfix: default setting of nzb_local for flat topography
    4142!
    4243! 274 2009-03-26 15:11:21Z heinze
     
    100101    REAL    ::  dx_l, dy_l, dz_stretched
    101102
    102     REAL, DIMENSION(0:ny,0:nx)          ::  topo_height
     103    REAL, DIMENSION(:,:), ALLOCATABLE   ::  topo_height
    103104
    104105    REAL, DIMENSION(:,:,:), ALLOCATABLE ::  distance
     
    331332    ALLOCATE( l_wall(nzb:nzt+1,nysg:nyng,nxlg:nxrg) )
    332333
     334
    333335    nzb_s_inner = nzb;  nzb_s_outer = nzb
    334336    nzb_u_inner = nzb;  nzb_u_outer = nzb
     
    517519       CASE ( 'read_from_file' )
    518520
     521          ALLOCATE ( topo_height(0:ny,0:nx) )
     522
    519523          DO  ii = 0, io_blocks-1
    520524             IF ( ii == io_group )  THEN
     
    552556             ENDDO
    553557          ENDDO
     558
     559          DEALLOCATE ( topo_height )
    554560!
    555561!--       Add cyclic boundaries (additional layers are for calculating
  • palm/trunk/UTIL/mrungui/mainwindow.cpp

    r812 r818  
    22// Current revisions:
    33// -----------------
    4 //
     4// New: flag parameter -z implemented (used for skipping parameter file check)
    55//
    66// Former revisions:
     
    199199    ui->check_advanced->setEnabled(false);
    200200    ui->check_verbose->setEnabled(false);
     201    ui->check_namelist_check->setEnabled(false);
    201202    ui->button_start->setEnabled(false);
    202203    ui->button_start->setText("wait...");
     
    255256    ui->check_advanced->setEnabled(true);
    256257    ui->check_verbose->setEnabled(true);
     258    ui->check_namelist_check->setEnabled(true);
    257259    ui->button_start->setEnabled(true);
    258260    ui->action_save->setEnabled(true);
     
    990992    }
    991993
     994    status = ui->check_namelist_check->checkState();
     995
     996    if (status == 2)
     997    {
     998        activate_flag("z");
     999    }
     1000    else
     1001    {
     1002        deactivate_flag("z");
     1003    }
     1004
    9921005    status = ui->check_A->checkState();
    9931006
     
    14141427            {
    14151428               ui->check_verbose->setChecked(true);
     1429            }
     1430            else if ( parameter == "z")
     1431            {
     1432               ui->check_namelist_check->setChecked(true);
    14161433            }
    14171434            else if ( parameter == "A")
  • palm/trunk/UTIL/mrungui/mainwindow.ui

    r809 r818  
    4646     <rect>
    4747      <x>10</x>
    48       <y>590</y>
     48      <y>595</y>
    4949      <width>901</width>
    50       <height>71</height>
     50      <height>61</height>
    5151     </rect>
    5252    </property>
     
    9090      <rect>
    9191       <x>10</x>
    92        <y>40</y>
     92       <y>35</y>
    9393       <width>881</width>
    9494       <height>25</height>
     
    400400     <rect>
    401401      <x>10</x>
    402       <y>325</y>
     402      <y>320</y>
    403403      <width>491</width>
    404       <height>261</height>
     404      <height>271</height>
    405405     </rect>
    406406    </property>
     
    690690      <rect>
    691691       <x>7</x>
    692        <y>160</y>
     692       <y>155</y>
    693693       <width>481</width>
    694694       <height>16</height>
     
    703703      <rect>
    704704       <x>10</x>
    705        <y>180</y>
     705       <y>170</y>
    706706       <width>121</width>
    707707       <height>23</height>
     
    716716      <rect>
    717717       <x>10</x>
    718        <y>205</y>
     718       <y>195</y>
    719719       <width>271</width>
    720720       <height>23</height>
     
    777777      <rect>
    778778       <x>10</x>
    779        <y>230</y>
     779       <y>220</y>
    780780       <width>261</width>
    781781       <height>23</height>
     
    783783     </property>
    784784     <property name="text">
    785       <string>No prompt on confirmation</string>
     785      <string>No prompt on confirmation (silent)</string>
    786786     </property>
    787787    </widget>
     
    793793      <rect>
    794794       <x>130</x>
    795        <y>180</y>
     795       <y>170</y>
    796796       <width>241</width>
    797797       <height>21</height>
     
    806806     <property name="text">
    807807      <string/>
     808     </property>
     809    </widget>
     810    <widget class="QCheckBox" name="check_namelist_check">
     811     <property name="geometry">
     812      <rect>
     813       <x>10</x>
     814       <y>245</y>
     815       <width>261</width>
     816       <height>23</height>
     817      </rect>
     818     </property>
     819     <property name="text">
     820      <string>Skip namelist file check</string>
    808821     </property>
    809822    </widget>
     
    13601373    <addaction name="action_about"/>
    13611374   </widget>
    1362    <widget class="QMenu" name="menuTools">
    1363     <property name="title">
    1364      <string>Tools</string>
    1365     </property>
    1366     <addaction name="actionCheck_parameter_file"/>
    1367    </widget>
    13681375   <addaction name="menuStart"/>
    1369    <addaction name="menuTools"/>
    13701376   <addaction name="menuHelp"/>
    13711377  </widget>
     
    14841490    <hint type="sourcelabel">
    14851491     <x>160</x>
    1486      <y>687</y>
     1492     <y>657</y>
    14871493    </hint>
    14881494    <hint type="destinationlabel">
     
    15001506    <hint type="sourcelabel">
    15011507     <x>73</x>
    1502      <y>687</y>
     1508     <y>657</y>
    15031509    </hint>
    15041510    <hint type="destinationlabel">
     
    17561762    <hint type="sourcelabel">
    17571763     <x>72</x>
    1758      <y>571</y>
     1764     <y>541</y>
    17591765    </hint>
    17601766    <hint type="destinationlabel">
     
    17721778    <hint type="sourcelabel">
    17731779     <x>76</x>
    1774      <y>596</y>
     1780     <y>566</y>
    17751781    </hint>
    17761782    <hint type="destinationlabel">
     
    17881794    <hint type="sourcelabel">
    17891795     <x>53</x>
    1790      <y>626</y>
     1796     <y>591</y>
    17911797    </hint>
    17921798    <hint type="destinationlabel">
     
    19321938    <hint type="sourcelabel">
    19331939     <x>119</x>
    1934      <y>407</y>
     1940     <y>403</y>
    19351941    </hint>
    19361942    <hint type="destinationlabel">
     
    19481954    <hint type="sourcelabel">
    19491955     <x>149</x>
    1950      <y>431</y>
     1956     <y>428</y>
    19511957    </hint>
    19521958    <hint type="destinationlabel">
     
    19801986    <hint type="sourcelabel">
    19811987     <x>179</x>
    1982      <y>482</y>
     1988     <y>478</y>
    19831989    </hint>
    19841990    <hint type="destinationlabel">
     
    20122018    <hint type="sourcelabel">
    20132019     <x>361</x>
    2014      <y>429</y>
     2020     <y>428</y>
    20152021    </hint>
    20162022    <hint type="destinationlabel">
     
    20442050    <hint type="sourcelabel">
    20452051     <x>262</x>
    2046      <y>508</y>
     2052     <y>503</y>
    20472053    </hint>
    20482054    <hint type="destinationlabel">
     
    20602066    <hint type="sourcelabel">
    20612067     <x>324</x>
    2062      <y>504</y>
     2068     <y>503</y>
    20632069    </hint>
    20642070    <hint type="destinationlabel">
     
    21712177   <hints>
    21722178    <hint type="sourcelabel">
    2173      <x>906</x>
     2179     <x>900</x>
    21742180     <y>513</y>
    21752181    </hint>
     
    21872193   <hints>
    21882194    <hint type="sourcelabel">
    2189      <x>919</x>
     2195     <x>900</x>
    21902196     <y>538</y>
    21912197    </hint>
     
    22032209   <hints>
    22042210    <hint type="sourcelabel">
    2205      <x>917</x>
     2211     <x>900</x>
    22062212     <y>563</y>
    22072213    </hint>
     
    22522258    <hint type="sourcelabel">
    22532259     <x>307</x>
    2254      <y>675</y>
     2260     <y>657</y>
    22552261    </hint>
    22562262    <hint type="destinationlabel">
     
    22672273   <hints>
    22682274    <hint type="sourcelabel">
    2269      <x>904</x>
    2270      <y>333</y>
     2275     <x>900</x>
     2276     <y>343</y>
    22712277    </hint>
    22722278    <hint type="destinationlabel">
     
    24012407     <x>4</x>
    24022408     <y>122</y>
     2409    </hint>
     2410   </hints>
     2411  </connection>
     2412  <connection>
     2413   <sender>check_namelist_check</sender>
     2414   <signal>stateChanged(int)</signal>
     2415   <receiver>MainWindow</receiver>
     2416   <slot>check_flags()</slot>
     2417   <hints>
     2418    <hint type="sourcelabel">
     2419     <x>61</x>
     2420     <y>609</y>
     2421    </hint>
     2422    <hint type="destinationlabel">
     2423     <x>5</x>
     2424     <y>594</y>
    24032425    </hint>
    24042426   </hints>
Note: See TracChangeset for help on using the changeset viewer.