## Steps to create and test multi-tracker maps WIP https://docs.google.com/document/d/1LacVuubl4T4CtGzy1KT_GsWrjV-DOI8XQFuLsUliT88
GEM Tracker Maps is served entirely staticly, with no build process. Each tracker only requires a JSON based configuration file, and a data file (CSV or JSON, as currently produced for GEM Trackers).
/src/
contains the site code, styling information, layout, and supporting assets like images.site-config.js
contains site wide configuration that applies to all trackers/trackers/
contains a director for each trackerClone the repo. Create a new directory under /trackers/
. Place the data for the tracker there. Create a symlink to index.html
: while in the new directory, ln -s ../../src/index.html
. Create a config.js
. Commit to GitHub.
First, there are sitewide configurations with site-config.js
. Any parameter can be configured site wide. Documentation on the typical site wide parameters is in that file.
The config.js for coal-plant
has documentation on the parameters typically set for a tracker.
Fork the repository. Place new data file in the appropriate tracker directory. Test and do quality checks on that fork. When ready, make a pull request to the main repository. And accept the pull request to make the update.
Responsibilities of this repo (hint: maybe we separate this out to other repos soooon)
Non IDE set up / external process duties
IDE set up
adjust all_config.py based on your needs (primarily these initial four and any local file path) –trackers_to_update = [‘Integrated-simple’]# official tracker tab name in map tracker log sheet –new_release_date = ‘June_2025’ # for find replace within about page NEEDS TO BE FULL MONTH –releaseiso = ‘2025-06’ # YYYY-MM-DD (day optional) –simplified = False # True False –priority = [’’] # allows you to prioritize global, regional or internal output files
If you have a new tracker to set up, add to the renaming_cols_dict in all_config.py and add net new columns to final_cols, currently you may want to run the script and check the final names first, since the js map code requires certain formatting, so the dictioanry renaming_cols_dict may not be the final col name
Important files to run after non IDE and IDE setup
python run_maps.py
– make_metadata.py
– make_data_downloads.py
– make_maps.pyCurrently only used for GIPT map. Adjusted in the tracker/map’s config file with the flag “tile” instead of “csv” or “json”
Detailed GEM Specific Instructions for creating and updating GIPT tiles
Install csv2geojson and tippecanoe
% csv2geojson --numeric-fields "Capacity (MW)" Global\ Integrated\ Power\ data\ 2024-02-14.xlsx\ -\ Sheet1.csv > integrated.geojson
% tippecanoe -e integrated-2024-02-14.dir --no-tile-compression -r1 -pk -pf --force -l integrated < integrated.geojson
Copy local files to digital ocean spaces recursively and set public
aws s3 cp --endpoint-url https://nyc3.digitaloceanspaces.com PATH/TO/DIR/TILES/FROM/TIPPECANOE s3://$BUCKETEER_BUCKET_NAME/NAME_OF_FOLDER_IN_DIGITAL_OCEAN/NAME_OF_SUB_FOLDER_IN_DIGITAL_OCEAN --recursive --acl public-read
This can be hosted directly from GitPages.
If hosting on another webserver, the entire repo should be available from a directory on the webserver.
Official Maps can be found at this repo:
Live branch is gitpages-production
Maps spun up for PM review before pushed to live can be found in this repo:
Live branch is gitpages-production
GMET (add in pipelines soon)
GOIT (able to change soon)