Inspiration
Late-night walks have always been filled with uncertainty. Whether our group members are walking home after a late-night game or simply biking home from school, there is always the concern of making it home safely
Pharos comes from an ancient "lighthouse", guiding users through the dark as a beacon of light.
What it does
While all modern maps are built with a complete emphasis on speed, Pharos works by using a safety index algorithm to find the safest route, along with speed based on historic crime in the area.
How we built it
Pharos takes data from the San Francisco crime data set, which tells the computer where the crimes occurred, the type of crime, and when the crime occurred. The data takes in crimes from 2018 tothe present day with over 1 million occurrences.
This data is then all put into a comprehensive LLM which scores each street from the origin to destination in 1 score from 1-100.
These scores are now all placed on a map where the MapBox API finds dozens of possible routes to the destination. The safety data values are then fed into our A* algorithms, which use weighted values of each street the user is to find the safest overall path.
Challenges we ran into
One of the challenges we faced was creating an algorithm that took danger and pathfinding into account. It was difficult to think of an algorithm that would properly balance distance and safety We settled on an algorithm that generated many different paths, and then added danger scores with a weighting to penalize the algorithm for taking a dangerous path. Integrating Frontend (typescript) with Backend (python) We solved this by creating an api that relays information from the backend to display on the frontend.
Accomplishments that we're proud of
We're proud of the algorithm we wrote to generate an optimized path while taking into account speed and safety We are also proud of integrating our frontend, which was written in Typescript, with our backend, which was written in Python
What we learned
We learned how to combine our backend python with our front end html/css.
What's next for Pharos
Make this website into an app with both Android and iOS capabilities Create hardware like a wristwatch that analyzes and creates sound when it senses danger like gunshots Add more features like an emergency button and report danger to crowdsource safety index
Built With
- css3
- html5
- mapbox-api
- openai-api
- python
- typescript
Log in or sign up for Devpost to join the conversation.