https://www.pyimagesearch.com/2017/04/24/eye-blink-detection-opencv-python-dlib/
まばたきを検出するプログラムを動かしてみようとしたところ、dlibのところでエラーが出ました。
$ python detect_blinks_np.py --shape-predictor shape_predictor_68_face_landmarks.dat
上記のコマンドで以下のエラーが発生しました。
ape_predictor_68_face_landmarks.dat [INFO] loading facial landmark predictor... Traceback (most recent call last): File "detect_blinks_np.py", line 53, in <module> detector = dlib.get_frontal_face_detector() AttributeError: module 'dlib' has no attribute 'get_frontal_face_detector'
ソースコードの該当箇所
Python
1print("[INFO] loading facial landmark predictor...") 2detector = dlib.get_frontal_face_detector() 3predictor = dlib.shape_predictor(args[> "shape_predictor"])
python3.6.5
raspberry pi3 modelB
rasbian stretch
dlib 19.16
opencv 3.1.0
import dlibはエラーなくできます。インストールはpip install dlibでしています。
回答1件
あなたの回答
tips
プレビュー