{"id":309287,"name":"Geo-TIDE-backend","description":"Produce and interactively visualize publicly available geospatial data to support trucking fleets in navigating the transition to alternative energy carriers.","url":"https://github.com/mcsc-impact-climate/geo-tide-backend","last_synced_at":"2026-04-12T21:30:21.735Z","repository":{"id":226128463,"uuid":"749951605","full_name":"mcsc-impact-climate/Geo-TIDE-backend","owner":"mcsc-impact-climate","description":"Backend source code to produce geospatial data layers for the MCSC's Geospatial Trucking Industry Decarbonization Explorer (Geo-TIDE)","archived":false,"fork":false,"pushed_at":"2025-12-17T17:12:52.000Z","size":14150,"stargazers_count":3,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-27T04:25:02.450Z","etag":null,"topics":["biofuels","decarbonization","decision-support","electrification","geospatial","hydrogen","trucking"],"latest_commit_sha":null,"homepage":"https://climatedata.mit.edu/faf5/transportation/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mcsc-impact-climate.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-01-29T17:57:51.000Z","updated_at":"2025-09-27T12:11:50.000Z","dependencies_parsed_at":"2026-01-05T10:07:36.368Z","dependency_job_id":null,"html_url":"https://github.com/mcsc-impact-climate/Geo-TIDE-backend","commit_stats":{"total_commits":294,"total_committers":36,"mean_commits":8.166666666666666,"dds":0.7653061224489796,"last_synced_commit":"c43d1159ade488c2812a531c8840a567cf5d400d"},"previous_names":["mcsc-impact-climate/faf5-analysis","mcsc-impact-climate/geo-ftads-analysis","mcsc-impact-climate/geo-tide-backend"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/mcsc-impact-climate/Geo-TIDE-backend","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2FGeo-TIDE-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2FGeo-TIDE-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2FGeo-TIDE-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2FGeo-TIDE-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mcsc-impact-climate","download_url":"https://codeload.github.com/mcsc-impact-climate/Geo-TIDE-backend/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2FGeo-TIDE-backend/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31196261,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-30T12:28:04.769Z","status":"ssl_error","status_checked_at":"2026-03-30T12:28:01.577Z","response_time":138,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"owner":{"login":"mcsc-impact-climate","name":"MIT Climate \u0026 Sustainability Consortium","uuid":"157619269","kind":"organization","description":"Contains repos developed by the MIT Climate \u0026 Sustainability Consortium","email":null,"website":null,"location":null,"twitter":null,"company":null,"icon_url":"https://avatars.githubusercontent.com/u/157619269?v=4","repositories_count":1,"last_synced_at":"2024-01-24T19:01:48.070Z","metadata":{"has_sponsors_listing":false},"html_url":"https://github.com/mcsc-impact-climate","funding_links":[],"total_stars":null,"followers":null,"following":null,"created_at":"2024-01-24T19:01:48.072Z","updated_at":"2024-01-24T19:01:48.072Z","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mcsc-impact-climate","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mcsc-impact-climate/repositories"},"packages":[],"commits":{"id":8608144,"full_name":"mcsc-impact-climate/geo-tide-backend","default_branch":"main","total_commits":310,"total_committers":34,"total_bot_commits":0,"total_bot_committers":0,"mean_commits":9.117647058823529,"dds":0.6548387096774193,"past_year_total_commits":8,"past_year_total_committers":1,"past_year_total_bot_commits":0,"past_year_total_bot_committers":0,"past_year_mean_commits":8.0,"past_year_dds":0.0,"last_synced_at":"2026-04-03T17:07:38.283Z","last_synced_commit":"c5f54c858fed1d0e7d335efc8637e863cae07aff","created_at":"2025-02-05T00:08:06.433Z","updated_at":"2026-04-03T17:02:15.830Z","committers":[{"name":"Danika MacDonell","email":"43050968+danikam","login":"danikam","count":107},{"name":"Danika MacDonell","email":"danikamacdonell@Danikas-MacBook-Pro-2.local","login":null,"count":69},{"name":"cubicalknight","email":"micah.borrero@gmail.com","login":"cubicalknight","count":12},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-47-134.dyn.MIT.EDU","login":null,"count":11},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-161-6.dyn.MIT.EDU","login":null,"count":10},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-189-168.dyn.MIT.EDU","login":null,"count":7},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-18-65.dyn.mit.edu","login":null,"count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-73-104.dyn.mit.edu","login":null,"count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-40-169.dyn.MIT.EDU","login":null,"count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-237-75.dyn.MIT.EDU","login":null,"count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-144-137.dyn.MIT.EDU","login":null,"count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-103-212.dyn.MIT.EDU","login":null,"count":6},{"name":"brookebao","email":"158602782+brookebao","login":"brookebao","count":6},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-163-127.dyn.MIT.EDU","login":null,"count":5},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-18-65.dyn.MIT.EDU","login":null,"count":5},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-205-195.dyn.MIT.EDU","login":null,"count":4},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-238-32.dyn.MIT.EDU","login":null,"count":4},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-47-134.dyn.mit.edu","login":null,"count":4},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-161-6.dyn.mit.edu","login":null,"count":3},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-199-65.dyn.MIT.EDU","login":null,"count":3},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-205-195.dyn.mit.edu","login":null,"count":3},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-47-202.dyn.MIT.EDU","login":null,"count":3},{"name":"Brilant Kasami","email":"brili.kasami@gmail.com","login":"brili","count":3},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-199-65.dyn.mit.edu","login":null,"count":2},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-216-175.dyn.MIT.EDU","login":null,"count":2},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-250-183.dyn.mit.edu","login":null,"count":2},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-182-57.dyn.MIT.EDU","login":null,"count":2},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-144-137.dyn.mit.edu","login":null,"count":1},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-189-168.dyn.mit.edu","login":null,"count":1},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-245-0.dyn.mit.edu","login":null,"count":1},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-29-47-202.dyn.mit.edu","login":null,"count":1},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-12-232.dyn.mit.edu","login":null,"count":1},{"name":"Danika MacDonell","email":"danikamacdonell@dhcp-10-31-131-225.dyn.mit.edu","login":null,"count":1},{"name":"helena380","email":"145218607+helena380","login":"helena380","count":1}],"past_year_committers":[{"name":"Danika MacDonell","email":"danikam@mit.edu","login":"danikam","count":8}],"commits_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2Fgeo-tide-backend/commits","host":{"name":"GitHub","url":"https://github.com","kind":"github","last_synced_at":"2026-04-07T00:00:11.408Z","repositories_count":6211614,"commits_count":918017205,"contributors_count":35583097,"owners_count":1142749,"icon_url":"https://github.com/github.png","host_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://commits.ecosyste.ms/api/v1/hosts/GitHub/repositories"}},"issues_stats":{"full_name":"mcsc-impact-climate/geo-tide-backend","html_url":"https://github.com/mcsc-impact-climate/geo-tide-backend","last_synced_at":"2026-01-15T03:00:26.890Z","status":"error","issues_count":0,"pull_requests_count":21,"avg_time_to_close_issue":null,"avg_time_to_close_pull_request":247926.94736842104,"issues_closed_count":0,"pull_requests_closed_count":19,"pull_request_authors_count":4,"issue_authors_count":0,"avg_comments_per_issue":null,"avg_comments_per_pull_request":0.14285714285714285,"merged_pull_requests_count":19,"bot_issues_count":0,"bot_pull_requests_count":0,"past_year_issues_count":0,"past_year_pull_requests_count":10,"past_year_avg_time_to_close_issue":null,"past_year_avg_time_to_close_pull_request":9.875,"past_year_issues_closed_count":0,"past_year_pull_requests_closed_count":8,"past_year_pull_request_authors_count":1,"past_year_issue_authors_count":0,"past_year_avg_comments_per_issue":null,"past_year_avg_comments_per_pull_request":0.0,"past_year_bot_issues_count":0,"past_year_bot_pull_requests_count":0,"past_year_merged_pull_requests_count":8,"created_at":"2025-02-05T00:08:12.285Z","updated_at":"2026-01-15T03:00:26.890Z","repository_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2Fgeo-tide-backend","issues_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcsc-impact-climate%2Fgeo-tide-backend/issues","issue_labels_count":{},"pull_request_labels_count":{},"issue_author_associations_count":{},"pull_request_author_associations_count":{"CONTRIBUTOR":15,"COLLABORATOR":2},"issue_authors":{},"pull_request_authors":{"danikam":12,"cubicalknight":3,"brookebao":1,"helena380":1},"host":{"name":"GitHub","url":"https://github.com","kind":"github","last_synced_at":"2026-04-07T00:00:09.463Z","repositories_count":14129116,"issues_count":34525208,"pull_requests_count":112761526,"authors_count":11229026,"icon_url":"https://github.com/github.png","host_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/repositories","owners_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/owners","authors_url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors"},"past_year_issue_labels_count":{},"past_year_pull_request_labels_count":{},"past_year_issue_author_associations_count":{},"past_year_pull_request_author_associations_count":{"CONTRIBUTOR":2},"past_year_issue_authors":{},"past_year_pull_request_authors":{"danikam":2},"maintainers":[{"login":"brookebao","count":1,"url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors/brookebao"},{"login":"helena380","count":1,"url":"https://issues.ecosyste.ms/api/v1/hosts/GitHub/authors/helena380"}],"active_maintainers":[]},"events":{"total":{"ReleaseEvent":1,"DeleteEvent":4,"PullRequestEvent":5,"PushEvent":7,"CreateEvent":4},"last_year":{"PullRequestEvent":2,"PushEvent":1,"CreateEvent":1}},"keywords":["biofuels","decarbonization","decision-support","electrification","geospatial","hydrogen","trucking"],"dependencies":[{"ecosystem":"pypi","filepath":"requirements.txt","sha":null,"kind":"manifest","created_at":"2024-03-06T02:50:30.895Z","updated_at":"2024-03-06T02:50:30.895Z","repository_link":"https://github.com/mcsc-impact-climate/Geo-TIDE-backend/blob/main/requirements.txt","dependencies":[{"id":16632050056,"package_name":"pandas","ecosystem":"pypi","requirements":"==1.5.3","direct":true,"kind":"runtime","optional":false},{"id":16632050057,"package_name":"geopandas","ecosystem":"pypi","requirements":"==0.12.2","direct":true,"kind":"runtime","optional":false},{"id":16632050058,"package_name":"geopy","ecosystem":"pypi","requirements":"==2.3.0","direct":true,"kind":"runtime","optional":false},{"id":16632050059,"package_name":"tqdm","ecosystem":"pypi","requirements":"==4.64.1","direct":true,"kind":"runtime","optional":false},{"id":16632050060,"package_name":"openpyxl","ecosystem":"pypi","requirements":"==3.0.10","direct":true,"kind":"runtime","optional":false},{"id":16632050061,"package_name":"seaborn","ecosystem":"pypi","requirements":"==0.12.2","direct":true,"kind":"runtime","optional":false},{"id":16632050062,"package_name":"flask","ecosystem":"pypi","requirements":"==2.3.3","direct":true,"kind":"runtime","optional":false},{"id":16632050063,"package_name":"flask-cors","ecosystem":"pypi","requirements":"==4.0.0","direct":true,"kind":"runtime","optional":false},{"id":16632050064,"package_name":"scipy","ecosystem":"pypi","requirements":"==1.11.2","direct":true,"kind":"runtime","optional":false}]}],"score":4.624972813284272,"created_at":"2025-02-05T00:08:03.731Z","updated_at":"2026-04-12T21:30:21.751Z","avatar_url":"https://github.com/mcsc-impact-climate.png","language":"Python","category":"Consumption","sub_category":"Mobility and Transportation","monthly_downloads":0,"total_dependent_repos":0,"total_dependent_packages":0,"readme":"[![DOI](https://zenodo.org/badge/749951605.svg)](https://zenodo.org/doi/10.5281/zenodo.13205855)\n\n# Backend to produce layers for the Geo-TIDE tool\n\nThis repo contains code to produce and synthesize visualize publicly available geospatial data to support trucking fleets in navigating the transition to alternative energy carriers. The tool uses data from the \"freight analysis framework\" (FAF5) database and other public data sources.\n\nThe layers can be interactively visualized using the Geo-TIDE tool ([link to the Geo-TIDE code repo](https://github.com/mcsc-impact-climate/Geo-TIDE)).\n\n## Pre-requisites\n* python3\n\n## Setup\n\n```bash\ngit clone git@github.com:mcsc-impact-climate/FAF5-Analysis.git\n```\n\nInstall python requirements\n```bash\npip install -r requirements.txt\n```\n\n## Downloading the data\n\nThe script [`download_data.sh`](./download_data.sh) downloads all the data needed to run this code into the `data` directory. Note that it will only download a file if it doesn't already exist in the `data` directory. To run:\n\n```bash\nbash download_data.sh\n```\n\n## Processing highway assignments\n\nThe script [ProcessFAFHighwayData.py](./source/ProcessFAFHighwayData.py) reads in both the FAF5 network links for the entire US and the associated highway network assignments for total trucking flows, and joins the total flows for 2022 (all commodities combined) with the FAF5 network links via their common link IDs to produce a combined shapefile.\n\nTo run:\n\n```bash\npython processFAFHighwayData.py \n```\n\nThis should produce a shapefile in `data/highway_assignment_links`.\n\n## Processing eGRID emission intensity data\n\nThe script [ProcessGridData.py](./source/ProcessGridData.py) reads in the shapefile containing the borders of subregions within which eGRIDs reports grid emissions data, along with the associated eGRIDs data, and joins the shapefile with the eGRIDs data via the subregion ID to produce a combined shapefile.\n\nTo run:\n\n```bash\npython source/ProcessGridData.py \n```\n\nThis should produce shapefiles in `data/egrid2020_subregions_merged` and `data/eia2020_subregions_merged`.\n\n## Processing electricity prices and demand charges\n\nThe script [ProcessPrices.py](./source/ProcessPrices.py) reads in the shapefile containing borders of zip codes and states, along with the associated electricity price data and demand charges, and joins the shapefiles with the electricity price data via the subregion ID to produce combined shapefiles. It also evaluates electricity price, demand charge and diesel price by state. \n\nTo run:\n\n```bash\npython source/ProcessPrices.py \n```\n\n## Processing State-level Incentives and Regulations\n\nThe script [ProcessStateSupport.py](./source/ProcessStateSupport.py) reads in the shapefile containing borders of US states, along with CSV files containing state-level incentives relevant to trucking from the [AFDC website](https://afdc.energy.gov/laws/state), and joins the CSV files with the shapefile to produce a set of shapefiles with the number of incentives of each type (fuel, vehicle purchase, emissions and infrastructure) and fuel target (electrification, hydrogen, ethanol, etc.) for each state. \n\nTo run:\n\n```bash\npython source/ProcessStateSupport.py\n```\n\n## Processing planned infrastructure corridors for heavy duty vehicles\n\nThe script [PrepareInfrastructureCorridors.py](./source/PrepareInfrastructureCorridors.py) reads in either a shapefile with the US highway system, or shapefiles with specific regions of planned heavy duty vehicle infrastructure corridors [announced by the Biden-Harris administration](https://www.energy.gov/articles/biden-harris-administration-announces-funding-zero-emission-medium-and-heavy-duty-vehicle). For corridors represented as subsets of the national highway system, the code produces shapefiles for each highway segment with a planned infrastructure project. For corridors represented as regions of the US, the code produces shapefiles showing the region(s) where the planned infrastructure project will take place. \n\nTo run:\n\n```bash\npython source/PrepareInfrastructureCorridors.py\n```\n\nThis should produce shapefiles for zipcode-level and state-level electricity prices in `data/electricity_rates_merged`\n\n## Analyzing VIUS data\n\nThe script [AnalyzeVius.py](./source/AnalyzeVius.py) produces distributions of GREET vehicle class, fuel type, age, and payload from the VIUS data. To run:\n\n```bash\npython source/AnalyzeVius.py\n```\n\n## Processing VIUS data to evaluate average product of fuel efficiency and payload\n\nRun the script [ViusTools.py](./source/ViusTools.py) to produce an output file tabulating the product of fuel efficiency (mpg) times payload for each commodity, along with the associated standard deviation:\n\n```bash\npython source/ViusTools.py\n```\n\nThis should produce the following output file: `data/VIUS_Results/mpg_times_payload.csv`. \n\n## Producing shapefiles to visualize freight flows and emission intensities\n\nThe script [Point2PointFAF.py](./source/Point2PointFAF.py) combines outputs from VIUS, GREET and FAF5 and merges it with geospatial shapefiles with the contours of FAF5 regions to associate each region with tons, ton-miles, and associated emissions of imports to and exports from each region, along with areal densities of these three quantities (i.e. divided by the surface area of the associated region). There is also functionality to evaluate these quantities for a user-specified mode, commodity, origin region, or destination region. \n\nBefore running this code, you'll need to have first run the following:\n\n```bash\npython source/ViusTools.py\n```\n\nTo run:\n\n```bash\npython source/Point2PointFAF.py -m user_specified_mode -c \"user_specified_commodity\" -o user_specified_origin_ID -d user_specified_destination_ID\n```\n\nThis should produce a csv and shapefile in `data/Point2Point_outputs/mode_truck_commodity_Logs_origin_11_dest_all.[extension]`. \n\nNOTE: The \"\" around the commodity option is important because some commodities contain spaces, and python does NOT like command line arguments with spaces...\n\nwhere each argument defaults to 'all' if left unspecified. The mode is one of {all, truck, water, rail}. The available commodities can be found in the 'Commodity (SCTG2)' sheet in `data/FAF5_regional_flows_origin_destination/FAF5_metadata.xlsx` ('Description' column). The origin and destination region IDs can be found in the 'FAF Zone (Domestic)' sheet of the same excel file ('Numeric Label' column'). \n\nFor example, to filter for logs carried by trucks from FAF5 region 11 to FAF5 region 139:\n\n```bash\npython source/Point2PointFAF.py -m truck -c Logs -o 11 -d 139\n```\n\nThere's also a bash script in `source/run_all_Point2Point.sh` that can be executed to produce merged shapefiles for all combinations of modes, commodities, origins and destinations. \n\nTo run:\n\n```bash\nbash source/run_all_Point2Point.sh\n```\n\nWARNING: This may take several hours to run in full, and the shapefiles and csv files produced will take up ~100 GB. To reduce this, you can comment out items that you don't want in the COMMODITIES, REGIONS and MODES variables.\n\n## Creating shapefiles for hydrogen production facilities\n\nThe script [PrepareHydrogenHubs.py](./source/PrepareHydrogenHubs.py) combines locations and information about operating and planned hydrogen production facilities and the U.S. and Canada into shapefiles located in `data/hydrogen_hubs/shapefiles`. To run:\n\n```bash\npython source/PrepareHydrogenHubs.py\n```\n\n## Identifying truck stops and hydrogen production facilities within a given radius\n\nThe script [IdentifyFacilitiesInRadius.py](./source/IdentifyFacilitiesInRadius.py) identifies truck stops and hydrogen production facilities within a user-provided radius and central location - (33N, 97W) and 600 miles by default.\n\n## Analyze potential infrastructure investment savings from collective investment in truck stop charging\n\nThe script [AnalyzeTruckStopCharging.py](./source/AnalyzeTruckStopCharging.py) is designed to quantify the charging demand at truck stops along U.S. interstates that are sparsified to support the specified truck range, and estimate the potential difference in infrastructure costs needed if the entire electrified trucking fleet were to electrify and either:\n* The full electrified fleet shared the investment and usage of charging infrastructure, or\n* The fleet was divided in half, and each half invested in and used their respective charging infrastructure separately. \n\nThe idea of this exercise is to understand the potential infrastructure savings from trucking fleets pooling infrastructure investments in charging infrastructure based on real-world freight flow data. \n\nThe methodology is detailed in [MacDonell and Borrero, 2024](https://dspace.mit.edu/handle/1721.1/153617).\n\nTo run with a specified set of options:\n\n```bash\npython source/AnalyzeTruckStopCharging.py -c [charging time (hours)] -m [max allowable wait time (hours)] -r [truck range (miles)]\n```\n\nTo run over all options visualized in the geospatial mapping tool:\n\n```bash\nbash source/run_all_AnalyzeTruckStopCharging.sh\n```\n\n## Evaluating state-level electricity demand if trucking is fully electrified\n\nThe script [EvaluateTruckingEnergyDemand.py](./source/EvaluateTruckingEnergyDemand.py) aggregates highway-level FAF5 commodity flows and trips to evaluate the approximate annual energy demand (in MWh) that would be placed on the grid for each state if all trucking operations were to be fully electrified. The energy demand is calculated assuming that the flows are carried by the Tesla Semi, using the mileage with respect to payload calibrated using code in [this repo](https://github.com/mcsc-impact-climate/Green_Trucking_Analysis) ([link to relevant section of README](https://github.com/mcsc-impact-climate/Green_Trucking_Analysis?tab=readme-ov-file#evaluate-straight-line-approximation-of-fuel-economy-as-a-function-of-payload)). The underlying calibration is performed in [this repo](https://github.com/mcsc-impact-climate/PepsiCo_NACFE_Analysis) using data from the PepsiCo Tesla Semi pilot. \n\nTo run:\n\n```bash\npython source/EvaluateTruckingEnergyDemand.py\n```\n\nThis produces an output shapefile in `data/trucking_energy_demand` containing the energy demand for each state from electrified trucking, both as an absolute value (in MWh), and as a percent of each of the following:\n* The total energy generated in the state in 2022\n* The theoretical total energy generation capacity for the state in 2022 (if the grid were to run at its full summer generating capacity 24/7)\n* The theoretical excess energy generation capacity (i.e. theoretical - actual energy generated in 2022)\n\n## Comparing electricity demand for full trucking electrification with historical load in Texas ERCOT weather zones\n\n### Visualizing demand for each charging site\n\nThe script [`TT_charging_analysis.py`](./source/TT_charging_analysis.py) produces a plot visualizing the demands associated with electrifying trucking with charging at 8 sites in the Texas triangle region. To run:\n\n```bash\npython source/TT_charging_analysis.py\n```\nThis will produce `Texas_charger_locations.png` in the `plots` directory that compares the \n\n### Producing daily electricity demand curves for each charging site\n\nThe script [`MakeChargingLoadByZone.py`](source/MakeChargingLoadByZone.py) produces a csv file for each ERCOT weather zone containing one or more charging sites. For each such zone, the csv file contains the daily load from each charging site in the weather zone, assuming it follows the most extreme variation found in Borlaug et al (2021) for immediate charging (see red curve in Fig. 5 in the paper). \n\nTo run:\n```bash\npython source/MakeChargingLoadByZone.py\n```\n\nThis will produce a csv file `daily_ev_load_[zone].csv` for each zone.\n\n### Comparing daily EV demand with historical load for each month\n\nThe script [`AnalyzeErcotData.py`](source/AnalyzeErcotData.py) compares the daily EV demand each charging site in a zone (along with the total combined demand) with the estimated excess capacity of the grid over the day. \n\nTo run:\n\n```bash\npython source/AnalyzeErcotData.py\n```\n\nThis will produce a plot for each zone and month called `daily_ev_load_with_excess_[zone]_[month].png` in the `plots` directory.\n\n\n\n\n","funding_links":[],"readme_doi_urls":[],"works":{},"citation_counts":{},"total_citations":0,"keywords_from_contributors":[],"project_url":"https://ost.ecosyste.ms/api/v1/projects/309287","html_url":"https://ost.ecosyste.ms/projects/309287"}