Inspiration
It’s been just two weeks since wildfires plagued the lives of many—a testament to rising pollution levels at each corner. Amidst catastrophes like these, we have leaders who either call climate change a “hoax,” or those who propose vague environmental policies without citing facts or figures.
It’s sad that we’re growing up in a world where we neglect data when we need it the most.
This disconnect motivated us to delve deeper and assess the actual impact of environmental policies and initiatives. We wanted to move beyond all the fluff and provide people with understandable data that quantifies the actual effects of environmental measures.
To this end, we created Policy2Pollution: an interactive platform that maps the impact of environmental policies on global pollution levels.
Policy2Pollution is built upon two principles. First, that data-driven decision-making is our first step toward effective change. And second, that it can be leveraged as a tool to understand the complexities of environmental issues in marginalized communities that are most vulnerable to environmental damage.
What it does
Policy2Pollution maps pollutant data and infrastructure data (airports, industries, and coal-mines) and allows users to upload information regarding policies that could have affected an area. It also allows for examining pollution trends by changing the time surrounding the implementation of a policy.
How we built it
The user enters the location, date, policy name, and policy information on the website; from here, the inputs are queried in our datasets and Google Earth Engine to create interactive maps of global pollutants and toxic waste-creating infrastructure.
For the map, the user has two options: either each layer can be viewed individually to examine the trends of just one pollutant or infrastructure based on the given environmental policies, or each layer of the map can be overlaid to compare data.
If a user wants to examine trends in the map due to a certain policy over time, they can simply drag the slider and then click on “update policy”. The positioning of the slider alters the date by a certain increment.
MongoDB was used to save policies into the Atlas. When the user clicks “save policy”, the information in the text boxes are saved into a MongoDB atlas database, and then users can load in saved databases using the dropdown.
For our user dashboard, we utilized HTML and CSS, and connected to the backend through the Flask. We credit our ease of use to the intricate backend-side communication between flask, the datasets, Google Earth Engine, and MongoDB Atlas.
Challenges we ran into
Backend:
What were our Variables?: Our first challenge was identifying relevant variables of analysis, such as airports, coal mines, and other factors that contribute to environmental impact. This required extensive research and data collection to ensure the inclusion of crucial factors in our analysis.
What was our purpose?: While doing all this, we wanted to consider how our platform could specifically address the needs and concerns of marginalized communities, requiring us to consider the unique challenges they face.
From here, we had to figure out how to convert our drive to design.
How do we adapt our code? One of the initial challenges we encountered was transferring our visualization code from Google Colab notebooks to our application. The transition proved to be difficult as the code needed to be adapted to work within the application's framework. We had to carefully adapt and optimize the code to ensure smooth functionality and maintain the visual appeal of our insights.
Hand-in-hand with this problem, we also encountered challenges when implementing a time series prediction model using Prophet. Despite successfully building the model, we faced dependency issues that prevented us from running it seamlessly within our application. To overcome this, we had to thoroughly debug and explore alternative approaches to deliver accurate predictions.
Front end:
Moreover, as a team with limited web development experience, we had to overcome the challenge of styling a webpage and creating a visually appealing user interface. This demanded learning web design principles, CSS styling, and frontend frameworks to enhance the user experience and establish smooth interaction with the backend.
Accomplishments that we're proud of
We have two prominent accomplishments.
The first accomplishment is the successful implementation of layered maps using image data from the Google Earth Engine and other datasets.
Our second accomplishment is the unique application of MongoDB to provide a feature that allows anyone to view policy information stored by other users.
Another accomplishment that we, unfortunately, couldn't implement in our website due to issues with installation on VSCode was the time-series prediction feature using google prophet.
What we learned
Before this hackathon, the term “geospatial analysis” was nothing more than a buzzword to us. So, first, it was time to get our hands dirty with the fundamentals—we learned about georeferencing, spatial data formats, spatial queries, and spatial statistics.
Armed with this newfound knowledge, we set out to figure out Google Earth Engine, a cloud-based platform for geospatial analysis, so that we could extract meaningful insights about pollution levels from satellite imagery. This enabled us to paint a clearer picture of the real-world consequences of environmental policies.
To effectively communicate our findings, we delved into the realm of data visualization. Through setting up a backend with Flask, a Python web framework, we learned how to create interactive visualizations. We also explored various libraries like geopandas, folium, and fiona to create visually engaging representations like layered heatmaps, ensuring that our insights were easily understandable and impactful.
Finally, we ventured into the world of cloud-connected databases. Through working with MongoDB, we learned how to efficiently store, retrieve, and query geospatial data, allowing us to access and analyze data seamlessly throughout the project.
What's next for Policy2Pollution
In the short-term, we want to add features that map major pollutants in areas that are most vulnerable to environmental damage. It’s no question that climate change impacts some communities more than others, and we’d love to be part of building something that helps policymakers understand their unique and complex challenges.
And with this, as a long-term bigger picture goal, we want to scale Policy2Pollution to pave the road for further data-driven insight onto the complex nature of environmental policies: what are other corresponding socioeconomic impacts? are there associated health concerns? what’s the interplay with other variables? are there capital tradeoffs we make with exorbitant amounts of spending?
The possibilities are endless, and Policy2Pollution is the first step.
Log in or sign up for Devpost to join the conversation.