123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150 |
- #!/bin/bash
- # Replace "python3" with your Python interpreter if needed
- DS="Heap"
- Operation="Extract"
- cd ..
- rm "repro/experimentaldata_preproc_wallclock" "repro/experimentaldata_wallclock"
- touch "repro/experimentaldata_preproc_wallclock" "repro/experimentaldata_wallclock"
- nitrs=10
- minsize=16
- maxsize=30
- stepsize=2
- for itr in $(seq 1 $nitrs); do
- for heapsize in $(seq $minsize $stepsize $maxsize); do
- input_file="repro/data/log_basic_heap_extract_online_${heapsize}_itr_${itr}"
- echo $input_file
- output=$(python3 repro/extract_data.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]}
- optimization_flag=${values[1]}
- milliseconds=${values[4]}
- #seconds=$((milliseconds / 1000))
- seconds=$(echo "scale=3; $milliseconds / 1000" | bc) # Use bc for decimal division
- extract_wc=$seconds
-
- echo $optimization_flag
- echo $heapsize
- echo $milliseconds
- echo "$extract_wc"
- datafile="repro/experimentaldata_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $extract_wc
- input_file="repro/data/log_opt_heap_extract_online_${heapsize}_itr_${itr}"
- echo $input_file
- output=$(python3 repro/extract_data.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- milliseconds=${values[4]}
- seconds=$(echo "scale=3; $milliseconds / 1000" | bc) # Use bc for decimal division
- heapsize=${values[0]} optimization_flag=${values[1]} extract_wc=$seconds
- datafile="repro/experimentaldata_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $extract_wc
- done
- done
- echo "OnlineTable"
- cat $datafile
- echo -e "\n\n"
- nitrs=2
- for itr in $(seq 1 $nitrs); do
- for heapsize in $(seq $minsize $stepsize $maxsize); do
- input_file="repro/data/log_basic_heap_extract_preproc_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data_from_preproc.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} milliseconds=${values[2]}
- seconds=$(echo "scale=3; $milliseconds / 1000" | bc) # Use bc for decimal division
- preproc_wc=$seconds
- datafile="repro/experimentaldata_preproc_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $preproc_wc
- input_file="repro/data/log_opt_heap_extract_preproc_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data_from_preproc.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} milliseconds=${values[2]}
- seconds=$(echo "scale=3; $milliseconds / 1000" | bc) # Use bc for decimal division
- preproc_wc=$seconds
- datafile="repro/experimentaldata_preproc_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $preproc_wc
- done
- done
- echo "Preproc Table"
- cat $datafile
- echo -e "\n\n"
- nitrs=0
- # Replace "python3" with your Python interpreter if needed
- DS="Heap"
- Operation="Insert"
- for itr in $(seq 1 $niters); do
- for heapsize in $(seq $minsize $stepsize $maxsize); do
- input_file="repro/data/log_basic_heap_insert_online_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} insert_wc=${values[2]}
- datafile="repro/experimentaldata_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $insert_wc
- input_file="repro/data/log_opt_heap_insert_online_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} insert_wc=${values[2]}
- datafile="repro/experimentaldata_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $insert_wc
- done
- done
- echo "Online Table"
- cat $datafile
- echo -e "\n\n"
- for itr in $(seq 1 $niters); do
- for heapsize in $(seq $minsize $stepsize $maxsize); do
-
- input_file="repro/data/log_basic_heap_insert_preproc_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data_from_preproc.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} preproc_wc=${values[2]}
- datafile="repro/experimentaldata_preproc_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $preproc_wc
- input_file="repro/data/log_opt_heap_insert_preproc_${heapsize}_itr_$itr"
- output=$(python3 repro/extract_data_from_preproc.py "$input_file")
- # Read the output into an array
- IFS=$'\n' read -d '' -r -a values <<< "$output"
- # Store each value in different variables
- heapsize=${values[0]} optimization_flag=${values[1]} preproc_wc=${values[2]}
- datafile="repro/experimentaldata_preproc_wallclock"
- python3 repro/append-experiment-results.py $datafile $DS $Operation $optimization_flag $heapsize $preproc_wc
- done
- done
- echo "Preproc Table"
- cat $datafile
|