FAST Screenshots in Python for Computer Vision: mss vs. PIL vs. pyautogui

preview_player
Показать описание
In this video we will be comparing 3 common Python libraries for image manipulation and screen capture. Our goal is to maximize performance (framerate) for use with computer vision projects.

We will be comparing the performance of mss, PIL (pillow, and pyautogui libraries for speed and efficiency in image capture. All code is virtually identical, allowing for a fair comparison across libraries. The complete code can be downloaded at the github repository link below:

Рекомендации по теме
Комментарии
Автор

Hey this was a great video. Thanks for putting in the work!

dariustrabalza
Автор

I want to make a Google chrome dinosaur space bar presser. Will this work to input small streaming rectangles.

wyattb
Автор

why screenshot looks blur when seeing it below 100% but it looks clear, when i see it in its original dimension and this is only happening with the screenshot because i have many images which have same dimensions as of the screenshot

tapgameplay
Автор

Nice comparison although missing dxcam. I think it's the fastest of all of these.

powN
Автор

Why are they all so slow? I can easily get 60fps recording with OBS. This bothered me a lot when writing with pyautogui.

spaghettiking
Автор

Hi, what theme are you using for the python code?

xSensu
Автор

Keras ocr takes approx 3 sec per frame of a video. How to make it faster as I have 100k frames per video

Udayanverma
Автор

how about using Win32 API directly ? It would have been nice if you had compared that too.

alfred.clement
Автор

Ugh. I'm going to have to move away from pyautogui and get my hands dirty with opencv template matching :/ and threading

UaintDoxinme
Автор

I use pywin it's 2 times faster then mss sometimes more

eThan-kt
Автор

Run mss with 2 thread, increasing upper 30 fps.

vio
join shbcf.ru