This is the repository for TileMill project of maps for intense and recent fires at infoamazonia.org.
- Clone this repository at your machine;
git clone [email protected]:oeco/tm-fires-nasa.git
-
Symlink TileMill projects:
ln -s /path/to/repository/tilemill/fires-intense ~/Documents/MapBox/project/fires-intense ln -s /path/to/repository/tilemill/fires-recent ~/Documents/MapBox/project/fires-recent
-
Download new data setting extents (West South East North) = (-85 -59 -29 16):
-
Unzip the downloaded file at
data
folder; -
Import downloaded files, replacing 'new_data_filename' with downloaded filename without extension:
cd data spatialite_tool -i -shp new_data_filename -d fires.sqlite -t fires -c UTF-8 -s 4326 spatialite fires.sqlite < ../sql/update.sql
-
Update month and year at legend and teaser texts.
-
Regenerate maps and upload to Mapbox:
-
Commit changes to GitHub.
- Log in at the InfoAmazonia Wordpress JEO platform
- Go to the 'Maps' section and enter on Fire map
- On the 'HTML Legend' box, on the right hand column change the legend according to the month in 3 languages
If you need to regenate from scratch, download source files spliting by 3-4 years periods, e.g. 2000 to 2003, 2004-2006, 2007-2009,2010-2012, and so forth.
Merge then:
ogr2ogr -select "ACQ_DATE","BRIGHTNESS","FRP" fires.shp fires_2000-2003.shp
ogr2ogr -append -select "ACQ_DATE","BRIGHTNESS","FRP" fires.shp fires_2004-2006.shp
ogr2ogr -append -select "ACQ_DATE","BRIGHTNESS","FRP" fires.shp fires_2007-2009.shp
ogr2ogr -append -select "ACQ_DATE","BRIGHTNESS","FRP" fires.shp fires_2010-2012.shp
ogr2ogr -append -select "ACQ_DATE","BRIGHTNESS","FRP" fires.shp fires_2013.shp
Init a Spatialite database with this data:
spatialite_tool -i -shp data/fires -d data/fires.sqlite -t fires -c UTF-8 -s 4326
Create recent and intense tables:
spatialite data/fires.sqlite < sql/create.sql