"Don't worry about people stealing an idea. If it's original, you will have to ram it down their throats." - Howard H. Aiken (https://en.wikiquote.org/wiki/Howard_H._Aiken)
This application will spot whether a video/image contains a person using a phone or doing something else a dozy driver might do whilst at the wheel of a vehicle.
In the UK there is a desire from the general public to create a shift in culture towards reducing mobile phone use (and other bad habits like speeding) whilst driving. This behaviour is rife in society because the man-power required to enforce laws against breaking the law is not present for reasons such as cuts to police force budgets (source: http://www.apccs.police.uk/press_release/budget-cuts-will-radically-change-policing/).
As technology has progressed, technology has been rolled out along the roads that makes it easier to monitor vehicles and drivers (motor bikes/cars/vans/lorries).
Some drivers simply do not give their full attention to the road whilst driving. Example: whilst going around a bend, they are texting, then veer off the road and occassionally die in a fatal accident that was easily avoidable. Or they might be a lorry driver reading/sending a text message, take their eyes off the road for 2-3 seconds, not realising a queue of slowing traffic ahead of them, then plough into the back of them causing fatalities once again (example: http://www.mirror.co.uk/news/uk-news/motorist-killed-crash-texting-wheel-5516563 - one of many).
Self driving cars are still some way off for the masses. A privileged few have access to them but the vast majority of people earning an average salary of £28,000 (in the UK) will not get access to self driving cars for a decade or so to come.
At present 1 in 4/25% of accidents involve drivers who are using a mobile phone (source: http://www.dailymail.co.uk/news/article-2591148/One-four-car-accidents-caused-cell-phone-use-driving-five-cent-blamed-texting.html). There is currently talk (at the time of writing) of asking people to be "spotters" and to shift the culture more towards making mobile phone use whilst driving perceived as more like drunk driving (source: http://metro.co.uk/2016/11/15/public-urged-to-report-drivers-who-use-mobile-phones-behind-the-wheel-6258772/). It is socially unacceptable.
This application will be implemented using the OpenCV library - free open source library as used in devices such as the Microsoft Kinect for Xbox. It includes lots of algorithms for reducing noise in images, finding objects, etc. So this is a proof of concept that should be able to identify drivers using a mobile phone whilst on the road.
This project aims to make driving a little safer for everyone else who does appreciate the laws. My vision is to roll this out using existing technology that monitors the roads, even have house holder's CCTV tap into this library to catch the bad eggs so they can earn a commission and help keep the roads safer for everyone else around them.
- This is a C++ application so you'll need that.
- You must have opencv 3.0.0 set up or greater set up.
In the shell command below opencv3 is whatever you've aliased youre installation of openCv as:
g++ -ggdb `pkg-config --cflags --libs opencv3` main.cpp -o /tmp/main && /tmp/main
If all goes well you should see the driver1.jpg image displayed in a window.
Hit 'esc' to exit.