logo
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Readme
Files and versions

21 lines
386 B

m towhee import triton_client
import sys
import time
num = int(sys.argv[-1])
data = '../towhee.jpeg'
client = triton_client.Client('localhost:8000')
# warm up
client.batch([data])
print('client: ok')
time.sleep(5)
print('test...')
start = time.time()
client.batch([data] * num, batch_size=8)
end = time.time()
print(f'duration: {end - start}')
print(f'qps: {num / (end - start)}')