update cmu-sod tests

master
emil 2 years ago
parent dac95d08f4
commit bc2c52165a

@ -8,10 +8,10 @@ clean:
rm -rf res/*
run:
SLEDGE_SANDBOX_PERF_LOG=perf.log LD_LIBRARY_PATH=${SLEDGE_BINARY_DIR} ${SLEDGE_BINARY_DIR}/sledgert spec.json
SLEDGE_SPINLOOP_PAUSE_ENABLED=true SLEDGE_SANDBOX_PERF_LOG=perf.log LD_LIBRARY_PATH=${SLEDGE_BINARY_DIR} ${SLEDGE_BINARY_DIR}/sledgert spec.json
debug:
SLEDGE_NWORKERS=1 LD_LIBRARY_PATH=${SLEDGE_BINARY_DIR} gdb ${SLEDGE_BINARY_DIR}/sledgert --eval-command="run spec.json"
SLEDGE_SPINLOOP_PAUSE_ENABLED=true SLEDGE_NWORKERS=1 LD_LIBRARY_PATH=${SLEDGE_BINARY_DIR} gdb ${SLEDGE_BINARY_DIR}/sledgert --eval-command="run spec.json"
valgrind:
SLEDGE_DISABLE_PREEMPTION=true SLEDGE_NWORKERS=1 LD_LIBRARY_PATH=${SLEDGE_BINARY_DIR} valgrind --leak-check=full --max-stackframe=11150456 --run-libc-freeres=no --run-cxx-freeres=no ${SLEDGE_BINARY_DIR}/sledgert spec.json

@ -0,0 +1,20 @@
import time
import requests
url = 'http://arena0.andrew.cmu.edu:10000/depth_to_xyz'
payload = open('0_depth.png', 'rb')
img = None
response = requests.post(url, data=payload)
img = response.content
time.sleep(1)
print("single request works!")
for i in range(100):
payload = open('0_depth.png', 'rb')
response = requests.post(url, data=payload)
img = response.content
time.sleep(1)
print(f"multi request #{i} works!")

@ -28,5 +28,4 @@ def get_img():
thread = threading.Thread(target=get_img)
thread.daemon = True
thread.start()
thread.join()
Loading…
Cancel
Save