forked from vishalmhjn/actrys
-
Notifications
You must be signed in to change notification settings - Fork 0
/
wrapper.sh
73 lines (63 loc) · 2.29 KB
/
wrapper.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#!/bin/bash
# Function to set environment variables
set_environment_variables() {
export temp_folder_name=$1
export run_scenario=$2
export synthetic_counts=$3
export noise_param=$4
export bias_param=$5
export spsa_a=$6
export spsa_c=$7
export spsa_a_out_sim=$8
export spsa_c_out_sim=$9
export spsa_reps=${10}
export sim_in_loop=${11}
export sim_out_loop=${12}
export n_iterations=${13}
export sim_in_iterations=${14}
export sim_out_iterations=${15}
export which_algo=${16}
export wspsa_threshold=${17}
export calibrate_supply=${18}
export calibrate_demand=${19}
export set_spa=${20}
export estimator=${21}
export SCENARIO=${22}
export weight_counts=${23}
export weight_od=${24}
export weight_speed=${25}
export bagging_run=${26}
export count_noise_param=${27}
export heuristic=${28}
export auto_tune_spsa=${29}
export momentum_beta=${30}
export interval=${31}
export only_bias_correction=${32}
export bias_correction_method=${33}
export OD_FILE_IDENTIFIER=OD
export DEMAND_SOURCE=demand
export DEMAND_INTERVAL=$interval
export temp_scenario_name=$temp_folder_name
export PATH_ZONE=../../$SCENARIO/tazes.taz.xml
export PATH_DEMAND=../../$SCENARIO/$DEMAND_SOURCE/$OD_FILE_IDENTIFIER.txt
export PATH_NETWORK=../../$SCENARIO/network.net.xml
export PATH_ADDITIONAL=../../$SCENARIO/additional.add.xml
export PATH_SUMO_TOOLS=$SUMO_HOME/tools/
export PATH_OUTPUT_COUNT=../../$SCENARIO/$temp_scenario_name/out.xml
export PATH_REAL_COUNT=../../$SCENARIO/$temp_scenario_name/real_counts_complete.csv
export PATH_OUTPUT_SPEED=../../$SCENARIO/$temp_scenario_name/edge_data_3600
export PATH_REAL_SPEED=../../$SCENARIO/$temp_scenario_name/real_edge_data_3600.csv
export FILE_MATCH_DETECTORS=../../$SCENARIO/sample_real_world_data/matchable_detectors.csv
export FILE_REAL_COUNTS=../../$SCENARIO/sample_real_world_data/dummy_counts_data.csv
export FILE_REAL_SPEEDS=../../$SCENARIO/sample_real_world_data/dummy_speed_data.csv
export TOD_START=7
export TOD_END=9
export WARM_UP_PERIOD=2
export COOL_DOWN_PERIOD=0
}
# Main execution
main() {
set_environment_variables "$@"
python ../core/main.py
}
main "$@"