Open DEEPMINDing opened 3 years ago
I solved the problem by changing video_wh and save_framerate
Note : create a folder CenterTrack/results
In demo.py file Line 48:
change this
if opt.save_video:
fourcc = cv2.VideoWriter_fourcc(*'XVID')
out = cv2.VideoWriter('results/{}.mp4'.format(
opt.exp_id + '_' + out_name),fourcc, opt.save_framerate, (opt.video_w, opt.video_h))
to this
if opt.save_video:
fourcc = cv2.VideoWriter_fourcc('m', 'p', '4', 'v')
out = cv2.VideoWriter('results/{}'.format(
opt.exp_id + '_' + out_name),fourcc, opt.save_framerate, (
opt.video_w, opt.video_h))
Specify the height and width of video : --video_h 450 --video_w 800
!python src/demo.py tracking,ddd --load_model models/nuScenes_3Dtracking.pth --dataset nuscenes --pre_hm --track_thresh 0.1 --demo videos/nuscenes_mini.mp4 --test_focal_length 633 --video_h 450 --video_w 800 --save_video
I used the fourcc = cv2.VideoWriter_fourcc('m', 'p', '4', 'v') and fourcc = cv2.VideoWriter_fourcc(*'XVID'),But the results video still won't open