AWS Builder Center
Which Tree Should Go Here? Green Lungs on AWS

Which Tree Should Go Here? Green Lungs on AWS

From Delhi’s haze to healthier streets: how we used local air, heat and water data to rank tree species for any spot and plan 20 years of impact on AWS.

INTRO

Delhi is dealing with two environmental problems at once: dirty air and extreme heat. New Delhi was the world’s most polluted capital in 2025, with an average PM2.5 of 82.2 µg/m³ against a WHO annual guideline of 5 µg/m³. That is about 16 times the recommended level.  thewire (link)
Trees can help with both, but the species matters. Saplings are often chosen without checking local pollution, heat, water availability or how well each species captures particles. For this hackathon, our team built Green Lungs to answer one question: which tree should go here?

What Green Lungs does

You search for a place or paste coordinates. The app then:
  1. Matches it to the nearest study site we have data for
  1. Builds a seasonal baseline of that site’s air quality, heat and water conditions
  1. Ranks tree species by how well they fit those conditions
  1. Assigns species to the site’s planting spaces on a satellite map
  1. Projects growth, survival, impact and cost over 20 years
Our data covers 3 study sites, 293 planting patches and 13 species. The rest of this post follows one example, Anand Lok.


Step 1: Understand the site

The app ranks each site’s pressures from most to least pressing, using averages from that site’s own 2024 to 2026 records. For Anand Lok the order was:
  1. Monsoon waterlogging was the biggest pressure, with 717 mm of rain from July to September. Roots can sit in saturated soil, so wet-root-tolerant trees are favoured.
  1. Fine particle pollution averaged 91 µg/m³ PM2.5, 1.5 times the 60 µg/m³ national limit the app uses, and the limit was exceeded in 64% of hours.
  1. Ozone and traffic gases averaged 89 µg/m³ ozone and 38 µg/m³ nitrogen dioxide. Trees that release many natural gases can add to ozone, so high emitters are penalised.
  1. Heat, with 24% of hours feeling like 35 °C or hotter.
  1. Dry air and limited water, with 940 mm of rain a year and a vapour pressure deficit of 1.6 kPa.


Step 2: Rank the species

Each species is ranked on how well it handles those conditions, weighed against its survival, local suitability and cost. Anand Lok’s top six:

The ranking isn’t just about particle capture. Peepal captures more than three times as much PM2.5 as Neem, yet Neem ranks first. The score also weighs survival, cost, heat tolerance and the site’s needs, and each row includes a plain-language “why it fits” note so the reasoning is visible.
When trees are assigned to planting patches, we filter by site type, width, area and spacing, and cap any single species at 40% of the plan so it stays diverse.

Step 3: See how the plan plays out

Young trees deliver little at first. Every impact is scaled by how much canopy a tree has reached and how many saplings survive, so benefits build slowly and then compound. For Anand Lok the 20-year plan comes to:
  • 793 trees planted
  • 2,452.2 kg of PM2.5 captured
  • 52,076 m² of canopy shade by year 20
  • ₹52.8 lakh total cost
  • ₹2,153 per kg of PM2.5 captured
Spending is front-loaded (planting, saplings and guards), then drops to a low yearly maintenance cost while captured pollution keeps rising with canopy. Results can be downloaded as JSON, and the map layers as GeoJSON.
->IMPACT SCALED BY SIZE

->GROWTH CURVE


How it runs on AWS

Green Lungs is a FastAPI application, with a Leaflet map and Chart.js charts, packaged as a Docker container and deployed on AWS Elastic Beanstalk in the Sydney region (ap-southeast-2).
  • The environmental, species and planting-space datasets are read from a local folder packaged with the app.
  • Place names are resolved with OpenStreetMap Nominatim, and users can also enter coordinates directly.
  • The app has a health-check endpoint and interactive API docs.
Future versions could add Amazon S3 for dataset storage, Amazon Location Service for place search, and more AWS monitoring

ARCHITECTURE



Honest limitations

->The growth, survival and cost curves use synthetic parameters. They compare species with each other and aren’t forecasts.

->Baselines come from modelled data at our study sites and apply only within 5 km. Beyond that, the app declines to answer.

->Planting spaces are drawn as circles sized to each patch’s area, not true outlines.

What’s next

More study sites, true patch outlines, real survival data from field records, and the AWS upgrades above.
Team: Pranay Bhardwaj, Navya Gupta, Vanshika , Vansh Vaibhav
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article