提交 8e397481 authored 作者: blu's avatar blu

video detect: time and path

上级 3c8a3ab7
......@@ -9,8 +9,8 @@ print(json.dumps( {
"video": "http://evcloudsvc.ilabservice.cloud/video/D72154040/1550143347000-1577267418999/1550143347000-1577267418999.mp4"
}))
m = re.match(r".*? found (\w+) ([\d\.]+) .*? image: .*?/([_\w\d]+.jpg)", "ObjectDetector found human 0.857669 x: 655, y: 379, w: 300, h: 309; written image: /Users/blu/work/opencv-projects/opencv-yolo/D72154040/1550143347000-Rhwjpb/detect_person_1577774106607.jpg")
rawStr = "edet found human 0.838 x: 645, y: 353, w: 278, h: 348; written image: /apps/app/D72154040/1550143347000-wzGsNR//detect_1580371688.jpg; time: 3"
m = re.match(r".*? found (\w+) ([\d\.]+) .*? image: .*?/([_\w\d]+.jpg).*?time: ([\d\.]+)", rawStr)
if m:
print("matched", m.group(1))
......
......@@ -173,7 +173,7 @@ def video_analysis(data):
# parse
for line in output.decode('utf-8').split('\n'):
print("\n", line)
m = re.match(r".*? found (\w+) ([\d\.]+) .*? image: .*?/([_\w\d]+.jpg) .*?time: ([\d\.]+)", line)
m = re.match(r".*? found (\w+) ([\d\.]+) .*? image: .*?/([_\w\d]+.jpg).*?time: ([\d\.]+)", line)
if m:
ret['data']['humanDetect']['found'] = 1
ret['data']['humanDetect']['level'] = m.group(2)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论