If you want to run this script, all you'll need is opencv 2.4.11, and numpy. Change the image paths in the code to something that makes sense for you, all you need to do is change the base paths for your folders (I organized my images such that each class has its own folder of images, all in one parent folder)