Inspiration

Typically, all University of Maryland students receive countless emails regarding UMPD incidents, such as robberies, suspicious activities, and indecent exposures. However, due to these countless emails, it is hard to keep track as to where every incident occurs. Also, it is impossible for every student to be aware of every incident that takes place because emails aren’t sent for every single event that takes place.

As a result, we wanted to create a web application which displays where these types of incidents happen, so that students can not only be aware but also avoid areas of potential danger.

What it does

It is a web app that webscrapes information from the University of Maryland Police Department’s Daily Crime and Incidents public data and plots it onto an interactive map with color-coded markers.

Additionally, the app updates in real-time. So when UMPD adds new reports, the map updates in real time and adds those markers.

How we built it

We built our project through multiple layers of code and documentation needed to make every part of the project work. We web scraped (using BeautifulSoup) through the UMPD listings of all incidents that have occurred over the last two months, and took this information and put this into a pandas dataframe. From there, we took the data frame and put markers by using the location of the incident and finding the longitudinal and latitudinal coordinates through the use of Google’s Geocoding API to plot the points and to clean up address formats. We used the descriptions from the incidents (like their types, addresses, and dispositions) that were inputted into the database to create a description.

Challenges we ran into

One of the main challenges in our project was that we first ran into environmental issues, which made it difficult to import Python libraries that we used, such as Pandas and Folium. As a result, pathetic as it was, we had to use Google Colaboratory in order to program part of our project before switching back to a better, permanent IDE: VScode. We also had issues with transferring a frontend markup from Figma to HTML and CSS. Besides that, there were just a lot of bugs with Folium’s map making, the web scraping, and the geocoding api, which caused some inconvenience at times.

Accomplishments that we're proud of

We are proud that we learned how to use multiple different python libraries like folium, request, csv, pandas, BeautifulSoup, IPython, date-time, and geopy in such a small amount of time. We are also proud of utilizing html pages with css styling in order to make a functional website and webpage, and are proud of making an interactive map.

We are also proud of the idea we chose, because it is a present and immediate concern for students like us at the university. Thinking of the idea is the hardest part, so once that was done, implementation was not too complicated to figure out.

What we learned

Although we learned how to use multiple libraries, the most important thing that we learned was how to delegate backend and frontend tasks between one another and combine projects and code with each other to be more productive and to use our strengths. It was enlightening to see how complex backend material can be added to html pages through just one line of code, after which styling becomes easy.

What's next for IncidentExposed

In the future, we plan to move towards other campuses and generate similar statistics to include the entirety of the nation. We also look forward to increasing speed and automation of updates to create alerts the moment an incident is reported. Lastly, we look to provide more information about the incident using analytical graphs and charts.

Built With

Share this project:

Updates