RizwanMunawar / yolov7-pose-estimation

YOLOv7 Pose estimation using OpenCV, PyTorch
GNU General Public License v3.0
344 stars 82 forks source link

Fix the webcam device problem #4

Closed nianchengz closed 2 years ago

nianchengz commented 2 years ago

Before, when you ran this program with webcam, it will crush with the error 'Nonetype object has no attribute 'shape'. It happened because the type of 'video_path' is string, but cv2.VideoCapture(0) need it to be 'int' type. So I made a little adjustment at line 37 ~ 40 and it work successfully.

RizwanMunawar commented 2 years ago

@Hooje! I have merged your pull request with master branch. It will help lot of people to test pose estimation on their webcams. Thanks for your valuable contribution.