Preparing a Raspberry Pi for OpenCV development is really time consuming, OpenCV takes hours to compile and a lot of other things have to be set up, so I just share my SD Card image here to speed up Raspberry OpenCV development for others. I shrank the root partition to 7GB to make it suitable for smaller SD cards. It has 300MB free space only so you better expand it to fit on the target SD card. You can do this right on your raspberry with an additional USB-SD card stick and gparted. User/pass is pi/raspberry. After startup it autologins directly to OpenBox. Right click -> Terminal emulator to open a terminal. To test and run the OpenCV examples type "workon cv" to activate the python virtual environment, go into "/home/pi/Desktop/OpenCV-Face-Recognition-master/FacialRecognition" and type "python" . If you have a raspberry camera installed and enabled with raspi-config, a camera window should pop up and face detection should start. For a usb camera you have to modify the scripts a little.

If you find this image useful please donate at the top of the page.

What does it contain

Base System

  • Raspbian Lite


  • openbox for window manager
  • tint2 for taskbar
  • slim for autologin
  • pcmanfm for file manager
  • chromium for stack overflow

Dev Tools

  • lxterminal for terminal
  • vim/nano for python
  • codeblocks for c/c++ development
  • python for opencv development
  • opencv 4.0 for computer vision
  • picamera python module for the raspberry camera
  • opencv face recognition examples


  • Scratch, Termite, Cortex, Brawl for short rests ( enable full KMS OpenGL support in raspi-config to play them )


Comment on MilGraPi
comments powered by Disqus