-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Speed #10
Comments
Just did some more profiling
13ms to copy a frame to the screen is completely unacceptable! Going to need to look into a better ui library or something. |
Mine takes 6 to 12ms to render. DLib also screws everything up. |
Just tested disabling the thread. |
Well we know read frame is cv2, so we can perhaps replace that. And we should expect face detection to take much longer however it shouldn't slow the live webcam feed. |
Apparently PyGame has camera bindings http://stackoverflow.com/a/11094891/4191572 |
Just pushed some benchmarks, this is what I got at 3000 samples: Tkinter
pyqt
Over 3 times faster! |
I got similar Tkinter image = Image.fromar 0.900962352753 pyqt image = QImage(frame 2.30165958405 The configure really takes ages in tkinter. |
I'm still trying to found out why my FPS is capped.
Which still gives 15 fps regardless of what I pass to cap.set(cv2.cv.CV_CAP_PROP_FPS, fps) |
By reducing dlibs input size it runs almost as fast as cv2 but way more accurate. I haven't tested it with a webcam but on the sample video its about 18 FPS. |
Also looking into GPU acceleration, it only seems to work with CUDA so it would be useless for the laptop. |
Nice, DLib is actually much less CPU intensive. It uses 10%, so less than one core, while CV2 gets up to about 60% usage. |
Different types of detection can still be split into separate threads.
The text was updated successfully, but these errors were encountered: