Book Image

Computer Vision Projects with OpenCV and Python 3

By : Matthew Rever
Book Image

Computer Vision Projects with OpenCV and Python 3

By: Matthew Rever

Overview of this book

Python is the ideal programming language for rapidly prototyping and developing production-grade codes for image processing and Computer Vision with its robust syntax and wealth of powerful libraries. This book will help you design and develop production-grade Computer Vision projects tackling real-world problems. With the help of this book, you will learn how to set up Anaconda and Python for the major OSes with cutting-edge third-party libraries for Computer Vision. You'll learn state-of-the-art techniques for classifying images, finding and identifying human postures, and detecting faces within videos. You will use powerful machine learning tools such as OpenCV, Dlib, and TensorFlow to build exciting projects such as classifying handwritten digits, detecting facial features,and much more. The book also covers some advanced projects, such as reading text from license plates from real-world images using Google’s Tesseract software, and tracking human body poses using DeeperCut within TensorFlow. By the end of this book, you will have the expertise required to build your own Computer Vision projects using Python and its associated libraries.
Table of Contents (9 chapters)

Creating and training a support vector machine

In this section, we're going to create and train a support vector machine that will actually perform our digit classification.

In the very first example, we're going to use scikit-learn, and we're going to use what's called a support vector machine, which is a very powerful, very versatile classic machine learning technique that can learn all kinds of functions and all kinds of mappings from inputs to outputs. We're going to do classification, which is mapping inputs as an array of pixels, and in our case we're going to classify each input into one of ten classes, corresponding to ten digits. But we can classify different kinds of things as continuous ordered functions, which is called regression, and that can be useful, for example, if you want to extract position or an area of volume where it doesn...