Changeset 3579
- Timestamp:
- Jan 15, 2025, 1:50:20 PM (2 weeks ago)
- Location:
- trunk/LMDZ.COMMON/libf/evolution
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.COMMON/libf/evolution/changelog.txt
r3571 r3579 537 537 - Renaming of variables and subroutines to make everything clearer. In particular, the suffixes: '_avg' = average, '_start' = PCM start file, '_dev' = deviation, '_ini' or '0' = initial, '_dyn' = dynamical grid, '_timeseries' = daily average of last PCM year. 538 538 - Cosmetic cleanings for readability. 539 540 == 15/01/2025 == JBC 541 Improvement of the Bash script tools in the deftank with an automatic error detection which ends the script with a message. -
trunk/LMDZ.COMMON/libf/evolution/deftank/PCMrun.job
r3556 r3579 13 13 #SBATCH --time=10:00:00 14 14 15 # A few parameters that might need to be changed depending on your setup 15 ######################################################################## 16 # Modify here the parameters depending on your setup 17 #################################################### 16 18 # Path to the arch.env to source: 17 19 source ../trunk/LMDZ.COMMON/arch.env -
trunk/LMDZ.COMMON/libf/evolution/deftank/PEMrun.job
r3495 r3579 13 13 #SBATCH --mem=29000M 14 14 15 ######################################################################## 16 # Modify here the parameters depending on your setup 17 #################################################### 15 18 # A few parameters that might need to be changed depending on your setup 16 19 # Path to the arch.env to source: -
trunk/LMDZ.COMMON/libf/evolution/deftank/README
r3556 r3579 34 34 35 35 # obl_ecc_lsp.asc 36 File describing orbital parameters for Mars from Laskar data. It contains the Earth year and the corresponding obliquity, eccentricity and Ls of perihelion.36 File describing orbital parameters for Mars from Laskar's data. It contains the Earth year and the corresponding obliquity, eccentricity and Ls of perihelion. 37 37 38 38 # modify_startfi_orbit.sh: … … 49 49 50 50 # clean.sh: 51 Bash script file to clean the folder after a PEM simulation .51 Bash script file to clean the folder after a PEM simulation and reset the initial starting files to prepare a new simulation. 52 52 53 53 # multiple_exec.sh: 54 Bash script to execute multiple scripts in subdirectories,useful to launch multiple simulations at once.54 Bash script file to execute multiple scripts in subdirectories. It is useful to launch multiple simulations at once. 55 55 56 56 # visu_layering.py: -
trunk/LMDZ.COMMON/libf/evolution/deftank/clean.sh
r3428 r3579 2 2 ######################################################### 3 3 ### Script to clean the folder after a PEM simulation ### 4 ### and reset the initial starting files to prepare a ### 5 ### new simulation ### 4 6 ######################################################### 7 # There is no argument, you can just execute it. 8 ################################################ 5 9 6 10 echo "Cleaning..." -
trunk/LMDZ.COMMON/libf/evolution/deftank/concat_diagpem.sh
r3214 r3579 3 3 ### Script to concatenate "diagpem.nc" outputs into one file ### 4 4 ################################################################ 5 set -e 6 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 5 7 8 ################################################################ 9 # Modify here the parameters for the script 10 ########################################### 6 11 # Output file name 7 12 output_file="diagpem_concat.nc" … … 20 25 files=($directory/diagpem*.nc) 21 26 output_file=($directory/$output_file) 27 ################################################################ 22 28 23 29 24 ################################################################25 30 # Checking if everything is ok 26 31 if [ ! -d "$directory" ]; then -
trunk/LMDZ.COMMON/libf/evolution/deftank/inipem_orbit.sh
r3351 r3579 4 4 ### according to the date set in the file "run_PEM.def" ### 5 5 ###################################################################### 6 set -e 7 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 6 8 9 ###################################################################### 10 # Modify here the parameters for the script 11 ########################################### 7 12 # Name of the file to be modified 8 13 name_file="startfi.nc" … … 10 15 # Name of the file containing the orbital data 11 16 orb_data="obl_ecc_lsp.asc" 17 ###################################################################### 12 18 13 19 14 ######################################################################15 20 # Check if files necessary for the script exist 16 21 if [ ! -f "$orb_data" ]; then -
trunk/LMDZ.COMMON/libf/evolution/deftank/launchPEM.sh
r3556 r3579 8 8 # It will ask for parameters to know the starting point that you want to. 9 9 ######################################################################## 10 set -e 11 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 10 12 11 13 -
trunk/LMDZ.COMMON/libf/evolution/deftank/lib_launchPEM.sh
r3556 r3579 10 10 11 11 date 12 echo "Success ful end of the launching script for the PEM simulation."12 echo "Success: the launching script for the PEM simulation completed normally!" 13 13 exit 0 14 14 } … … 20 20 21 21 date 22 echo "E nd with error of the launching script for the PEM."22 echo "Error: an issue occured in the launching script for the PEM simulation!" 23 23 exit 1 24 24 } -
trunk/LMDZ.COMMON/libf/evolution/deftank/modify_startfi_orbit.sh
r3210 r3579 3 3 ### Script to modify the orbital parameters of a file "startfi.nc" ### 4 4 ###################################################################### 5 set -e 6 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 5 7 8 ###################################################################### 9 # Modify here the parameters for the script 10 ########################################### 6 11 # Name of the file 7 name_file ="startfi.nc"12 name_file = "startfi.nc" 8 13 9 14 # New values for the orbital parameters … … 12 17 new_Lsp=251.06881714 13 18 new_iniLs=0. 19 ###################################################################### 14 20 15 21 16 ######################################################################17 22 # Calculate modified values 18 23 if [ ! -f "$name_file" ]; then -
trunk/LMDZ.COMMON/libf/evolution/deftank/modify_startfi_var.sh
r3210 r3579 3 3 ### Script to modify the value of a variable in a file "startfi.nc" ### 4 4 ####################################################################### 5 set -e 6 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 5 7 8 ####################################################################### 9 # Modify here the parameters for the script 10 ########################################### 6 11 # Name of the file 7 12 name_file="startfi.nc" … … 12 17 # New value for the variable 13 18 new_var=8. 19 ####################################################################### 14 20 15 21 16 #######################################################################17 22 # Update the netCDF file 18 23 ncap2 -O -s "$var_name=$new_var" \ -
trunk/LMDZ.COMMON/libf/evolution/deftank/multiple_exec.sh
r3456 r3579 3 3 ### Script to execute multiple scripts in subdirectories ### 4 4 ############################################################ 5 set -e 6 trap 'echo -e "\033[31mError: an issue occurred in the script on line $LINENO! Please review the command and try again.\033[0m"' ERR 5 7 8 ############################################################ 9 # Modify here the parameters for the script 10 ########################################### 6 11 # Name of the file to execute in all subdirectories 7 12 script_name="launchPEM.sh" … … 12 17 # Name of the template directory to skip 13 18 tempdir_name="Template" 19 ############################################################ 20 14 21 15 22 # Traverse all subdirectories, excluding the template -
trunk/LMDZ.COMMON/libf/evolution/reshape_XIOS_output.F90
r3214 r3579 11 11 !======================================================================= 12 12 use netcdf 13 use version_info_mod, only: print_version_info 13 14 14 15 implicit none … … 23 24 character(1) :: str 24 25 character(30) :: name_, namevar 26 character(100) :: arg ! To read command-line arguments 25 27 integer :: xtype_var, len_, len_1, len_2, len_lat, len_lon, len_time, len_soil 26 28 integer :: dimid_lon, dimid_lat, dimid_time, dimid_soil, dimid_2, numdims, numatts, numyear 27 29 logical :: yes 30 31 32 if (command_argument_count() > 0) then ! Get the number of command-line arguments 33 call get_command_argument(1,arg) ! Read the argument given to the program 34 select case (trim(adjustl(arg))) 35 case('version') 36 call print_version_info() 37 stop 38 case default 39 error stop 'The argument given to the program is unknown!' 40 end select 41 endif 28 42 29 43 do numyear = 1,2
Note: See TracChangeset
for help on using the changeset viewer.