diff --git a/scripts/test_ipmu_gw/gw_queue_check_various_mps.sh b/scripts/test_ipmu_gw/gw_queue_check_various_mps.sh new file mode 100644 index 0000000..4163c6c --- /dev/null +++ b/scripts/test_ipmu_gw/gw_queue_check_various_mps.sh @@ -0,0 +1,44 @@ +#!/bin/bash + +# The shell script which interprets this job script. +# Any option for qsub can be described like this, +# with #PBS +#PBS -S /bin/bash + + +# Merge STDERR to STDOUT +#PBS -j oe + +# Path of the redirect of STDOUT by the batch job. +#PBS -o check_various_mps_sampled_case5_test_result + +# No mail will be sent for the job. +#PBS -m p + +#PBS -l nodes=1:ppn=28 +#PBS -l walltime=72:00:00 + +# Name of queue; +# run qmgr -c "p s" to get the list of available queues. +#PBS -q mini + +# Name of the job +# - within 15 characters length, +# - without white space characters, +# - and with the first character alphabetic. +# It is shown in the list which "qstat" generates +#PBS -N sampled_case5_test + +cd /work/kiyoyabe/pfs/survey_simulations/scripts/check_netflow_processing_time_201905/scripts +source /home/kiyoyabe/gurobi/gurobi_811.env + + +# example (changing MIPFocus from 0 to 3) +rm -f ../logs/idl_ge_single_sampled_case5_fixed_net_test_mipfocus?_seed??.log + +./run_gurobi_cl.sh -m idl_ge_single_unsampled_case5_fixed_net.mps -l idl_ge_single_sampled_case5_fixed_net_test_mipfocus0 -g 0.01 -t 28 -p 2 -e 4 -d 0 -r 0.8 -f 0 -c -1 -n 5 +./run_gurobi_cl.sh -m idl_ge_single_unsampled_case5_fixed_net.mps -l idl_ge_single_sampled_case5_fixed_net_test_mipfocus1 -g 0.01 -t 28 -p 2 -e 4 -d 0 -r 0.8 -f 1 -c -1 -n 5 +./run_gurobi_cl.sh -m idl_ge_single_unsampled_case5_fixed_net.mps -l idl_ge_single_sampled_case5_fixed_net_test_mipfocus2 -g 0.01 -t 28 -p 2 -e 4 -d 0 -r 0.8 -f 2 -c -1 -n 5 +./run_gurobi_cl.sh -m idl_ge_single_unsampled_case5_fixed_net.mps -l idl_ge_single_sampled_case5_fixed_net_test_mipfocus3 -g 0.01 -t 28 -p 2 -e 4 -d 0 -r 0.8 -f 3 -c -1 -n 5 + +# for options for run_gurobi_cl.sh, run ./run_gurobi_cl.sh -h diff --git a/scripts/test_ipmu_gw/run_gurobi_cl.sh b/scripts/test_ipmu_gw/run_gurobi_cl.sh new file mode 100755 index 0000000..be40369 --- /dev/null +++ b/scripts/test_ipmu_gw/run_gurobi_cl.sh @@ -0,0 +1,90 @@ +#!/bin/bash + +function usage { + + cat < : MPS FILE NAME + -l : LOG NAME for LOGFILE + -g : MIPGap value (default:0.01) + -t : Number of Threads (default:28) + -p : Presolve (default:-1) + -e : Method (default:-1) + -d : DegenMoves (default:-1) + -r : Heuristics (default:0.05) + -f : MIPFocus (default:0) + -c : Cuts (default:-1) + -n : Number of seeds (default:5) + -h : Display help +EOM + + exit 2 +} + + +mps_dir=../data/ +log_dir=../logs/ + +# init parameters + +mps=idl_ge_single_sampled_case1_fixed_net.mps +logname=idl_ge_single_sampled_case1_fixed_net_fiducial +mipgap=0.01 +threads=28 +presolve=-1 +method=-1 +degenmoves=-1 +heuristics=0.05 +mipfocus=0 +cuts=-1 +nseed=5 + +while getopts "m:l:g:t:p:e:d:r:f:c:n:" optKey; do + case "$optKey" in + m) + mps=$OPTARG + ;; + l) + logname=$OPTARG + ;; + g) + mipgap=$OPTARG + ;; + t) + threads=$OPTARG + ;; + p) + presolve=$OPTARG + ;; + e) + method=$OPTARG + ;; + d) + degenmoves=$OPTARG + ;; + r) + heuristics=$OPTARG + ;; + f) + mipfocus=$OPTARG + ;; + c) + cuts=$OPTARG + ;; + n) + nseed=$OPTARG + ;; + h|*) + usage + ;; + esac +done + +for seed in `seq -f %02g 1 $nseed` +do + arguments="MIPGap=$mipgap Threads=$threads Seed=$seed Presolve=$presolve Method=$method DegenMoves=$degenmoves Heuristics=$heuristics MIPFocus=$mipfocus Cuts=$cuts LogFile=$log_dir${logname}_seed$seed.log ${mps_dir}$mps" + command="gurobi_cl $arguments " + echo $command + $command +done