Police forces in the UK and the US has been predicting crime hotspots using machine learning on historic data. We wanted to help other emergency services such as ambulances and hospital A & E prepare in advance using the same techniques. This would enable them to save more lives.
What it does
We used historical accident data about the UK for 10 years to learn about the location, road conditions, weather conditions, speed limits, time of the day / lighting conditions, age and gender of the drive and how they affect the probability of a driver to be involved in an accident.
Our software does two things:
When someone departs for a journey, we plot their journey on the map and predict the accident prone hot spots on their route and warn them in advance to drive carefully as they approach that area.
We display a heat map for ambulance drivers and hospitals of how new accidents will occur in new areas as the time of the day (lighting, weather & traffic conditions) change. This enables them to plan a better route & patient pipe line for their ambulances.
How we built it
For the UI, we built it using the Google Maps API with heat map visualisation along with node Js / express / mysql for the historic data api. Use their routing API
Machine learning API: Flask with R backend (invoked as a sub-process)
Challenges we ran into
Lots of minor issues with our machine learning implementation which include:
- Imbalanced classes
- Feature select was an issue due to the huge dataset we used (2M records)
- Location data involving longitude and latitude was complex to handle
Breaking NodeJS (out of memory) when trying to import and sanitise the huge dataset.
Performance related plotting the data on UI due to the huge dataset.
Accomplishments that we're proud of
Initially we were frustrated with the model performance (Accuracy). With after spending more time on this we improved this score. Also after cross referencing some research papers we realised that we were not too far off from state of art accuracy.
What we learned
- The challenges of feature selection on datasets so large, its hard to even load it up.
- Handle geolocation / spatial data
- Optimising web UIs for displaying large datasets.
What's next for AccidentallySafer
Make the platform open source to allow for hospitals and ambulance drivers predict locations of potential accidents. Advanced preparation for casualties will help to reduce patient's waiting times at A & E.
Push this service to Sat navs like Google map and TomTom. When drivers are about to drive through an accident prone area, they'll be warned in advanced to take extra care just like speed camera alerts.