Computer Vision for the Web
eBook - ePub

Computer Vision for the Web

  1. 116 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Computer Vision for the Web

About this book

Unleash the power of the Computer Vision algorithms in JavaScript to develop vision-enabled web content

About This Book

  • Explore the exciting world of image processing, and face and gesture recognition, and implement them in your website
  • Develop wonderful web projects to implement Computer Vision algorithms in an effective way
  • A fast-paced guide to help you deal with real-world Computer Vision applications using JavaScript libraries

Who This Book Is For

If you have an interest in Computer Vision or wish to apply Computer Vision algorithms such as face, custom object, and gesture recognition for an online application, then this book is ideal for you. Prior understanding of the JavaScript language and core mathematical concepts is recommended.

What You Will Learn

  • Apply complex Computer Vision algorithms in your applications using JavaScript
  • Put together different JavaScript libraries to discover objects in photos
  • Get to grips with developing simple computer vision applications on your own
  • Understand when and why you should use different computer vision methods
  • Apply various image filters to images and videos
  • Recognize and track many different objects, including face and face particles using powerful face recognition algorithms
  • Explore ways to control your browser without touching the mouse or keyboard

In Detail

JavaScript is a dynamic and prototype-based programming language supported by every browser today. JavaScript libraries boast outstanding functionalities that enable you to furnish your own Computer Vision projects, making it easier to develop JavaScript–based applications, especially for web-centric technologies. It makes the implementation of Computer Vision algorithms easier as it supports scheme-based functional programming.

This book will give you an insight into controlling your applications with gestures and head motion and readying them for the web. Packed with real-world tasks, it begins with a walkthrough of the basic concepts of Computer Vision that the JavaScript world offers us, and you'll implement various powerful algorithms in your own online application. Then, we move on to a comprehensive analysis of JavaScript functions and their applications.Furthermore, the book will show you how to implement filters and image segmentation, and use tracking.js and jsfeat libraries to convert your browser into Photoshop. Subjects such as object and custom detection, feature extraction, and object matching are covered to help you find an object in a photo. You will see how a complex object such as a face can be recognized by a browser as you move toward the end of the book. Finally, you will focus on algorithms to create a human interface.

By the end of this book, you will be familiarized with the application of complex Computer Vision algorithms to develop your own applications, without spending much time learning sophisticated theory.

Style and approach

This book is an easy-to-follow project-based guide that throws you directly into the excitement of the Computer Vision theme. A "more in less" approach is followed by important concepts explained in a to-the-point, easy-to-understand manner.

Tools to learn more effectively

Saving Books

Saving Books

Keyword Search

Keyword Search

Annotating Text

Annotating Text

Listen to it instead

Listen to it instead

Computer Vision for the Web


Table of Contents

Computer Vision for the Web
Credits
About the Author
About the Reviewer
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
1. Math Never Was So Simple!
Installation and core structure representation of JSFeat
Initializing the project
Understanding a digital image
Loading an image into a matrix
Basic matrix operations
Going deeper
Matrix displaying
Useful functions and where to use them
Sorting using JSFeat
Linear algebra
A perspective example
Summary
2. Turn Your Browser into Photoshop
Introducing the tracking.js library
Installation and image loading
Conversion between JSFeat and tracking.js image formats
What is filtering and how to use it?
Image convolution
The Gaussian filter and separate convolution
The box blur
The integral image
Basic edge detection
The Sobel filter
Other operators
Advanced image processing
The Canny edge detector
Histogram equalization
Summary
3. Easy Object Detection for Everyone
Detecting color objects
Using predefined colors with the tracking.js library
Using your own colors
Digging into the tracking.js API
Using the <img> and <video> tags
Building a custom tracker
Image features
Detecting key points
A practical example
Descriptors and object matching
The BRIEF and ORB descriptors
Descriptors implementation and their matching
Finding an object location
Summary
4. Smile and Wave, Your Face Has Been Tracked!
Face detection with JSFeat
Face detection using Haar-like features
Brightness binary features
Tagging people with tracking.js
Haar features with tracking.js
Tagging people in photos
Head tracking with Camshift
The idea behind head tracking
The head tracking application
Summary
5. May JS Be with You! Control Your Browser with Motion
Basic tracking with tracking.js
An example of an object tracking application
Controlling objects with the head motion
The Head-coupled perspective
Controlling a simple box
Optical flow for motion estimation
The Lucas-Kanade optical flow
Optical flow map with oflow
Track points with JSFeat
Zooming with gestures
Summary
6. What's Next?
Refresh your memory
Importance of client-side scripting
Other interesting libraries in Computer Vision
CCV library and its extensions
Face detection and more
Object detection with js-objectdetect
Summary
Index

Computer Vision for the Web

Copyright © 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: October 2015
Production reference: 1091015
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78588-617-1
www.packtpub.com

Credits

Author
Foat Akhmadeev
Reviewer
Noritsuna Imamura
Acquisition Editor
Tushar Gupta
Content Development Editor
Amey Varangaonkar
Technical Editor
Vivek Pala
Copy Editor
Pranjali Chury
Project Coordinator
Francina Pinto
Proofreader
Safis Editing
Indexer
Mariammal Chettiyar
Graphics
Disha Haria
Production Coordinator
Arvindkumar Gupta
Cover Work
Arvindkumar Gupta

About the Author

Foat Akhmadeev has 5 years of experience in software development and research. He completed his master's degree in the year 2014 from the Kazan Federal University, Russia. He has worked on different projects, including development of high-loaded websites written in Java and real-time object detection for mobile phones. He has an extensive background in the field of Computer Vision. He has also written a scientific paper on 3D reconstruction from a single image. For more information, you can visit his website at http://foat.me.

About the Reviewer

Noritsuna Imamura is a specialist in embedded Linux/Android-based Computer Vision, and is one of the main members of SIProp.org (http://siprop.org/). His main works are as follows:
  • ITRI Smart Glass, which is similar to Google Glass. He worked on this using Android 4.3 and OpenCV 2.4 in June 2014 (https://www.itri.org.tw/chi/Content/techTransfer/tech_tran_cont.aspx?&SiteID=1&MmmID=620622510147005345&Keyword=&MSid=4858).
  • The Treasure Hunting Robot, a brainwave controlling robot that he developed in February 2012 (http://www.siprop.org/en/2.0/index.php?product%2FTreasureHuntingRobot).
  • OpenCV for Android NDK. This has been included since Android 4.0.1 (http://tools.oesf.biz/android-4.0.1_r1.0/search?q=SIProp).
  • The Auto Chasing Turtle, a human face recognition robot with Kinect, which he developed in February 2011 (http://www.siprop.org/ja/2.0/index.php?product%2FAutoChasingTurtle).
  • Feel Sketch—an AR Authoring Tool and AR Browser as an Android application, which he developed in December 2009 (http://code.google.com/p/feelsketch/).
He can be contacted via e-mail at .

www.PacktPub.com

Support files, eBooks, discount offers, and more

For support files and downloads related to your book, please visit www.PacktPub.com.
Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at for more details.
At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.
Support files, eBooks, discount offers, and more
https://www2.packtpub.com/books/subscription/packtlib
Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can search, access, and read Packt's entire library of books.

Why subscribe?

  • Fully searchable across every book published by Packt
  • Copy and paste, print, and bookmark content
  • On demand and accessible via a web browser

Free access for Packt account holders

If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view 9 entirely free books. Simply ...

Table of contents

  1. Computer Vision for the Web

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn how to download books offline
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 990+ topics, we’ve got you covered! Learn about our mission
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more about Read Aloud
Yes! You can use the Perlego app on both iOS and Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app
Yes, you can access Computer Vision for the Web by Foat Akhmadeev in PDF and/or ePUB format, as well as other popular books in Computer Science & Programming in JavaScript. We have over one million books available in our catalogue for you to explore.