|
After Width: | Height: | Size: 177 KiB |
|
After Width: | Height: | Size: 529 KiB |
|
After Width: | Height: | Size: 892 KiB |
|
After Width: | Height: | Size: 488 KiB |
|
After Width: | Height: | Size: 220 KiB |
|
After Width: | Height: | Size: 571 KiB |
|
After Width: | Height: | Size: 568 KiB |
|
After Width: | Height: | Size: 369 KiB |
|
After Width: | Height: | Size: 513 KiB |
|
After Width: | Height: | Size: 635 KiB |
|
After Width: | Height: | Size: 521 KiB |
|
After Width: | Height: | Size: 688 KiB |
|
After Width: | Height: | Size: 541 KiB |
|
After Width: | Height: | Size: 634 KiB |
|
After Width: | Height: | Size: 528 KiB |
|
@ -0,0 +1,41 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# Executes the runtime in GDB
|
||||||
|
# Substitutes the absolute path from the container with a path relatively derived from the location of this script
|
||||||
|
# This allows debugging outside of the Docker container
|
||||||
|
# Also disables pagination and stopping on SIGUSR1
|
||||||
|
|
||||||
|
experiment_directory=$(pwd)
|
||||||
|
project_directory=$(cd ../../../.. && pwd)
|
||||||
|
binary_directory=$(cd "$project_directory"/bin && pwd)
|
||||||
|
log="$experiment_directory/log.csv"
|
||||||
|
|
||||||
|
if [ "$1" != "-d" ]; then
|
||||||
|
SLEDGE_SANDBOX_PERF_LOG=$log PATH="$binary_directory:$PATH" LD_LIBRARY_PATH="$binary_directory:$LD_LIBRARY_PATH" sledgert "$experiment_directory/spec.json" &
|
||||||
|
sleep 1
|
||||||
|
else
|
||||||
|
echo "Running under gdb"
|
||||||
|
fi
|
||||||
|
|
||||||
|
one_plate=(Cars0 Cars1 Cars2 Cars3 Cars4)
|
||||||
|
two_plates=(Cars71 Cars87 Cars143 Cars295 Cars316)
|
||||||
|
four_plates=(Cars106 Cars146 Cars249 Cars277 Cars330)
|
||||||
|
|
||||||
|
for image in ${one_plate[*]}; do
|
||||||
|
echo "@./1/${image}.png"
|
||||||
|
curl --data-binary "@./1/${image}.png" --output - localhost:10000
|
||||||
|
done
|
||||||
|
for image in ${two_plates[*]}; do
|
||||||
|
echo "@./2/${image}.png"
|
||||||
|
curl --data-binary "@./2/${image}.png" --output - localhost:10001
|
||||||
|
done
|
||||||
|
for image in ${four_plates[*]}; do
|
||||||
|
echo "@./4/${image}.png"
|
||||||
|
curl --data-binary "@./4/${image}.png" --output - localhost:10002
|
||||||
|
done
|
||||||
|
|
||||||
|
if [ "$1" != "-d" ]; then
|
||||||
|
sleep 5
|
||||||
|
echo -n "Running Cleanup: "
|
||||||
|
pkill sledgert >/dev/null 2>/dev/null
|
||||||
|
echo "[DONE]"
|
||||||
|
fi
|
@ -0,0 +1,42 @@
|
|||||||
|
{
|
||||||
|
"active": "yes",
|
||||||
|
"name": "lpd1",
|
||||||
|
"path": "lpd_wasm.so",
|
||||||
|
"port": 10000,
|
||||||
|
"relative-deadline-us": 50000,
|
||||||
|
"argsize": 1,
|
||||||
|
"http-req-headers": [],
|
||||||
|
"http-req-content-type": "image/jpeg",
|
||||||
|
"http-req-size": 1002400,
|
||||||
|
"http-resp-headers": [],
|
||||||
|
"http-resp-size": 1048576,
|
||||||
|
"http-resp-content-type": "text/plain"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"active": "yes",
|
||||||
|
"name": "lpd2",
|
||||||
|
"path": "lpd_wasm.so",
|
||||||
|
"port": 10001,
|
||||||
|
"relative-deadline-us": 50000,
|
||||||
|
"argsize": 1,
|
||||||
|
"http-req-headers": [],
|
||||||
|
"http-req-content-type": "image/jpeg",
|
||||||
|
"http-req-size": 1002400,
|
||||||
|
"http-resp-headers": [],
|
||||||
|
"http-resp-size": 1048576,
|
||||||
|
"http-resp-content-type": "text/plain"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"active": "yes",
|
||||||
|
"name": "lpd4",
|
||||||
|
"path": "lpd_wasm.so",
|
||||||
|
"port": 10002,
|
||||||
|
"relative-deadline-us": 50000,
|
||||||
|
"argsize": 1,
|
||||||
|
"http-req-headers": [],
|
||||||
|
"http-req-content-type": "image/jpeg",
|
||||||
|
"http-req-size": 1002400,
|
||||||
|
"http-resp-headers": [],
|
||||||
|
"http-resp-size": 1048576,
|
||||||
|
"http-resp-content-type": "text/plain"
|
||||||
|
}
|
Before Width: | Height: | Size: 130 KiB |
Before Width: | Height: | Size: 97 KiB |
@ -1,54 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# Executes the runtime in GDB
|
|
||||||
# Substitutes the absolute path from the container with a path relatively derived from the location of this script
|
|
||||||
# This allows debugging outside of the Docker container
|
|
||||||
# Also disables pagination and stopping on SIGUSR1
|
|
||||||
|
|
||||||
experiment_directory=$(pwd)
|
|
||||||
project_directory=$(cd ../../.. && pwd)
|
|
||||||
binary_directory=$(cd "$project_directory"/bin && pwd)
|
|
||||||
|
|
||||||
# Copy License Plate Image if not here
|
|
||||||
if [[ ! -f "./plate.jpg" ]]; then
|
|
||||||
cp ../../../tests/sod/bin/plate.jpg ./plate.jpg
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$1" != "-d" ]; then
|
|
||||||
PATH="$binary_directory:$PATH" LD_LIBRARY_PATH="$binary_directory:$LD_LIBRARY_PATH" sledgert "$experiment_directory/spec.json" &
|
|
||||||
sleep 1
|
|
||||||
else
|
|
||||||
echo "Running under gdb"
|
|
||||||
fi
|
|
||||||
|
|
||||||
expected_size="$(find expected_result.jpg -printf "%s")"
|
|
||||||
success_count=0
|
|
||||||
total_count=50
|
|
||||||
|
|
||||||
for ((i = 0; i < total_count; i++)); do
|
|
||||||
echo "$i"
|
|
||||||
ext="$RANDOM"
|
|
||||||
curl -H 'Expect:' -H "Content-Type: image/jpg" --data-binary "@plate.jpg" --output "result_$ext.jpg" localhost:10000 2>/dev/null
|
|
||||||
actual_size="$(find result_"$ext".jpg -printf "%s")"
|
|
||||||
|
|
||||||
# echo "$result"
|
|
||||||
if [[ "$expected_size" == "$actual_size" ]]; then
|
|
||||||
echo "SUCCESS $success_count"
|
|
||||||
else
|
|
||||||
echo "FAIL"
|
|
||||||
echo "Expected Size:"
|
|
||||||
echo "$expected_size"
|
|
||||||
echo "==============================================="
|
|
||||||
echo "Actual Size:"
|
|
||||||
echo "$actual_size"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
echo "$success_count / $total_count"
|
|
||||||
|
|
||||||
if [ "$1" != "-d" ]; then
|
|
||||||
sleep 5
|
|
||||||
echo -n "Running Cleanup: "
|
|
||||||
rm result_*.jpg
|
|
||||||
pkill sledgert >/dev/null 2>/dev/null
|
|
||||||
echo "[DONE]"
|
|
||||||
fi
|
|
@ -1,14 +0,0 @@
|
|||||||
{
|
|
||||||
"active": "yes",
|
|
||||||
"name": "lpd",
|
|
||||||
"path": "lpd_wasm.so",
|
|
||||||
"port": 10000,
|
|
||||||
"relative-deadline-us": 50000,
|
|
||||||
"argsize": 1,
|
|
||||||
"http-req-headers": [],
|
|
||||||
"http-req-content-type": "image/jpeg",
|
|
||||||
"http-req-size": 102400,
|
|
||||||
"http-resp-headers": [],
|
|
||||||
"http-resp-size": 1048576,
|
|
||||||
"http-resp-content-type": "image/jpeg"
|
|
||||||
}
|
|
@ -1 +1 @@
|
|||||||
Subproject commit 8df9f4d8a3fd80f06d38cae50362d507f5878ebf
|
Subproject commit 3060d0102555aab949308247a78252fa75568e45
|