From 364b7c511146a1c68f2477c8f1df9bea71516e7e Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Thu, 10 Feb 2022 13:13:44 +0100 Subject: [PATCH] Fix YouTube dislike button bug in `pafy` package (#6603) Per https://github.com/ultralytics/yolov5/issues/6583#issuecomment-1034421945 by @alicera --- utils/datasets.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/datasets.py b/utils/datasets.py index b3e0dbb..9eba83d 100755 --- a/utils/datasets.py +++ b/utils/datasets.py @@ -301,7 +301,7 @@ class LoadStreams: # Start thread to read frames from video stream st = f'{i + 1}/{n}: {s}... ' if 'youtube.com/' in s or 'youtu.be/' in s: # if source is YouTube video - check_requirements(('pafy', 'youtube_dl')) + check_requirements(('git+https://github.com/Cupcakus/pafy', 'youtube_dl')) import pafy s = pafy.new(s).getbest(preftype="mp4").url # YouTube URL s = eval(s) if s.isnumeric() else s # i.e. s = '0' local webcam