未验证 提交 e3174294 编写于 作者: Z zhiboniu 提交者: GitHub

update demo&fix mtmct vis; test=document_fix (#6803)

上级 7fd6c8e7
demo/car.jpg

370.1 KB | W: | H:

demo/car.jpg

2.2 MB | W: | H:

demo/car.jpg
demo/car.jpg
demo/car.jpg
demo/car.jpg
  • 2-up
  • Swipe
  • Onion skin
...@@ -11,7 +11,7 @@ MOT: ...@@ -11,7 +11,7 @@ MOT:
VEHICLE_PLATE: VEHICLE_PLATE:
det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz
det_limit_side_len: 736 det_limit_side_len: 736
det_limit_type: "max" det_limit_type: "min"
rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz
rec_image_shape: [3, 48, 320] rec_image_shape: [3, 48, 320]
rec_batch_num: 6 rec_batch_num: 6
......
...@@ -15,7 +15,7 @@ MOT: ...@@ -15,7 +15,7 @@ MOT:
VEHICLE_PLATE: VEHICLE_PLATE:
det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz
det_limit_side_len: 736 det_limit_side_len: 736
det_limit_type: "max" det_limit_type: "min"
rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz
rec_image_shape: [3, 48, 320] rec_image_shape: [3, 48, 320]
rec_batch_num: 6 rec_batch_num: 6
......
...@@ -16,7 +16,7 @@ MOT: ...@@ -16,7 +16,7 @@ MOT:
VEHICLE_PLATE: VEHICLE_PLATE:
det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz det_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_det_infer.tar.gz
det_limit_side_len: 736 det_limit_side_len: 736
det_limit_type: "max" det_limit_type: "min"
rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz rec_model_dir: https://bj.bcebos.com/v1/paddledet/models/pipeline/ch_PP-OCRv3_rec_infer.tar.gz
rec_image_shape: [3, 48, 320] rec_image_shape: [3, 48, 320]
rec_batch_num: 6 rec_batch_num: 6
......
...@@ -128,7 +128,7 @@ def save_mtmct_vis_results(camera_results, captures, output_dir, ...@@ -128,7 +128,7 @@ def save_mtmct_vis_results(camera_results, captures, output_dir,
height = int(capture.get(cv2.CAP_PROP_FRAME_HEIGHT)) height = int(capture.get(cv2.CAP_PROP_FRAME_HEIGHT))
fps = int(capture.get(cv2.CAP_PROP_FPS)) fps = int(capture.get(cv2.CAP_PROP_FPS))
frame_count = int(capture.get(cv2.CAP_PROP_FRAME_COUNT)) frame_count = int(capture.get(cv2.CAP_PROP_FRAME_COUNT))
fourcc = cv2.VideoWriter_fourcc(*'mp4v') fourcc = cv2.VideoWriter_fourcc(* 'mp4v')
writer = cv2.VideoWriter(out_path, fourcc, fps, (width, height)) writer = cv2.VideoWriter(out_path, fourcc, fps, (width, height))
frame_id = 0 frame_id = 0
while (1): while (1):
...@@ -148,10 +148,7 @@ def save_mtmct_vis_results(camera_results, captures, output_dir, ...@@ -148,10 +148,7 @@ def save_mtmct_vis_results(camera_results, captures, output_dir,
# add attr vis # add attr vis
if multi_res: if multi_res:
tid_list = [ tid_list = multi_res.keys() # c0_t1, c0_t2...
'c' + str(idx) + '_' + 't' + str(int(j))
for j in range(1, len(ids) + 1)
] # c0_t1, c0_t2...
all_attr_result = [multi_res[i]["attrs"] all_attr_result = [multi_res[i]["attrs"]
for i in tid_list] # all cid_tid result for i in tid_list] # all cid_tid result
if any( if any(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册