CycleAI: Empowering cyclists in fighting for their own safety through AI
CycleAI: Developing human/machine alliance to boost safer cities
Perception of risk impedes people from cycling. We aim to build an AI model that automatically estimates a score of perceived safety based on objects in an image. Using Google Street View, a complete map of safety will be affordably created for entire cities, enhancing urban planning and policies.
Team membersLuís Rita, Joan Calvera, Miguel Peliteiro
Members roles and background
Background: Biomedical Engineer, Data Scientist, PhD Student in Computational Medicine. And an everyday cyclist
Roles: Data Scientist, Lead Engineer, Project Manager
Background: Industrial Engineer. President and Founder of CycloCat. Biking enthusiast
Roles: Product Manager, Product Validation, Routes Development Engineer
Background: Medical Doctor, Clinical Researcher. Freelancer. Violently ran over on cycle path
Roles: PR and External Relations, Social Media Manager, Operations Manager
Generally, our idea consists in creating an AI model to analytically estimate a perceived safety score for every image being analysed.
By crowdsourcing, we intend the crowd to label compiled Google Street View images according to their perceived safety and we will rank them according to their perception.
Once the dataset is complete, the second step would be to detect and recognize objects and structures in the images. By using the most up-to-date object detection (YOLOv5) and image segmentation (PSPNet101) software, this would enable us to detect over 80 categories of objects (people, cars, signs…) and structures (road, sidewalk...) present in the images, their dimensions and location.
The third step is to train an AI model which would automatically estimate the perceived safety score for a cyclist for any given image.
Ideally, we will be able to automatically estimate a complete map of cyclist’s perceived safety for an entire country with minimal costs (GSV available in most developed countries). In parallel to this, we intend to develop a software which calculates the safest and shortest route using AI technology: riders may select two points of the nodal net and choose their preferred path based on a multitude of variables. Plus, the user would also have the possibility of taking a photo of a given area, input in the website and obtain a score for the updated image within a few milliseconds.
Authorities, on the other hand, will be empowered by our integrative urban datasets crossing accident distribution and risk perception, translating data analysis into decision-taking towards greener, safer and more sustainable cities. Building a holistic measure of safety will help them locate unsafe hotspots or spots needing intervention, while working with urban labs on solutions to promote change.
Nowadays, [active] mobility is a priority theme for the EU in the context of urban development. Smart cities are looking into being greener, safer and sustainable, fomenting people to take a leap from using cars to bikes or other sustainable methods of transport. Even further, cities are redesigning themselves for the actual pandemics, adding and widening bike lanes to encourage cycling and accommodate more riders.
At the same time, thousands of people lose their lives on our roads every year. Of these, 70% of all accidents take place in urban areas. Numbers are even more frightening as we consider active users – cyclists and pedestrians – alone stand for 50% of the fatalities. How do we expect people to spread the use of bicycles while this happens? The planning and ordering of cities through appropriate infrastructures are urgent, alongside a safe and efficient transport network aimed at active mobility - both on foot and by bicycle.
However, managing transportation systems and urban planning is a difficult task. It takes resources, people, time, money, and it is fairly subjective. Or else, let’s put it this way: urbanism is arbitrary, mobility is subjective, accident risk and deaths on the road are real. Why not keep it analytical? We sure want to make planners’ life easier by shaping it more analytical and cost-efficient.
It is not only an isolate matter of dedicating public spaces; nor pinning down the 130B€ congestion costs EU citizens; nor the 1T€ transports’ externalities demand; nor is it dropping CO2 emissions and air pollution; nor just about living healthy, promoting sustainable commuting solutions – it’s all of this, altogether.
For all these reasons, cyclists must come forward with voice in urban and mobility matters. We intend to empower them, giving them a better understanding of their position on the scene. By backing them up with data, we expect them to take a stand towards boasting cyclable solutions while tackling blatant road safety issues.
Solution target group
We are aiming at different target groups, providing a tailor-made solution to each: general riders, commuters, authorities, km0 tourists and long distance cyclotourists. Check “Impact” to read further on how we will be providing solutions to each and every player throughout the bicycle community.
We expect to provide tailor-made solutions to each target group:
- Commuters: to empower those willing to change transportation methods into bikes in commuting trips (0-10 Km). We tend to see weather as the greatest issue, although it’s really not. We hesitate in commuting by bicycle simply because it is perceived as dangerous! Road safety is an issue, as are poor urban planning, polluted cities, and the blatant lack of infrastructure. Let’s promote change!
- General riders: to develop a routing planner which calculates the shortest and safest route. The user can access a map on our website – all the tracks verified by CycleAI. Selecting the starting, finishing point and the adequate cyclist level, we create a personalized route which can be downloaded in GPX format, so it’s easy to follow using a smartphone or a GPS device.
- Authorities: most municipalities look towards cyclable solutions, but to connect urban areas / cities is hard. We intend to integrate cities’ urban data through a datahub to be analyzed in correlation with the perception of risk. Alongside GIS, architects, engineers and urban planners, we will be offering joint urban planning suggestions and services. By locating unsafe hotspots or spots needing intervention in the existing net, or by suggesting new connections alongside the net, improving mobility will be our solution.
- Km0 tourists: a rising tendency in Europe: mass, long-distance tourism models are not sustainable, so some prefer to re-discover local territory – by bike! We want to make mobility easier around Europe, fomenting cyclotourists to leave the city and get lost into the rural local world. The calculated routes can be adapted to a wide range of audience, through different setups.
- Long distance cyclotourists: considering the last topic, this technology could also help ECF to develop the promising EuroVelo net throughout Europe.
Solution tweet textPerception of risk impedes people from cycling. We aim to build an AI model to estimate a score of perceived safety based on the objects in an image. Using Google Street View, a map of safety will be affordably created for entire cities, enhancing urban planning and policies.
We can point out several differentiation factors throughout the solutions proposed:
1) In order to determine a path to follow by cyclists, Google provides a “bike” layer under God-knows-what-variables exactly in some cities (eg. Barcelona, Rio de Janeiro). It is not even available in Portugal, though. Our platforms will be open, clear and transparent, available to all
2) There are some associations, such as the Portuguese MuBi, which facilitate mentorship by a “buddy” to help you define cycling routes to commute. We love the initiative (Really! For the cause!), but it is fairly subjective and not so analytical. We are stepping up on the game by providing analytically assessed perceived risks and conditions towards decision-making
3) There are no easy and/or accessible tools that GIS, urban planners, architects, engineers can use towards facilitating urban planning and mobility solutions. Even if there really are some in the market, those are definitely not widely available and cost-effective. We, on this side, only require few tech resources and little money to make this happen
4) The feasibility of our project is an innovation itself – from the information to be obtained via crowdsourcing, to the open source 500.000 images from the GSV, the AI tools widely available, the application of a deep-learning model already developed and creation of an easily achievable GPX software, there’s little to be wrong about this.
All it really takes is interest, will & determination - and we sure have that!
If there is an aspect to our idea that buzzes our ears is its transferability, the capacity to broaden our horizons to other places and plans.
On one hand, we are delighted to be a part of the WorldWideWeb taskforce into a cleaner, safer, greener world. To acknowledge our worldwide range is a great joy. As long as there is GSV we are able to work in open source, and GSV is available in the vast majority of European countries (or developed countries around the world). The rest of the project is mainly developed over the internet, so it is limitless.
Both people from all over the world can have access to safer commuting options, or general interest routes depending on personal preferences; and authorities, cities, or countries may apply their local efforts into their specific region of interest, towards the development of preventive & definite measures – with subsequent effective change – on promoting road safety, tackling accident hotspots, rearranging municipalities and promoting more sustainable mobility solutions.
On the other hand, this whole idea can later be applied to assess pedestrians, motorbike riders, car and truck drivers, you name it. We would aim to bring all parts of road mobility into the discussion table, kids and elderly people included. No road is safe if only one group circulating there is – it is an exercise of global, holistic risk and safety assessment by tackling lack of compulsory standards on cycling infrastructure design.
We will take action on the line, providing web-based solutions. And this is the point where we get advantage in what concerns the viability of the project through space and time.
Based on the continuous web-based crowdsourcing, we will stack ongoing data into our dataset. The more opinions we receive, the more robust the dataset gets. As data generates data, in loop, it subsists for itself, so our analysis and outputs can only grow stronger and vigorous, analytically.
Moreover, on the object detection and image segmentation side there is also space to develop on the move. We aim to retrain the object detection model with a new labelled dataset (developed by our team), to be able to detect an increased number of objects on the road. The algorithm will continuously be upgrading itself as long as the crowdsourcing goes. We have retrained in the past an algorithm that automatically recognizes whether riders are using a helmet (Towards Data Science article in the links section).
Finally, once we have reached enough reliability on the first phase explained above – we expect this to be achieved within the first two months of work –, we would go on to get the data analysis done. Then we would be producing our first outputs, while making the data available to the target groups into serving different purposes. The ultimate pinpoint would be to achieve a model which allows people to upload their own image, providing perceived safety interpretation within milliseconds at our website, or even a built-in app.
As stated before, both the dataset and the data analysis will constantly be fed with rigorous updates under our supervision. We could fantasize diverse and futuristic applications on and on, but that is not our point. We will be glad enough if this actually translates into actual savings in data maintenance, data analysis, improved urban planning and, more importantly, we want this to be saving lives.
Solution team work
Our shared story starts in May 2020 when our member Miguel Peliteiro, a young, tech-savvy medical doctor, is run over by a car while cycling on a bike path. He then got critically injured, 3-week induced coma, a total of 5 surgeries during a 4-month hospital stay. He was at the hyperbaric chamber, doing oxygen-therapy, when first learned about Luís Rita.
As of August 2020, Luís Rita, a skillful data scientist and daily bike user, develops Become a Better Cyclist with Deep Learning on his MRes at the Imperial College London (where he is currently working on his PhD). It uses AI in order to extrapolate cyclists' road risk factors from images of London, United Kingdom. The project was a hit, earning him the “Top Talent Under 25” recognition and enough projection for Miguel to acknowledge his work.
The two Portuguese eventually linked, finding a harmonization between message and messenger. They brainstormed, pitched professionals on the field and decided to take action. Ended up drafting an ambitious project – experimental to date – and went all in to participate in the 2020 ECF Hackathon with their ideas!
It was on the 13th November 2020, at the Hackathon, when they met Joan Calvera. Joan is an amateur cyclist, a bright Industrial Engineer of profession. He founded CycloCat 5 years ago, a reference website for interurban bike mobility in Catalonia. Identifying unmet needs, he studies similar cases in other countries and finally projects a nodal net, ready to be implemented on a routing software.
This three-way marriage was a perfect match. Luís, the data scientist, assumes the project in the backend supervising tasks, while Joan handles its real-life applications based on his knowledge on the scene. Miguel takes care of communication, external relations and manages operations.
We may not re-plan a city in a year, but we can certainly influence it in the mid and long term. We cannot move streets or buildings, but we can re-define how people will move and interact.
* Climate-KIC publishes the proposed solutions developed during the DigiEduHack event solely for the purposes of facilitating public access to the information concerning ideas and shall not be liable regarding any intellectual property or other rights that might be claimed to pertain to the implementation or use any of the proposed solutions shared on its website neither does it represent that it has made any effort to identify any such rights. Climate-KIC cannot guarantee that the text of the proposed solution is an exact reproduction of the proposed solution. This database is general in character and where you want to use and develop a proposed solution further, this is permitted provided that you acknowledge the source and the team which worked on the solution by using the team’s name indicated on the website.