-
Notifications
You must be signed in to change notification settings - Fork 0
/
copy_results_to_objectstorage.sh
executable file
·32 lines (24 loc) · 967 Bytes
/
copy_results_to_objectstorage.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
#!/usr/bin/env bash
obj_dir=$HOME/obj_mount
mkdir -p ${obj_dir}
if mountpoint -q "${obj_dir}" ; then
echo "$HOME/obj_mount is already mounted"
else
cc-cloudfuse mount ${obj_dir}
fi
perf_result=$(find . -maxdepth 1 -print | grep -m1 'perf-results-')
echo ${perf_result}
if [ -d "${perf_result}" ]; then
# Copy *.dat files and result PNG
rsync -zrv -O --prune-empty-dirs --include '*/' --include '*.dat' --include '*.png' --exclude '*' "${perf_result}" "${obj_dir}"
else
echo "Could not find any overhead analysis results to copy."
fi
cq_result=$(find . -maxdepth 1 -print | grep -m1 'cq-results-')
if [ -d "${cq_result}" ]; then
# Copy *.summary files
rsync -zrv --prune-empty-dirs --include '*/' --include '*.csv' --include '*.summary' --exclude '*' "${cq_result}" "${obj_dir}"
else
echo "Could not find any classification quality results to copy."
fi
echo "The files can be viewed in the object storage of the ChameleonCloud."