Automating the configuration of networking devices with Python
Automating the Analysis of GHGRP Data Using Python, to ...
Transcript of Automating the Analysis of GHGRP Data Using Python, to ...
Automating the Analysis of GHGRP Data Using Python, to Perform
Temporal Analysis on Natural Gas Supply Chain Parameters
Srijana Rai1, Selina Roman-White1, George G. Zaimes1, James Littlefield1, Gregory Cooney1, and Timothy J. Skone P.E.2
September 24, 20191Contractor to the National Energy Technology Laboratory, Pittsburgh, Pennsylvania2National Energy Technology Laboratory, Pittsburgh, Pennsylvania
2
DISCLAIMER
"This report was prepared as an account of work sponsored by an agency of the United States Government. Neither the United States Government nor any agency thereof, nor any of their employees, makes any warranty, express or implied, or assumes any legal liability or responsibility for the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately owned rights. Reference herein to any specific commercial product, process, or service by trade name, trademark, manufacturer, or otherwise does not necessarily constitute or imply its endorsement, recommendation, or favoring by the United States Government or any agency thereof. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government or any agency thereof."
Attribution
KeyLogic Systems, Inc.’s contributions to this work were funded by the National Energy Technology Laboratory under the Mission Execution and Strategic Analysis contract (DE-FE0025912) for support services.
Disclaimer and Attribution
3
This work analyzes subpart W of the Greenhouse Gas Reporting Program (GHGRP) data using Python
Introduction
GHGRP Subpart W
• Facility level greenhouse gas data for petroleum and gas systems
• Represents all the facilities that emit 25,000 metric tons or more of GHGs per year
• Highly granular database
Python Script
• Analyzes all the parameters• Uses bootstrapping as a statistical
technique• Calculates mean values with 95%
confidence interval • Performs the analysis for different
stages of the natural gas supply chain
4
• Bootstrapping is a statistical technique of random sampling with replacement
• The bootstrapping algorithm here samples according to the relative throughputs of the facilities within a scenario (i.e. facilities with greater throughput are more likely to be selected)
• For each iteration, the sample size is equal to the number of facilities in that scenario
• Current work performs 1000 iterations and calculates the 2.5th percentile, mean, and 97.5th percentile for each parameter
Bootstrapping Method
5
• Production• Technobasins
• Gathering and Boosting• Basins
• Processing
• Transmission
• Storage
• Pipeline
• Distribution
Modelling Scenarios
6
Code Structure
Acid Gas Removal
Pneumatic Devices
Blowdown Stacks
Transmission Tanks
Dataframe with relevant Parameters
Master Dataframe
Production-Shale
Facility OverviewProduction-Conventional
Production-Tight
Production-CBM
Gathering & Boosting
Processing
Transmission
Storage
Pipeline
Distribution
Production Parameters (For each Basin &
Extraction Technology)
G&B Parameters(For each Basin)
Processing Parameters
Transmission Parameters
Storage Parameters
Pipeline Parameters
Distribution Parameters
Flare Stacks
Pivot & Merge
Filter
Filter Bootstrap
Input .csv Files from Envirofacts, GHGRP (27 files)
Master Files with all Reported Records
Segregation of Scenarios
Parameter Outputs(P2.5, Average, and
P97.5 values)
7
• GHGRP data doesn’t have a consistent naming convention
• GHGRP data is in long data format and needs significant cleaning and manipulation
• This script will only be applicable as long as GHGRP reports its subpart W in the same format
• GHGRP started using this format in 2016, so any temporal analysis using this script will only be able to go back to 2016
Challenges & Limitations
8
• Total methane emissions from equipment leaks and calculated emission intensity per unit of gas produced were plotted on a map at a basin level for 2016 and 2017
• Both emissions and emission intensities were plotted to allow a more effective comparison between basins from a life cycle perspective
• This case study helped in tracking which basins had the highest reductions in emissions from equipment leaks, indicating if the change was due to a reduction in the emission intensity or reduced production from that basin
Case Study: Production Stage Equipment Leaks
9
Case Study: Results
Total Equipment Methane leak
Equipment Methane leak intensity per unit gas produced
10
• Comparison between total leaks and leak intensity per unit gas produced within a reporting year shows that a basin may have higher total emissions but very low emission intensity depending on its total production in the given year or vice-versa.
• Examples:• Central Western Overthrust has a mid-level total emission footprint, but a high-level
emission intensity• Arkoma Basin has one of the highest total emissions, but a mid-level emission
intensity• Palo Duro Basin has one of the lowest total emissions but a much higher emission
intensity
Case Study: Conclusions Comparisons within a reporting year
11
• Across different reporting years, a basin may reduce its total emissions while maintaining a similar emission intensity due to changes in production
• Examples:• Many basins, including Permian Basin, Appalachian Basin (Eastern Overthrust Area),
and Mid-Gulf Coast Basin, had a visible reduction in their total emissions from 2016 to 2017, with neglegible change in emission intensity
• Palo Duro Basin maintained low-level total emissions, but had a large increase in emission intensity from 2016 to 2017
Case Study: ConclusionsComparisons across different reporting years
12
• Scripting to scrape data directly from GHGRP
• Tools to automatically handle changes in GHGRP formatting
• Automatic key figure generation
• Creation of an interactive user dashboard
Future Work
13
Contact Information
Timothy J. Skone, P.E.Senior Environmental Engineer • U.S. DOE, NETL(412) 386-4495 • [email protected]
netl.doe.gov/LCA [email protected] @NETL_News
Srijana RaiEngineer• KeyLogic(412) 386-5508 • [email protected]
James LittlefieldPrincipal Engineer • KeyLogic(412) 386-7560 • [email protected]