# get payload
body = json.loads(event['body'])

# get params
img_b64 = body['image']
size = body.get('size', 640)
conf_thres = body.get('conf_thres', 0.3)
iou_thres = body.get('iou_thres', 0.5)