Skip to content

Soy Deforestation Assessment

View or edit on GitHub

This page is synchronized from trase/engagement/brazil/soy_risk_benchmark/soy_deforestation_assessment/README.md. Last modified on 2026-04-14 15:19 CEST by Nicolas Martin. Please view or edit the original file there; changes should be reflected here after a midnight build (CET time), or manually triggering it with a GitHub action (link).

Soy Deforestation Comparison Report

This folder contains a standalone HTML report that compares soy-related deforestation across two methodologies:

  1. GLAD + PRODES: GLAD soy area (Song et al. 2021) intersected with annual PRODES deforestation (Trase Method).
  2. MapBiomas-only: MapBiomas deforestation + secondary vegetation intersected with MapBiomas LULC soy area (Risk Benchmark method).

The data it relies on can be found in this same folder, as well as in s3://trase-storage/brazil/soy/risk_benchmark/soy_deforestation_assessment/

Contents

  • soy_deforestation_comparison_report.html - main report (single-page app)
  • Soy_BR_defo_MapBiomas_2002_2024_q1_26.csv - MapBiomas-based soy deforestation time series
  • soy_def_5y_glad_mb_orig_q4_2025.csv - GLAD + PRODES soy deforestation time series directly from Trase
  • Biomas_Trase.zip - biome boundaries overlay (shapefile ZIP)
  • slider_view/ - image comparison assets for selected regions with the most remarkable differences

Quick start (local)

The HTML fetches local CSV/ZIP files, so you need a local web server (file:// will be blocked by CORS).

From this folder, run:

python -m http.server 8000

Then open:

http://localhost:8000/soy_deforestation_comparison_report.html

Or open the direct online source:

hhttps://trase-storage.s3.eu-west-1.amazonaws.com/brazil/soy/risk_benchmark/soy_br_risk_benchmark_v3/QA/soy_deforestation_assessment/soy_deforestation_comparison_report.html

What the report shows

  1. National time series (2008-2024) for GLAD+PRODES vs MapBiomas.
  2. Biome-level differences (relative to MapBiomas vs GLAD).
  3. State-level differences.
  4. Municipality-level map of differences and absolute values.
  5. Municipality image comparison slider (MapBiomas vs GLAD).

Data sources (deforestation calculation)

  • GLAD soy area: Song et al. (2021).
  • Source: https://www.nature.com/articles/s41893-021-00729-z
  • PRODES annual deforestation maps (Brazil).
  • Source: https://terrabrasilis.dpi.inpe.br/en/faq-2/
  • MapBiomas deforestation + secondary vegetation (Collection 10).
  • Source: https://brasil.mapbiomas.org/en/
  • MapBiomas LULC soy area (Collection 10).
  • Source: https://brasil.mapbiomas.org/en/

If you have official data download links for the CSVs, add them here.

External libraries (CDN)

The report loads these libraries via CDN:

  • Tailwind CSS
  • Chart.js + chartjs-plugin-datalabels
  • PapaParse
  • Plotly.js
  • shpjs (for ZIP shapefiles)
  • Google Fonts: DM Sans, Space Mono

Configuration points in the HTML

In soy_deforestation_comparison_report.html:

  • CSV sources are defined in the sources object:
  • Soy_BR_defo_MapBiomas_2002_2024_q1_26.csv
  • soy_def_5y_glad_mb_orig_q4_2025.csv
  • Map base GeoJSON: mapUrl (external GitHub source)
  • Biome overlay: Biomas_Trase.zip (optional; report still works without it)
  • Image comparison assets: slider_view/{city}_{uf}_[mb|glad].png

Updating the data

  1. Replace the CSV files with updated versions (keep filenames).
  2. Refresh the page (hard reload).
  3. Check:
  4. Time series charts update across years.
  5. Differences by biome/state look reasonable.
  6. Map and image comparison update to the selected year/region.

Troubleshooting

  • Charts or map not loading: open browser dev tools and check for missing files (404s).
  • Local file blocked: serve the folder via python -m http.server.
  • Empty charts: verify CSV headers match the parsing logic in the HTML.