Given recent events, we feel it is important for Durham students to find their way home safely after a night out. With the release of lots of data by Durham County Council, we thought this provided an opportunity to improve the safety of students in Durham.

What it does

After a heavy night out, it's important to get home safe. This means following lit streets - and, particularly in Durham - staying away from the river, and being conscious of traffic. Get Home Safe combines the familiarity and ubiquity of Google Maps with never-before-seen data points from Durham County Council to show clubbers the safest route home after a night out. Get Home Safe highlights the density of streetlights and traffic across County Durham to visually indicate to the user the safest path through the city.

How we built it

Get Home Safe is a web app using node.js and MySQL on the backend, and revolves largely around the free Google Maps API on the frontend. Each team member took care of separate parts of the project, including developing the backend, populating the database, interpreting and visualising the data, and taking care of the front end. Our database contains approximately 80,000 entries - each representing the coordinates of a street light in County Durham. Upon loading the web app, the backend dynamically sends the required entries to the user, depending on their map viewport.

Challenges we ran into

One of the initial challenges was converting the data into a usable format. The coordinates had to be bulk converted from 'easting and northing' format to 'longitude and latitude', which is no small task when there are 80,000 points to convert! We then had to load these into the database, which proved to be difficult due to the sheer number of entries. Another idea we had was to reduce the number of data points with a clustering algorithm. However, due to time constraints, it proved unfeasible to comprehend all the complex modules and techniques that would be required. We attempted to map each data point to a street - this in itself proved difficult due to the method by which Google Maps stores information about its streets and the sheer processing power this would require. We used Google's API to plot lines on the roads that were lit (i.e. that had street lights on them), and this work (although incomplete) can be seen on the Lit Roads page.

Accomplishments that we're proud of

Our interface is user friendly, responsive and well optimised. Having a nearly finished - and, crucially, usable - product in such a short space of time is something to be proud of, and we feel that our product could be tweaked and released as a commercial app. The map data is surprisingly responsive - by dynamically loading the data points that are needed and then using Google's API to convert this to a heatmap means the work done by the browser is far less than that if we were to load all 80,000 data points into the webpage.

What we learned

Using Git is something many of us had not experienced before, but now we feel we have a certain level of ability and are able to use it in future projects. node.js runs the backend of our project, and we have learnt more about making a 'static' site using Express. We learnt adaptable skills in how to take third party APIs and put these together to realise a complete idea.

What's next for Get Home Safe

The plan is to further develop the Lit Roads idea, to best show the user the safest route home. We could also further optimise the site to work on small mobile devices. We could even use more data from other county councils to expand our reach, or to include other Durham data such as footfall, and combine all this to find even safer routes home.

Share this project: