Skip to content

Add Safeguard Mechanism facilities to oil & gas sector #152

Closed
aethr wants to merge 24 commits into
mainfrom
150/oil-gas-locations
Closed

Add Safeguard Mechanism facilities to oil & gas sector #152
aethr wants to merge 24 commits into
mainfrom
150/oil-gas-locations

Conversation

@aethr

@aethr aethr commented Nov 27, 2025

Copy link
Copy Markdown
Contributor

Description

Similar to #144, this adds a proof of concept for allocating Safeguard Mechanism facility emissions for facilities in the "Oil and gas extraction (070)" sector to the oil_gas prior sector.

This is more complicated than the coal implementation due to a number of factors:

  • An oil and gas "facility" in the SGM sometimes refers to multiple discrete locations
  • Some of these locations are large oil or gas fields which can span multiple grid cells
  • There is no single data source with locations for all Safeguard facilities

Currently, this implements a single new data source which gives the shapes of oil and gas fields in Victoria, Australia, and allocates the SGM facility emissions to them continuously across the entire area.

Allocation of facility emissions

Even if it was clear exactly which fields and facilities were counted under a single Safeguard facility, the single annual emission figure must be allocated among them, which is a complex problem. How much do fields emit vs facilities? How much is lost in transport? Do pipelines leak at the start and end, or across their length? Answers to these questions may differ from facility to facility.

Checklist

Please confirm that this pull request has done the following:

  • Tests added
  • Documentation added (where applicable)
  • Changelog item added to changelog/

Notes

@aethr aethr self-assigned this Nov 27, 2025
@aethr aethr changed the base branch from main to input-cache November 27, 2025 06:52
@aethr aethr force-pushed the 150/oil-gas-locations branch from 6c6b7d5 to 654e305 Compare November 28, 2025 05:08
@aethr aethr force-pushed the input-cache branch 2 times, most recently from 0bd08b9 to 3d45c3c Compare December 1, 2025 00:10
@aethr aethr force-pushed the 150/oil-gas-locations branch from 654e305 to 6e5fc5c Compare December 1, 2025 00:11
@aethr aethr force-pushed the 150/oil-gas-locations branch from 6e5fc5c to efb7a24 Compare December 2, 2025 22:23
Base automatically changed from input-cache to main December 10, 2025 05:15
@aethr aethr force-pushed the 150/oil-gas-locations branch 2 times, most recently from 947d45e to cff455e Compare December 10, 2025 05:57
@aethr aethr force-pushed the 150/oil-gas-locations branch 3 times, most recently from 48fdcfa to 557d4c6 Compare January 22, 2026 02:45
@aethr aethr force-pushed the 150/oil-gas-locations branch from 557d4c6 to 7f194b0 Compare February 17, 2026 23:26
aethr added 10 commits February 24, 2026 15:22
This reads the asset file using geopandas, and returns a GeoDataFrame, which is a pandas DataFrame that supports vector geometry fields.
This DataSource fetches oil and gas field shapes from the Victorian Open Data geoserver and saves them as GeoJSON. The data is then parsed as a GeoDataFrame using geopandas.
…hapes

The allocate_safeguard_facility_emissions method in the oil_gas sector module is similar to the implementation in the coal module, except it works on a data source which provides geometry shapes for locations instead of lat/lon points.

In this naive implementation the emissions from a single facility are spread out equally over the area covered by its locations. Two grid cells fully covered by a facility location would be attributed equal emissions, while grid cells with only partial coverage would get a smaller share of the facility's reported total.
The test is meant to ensure there aren't any empty rows, and the shape of a single row, which it now does.
Currently, only facilities in Victoria are included, as this is the only location dataset that's been introduced.
For the output, we only need to allocate SGM facilities to the domain grid. However, we also need to remove SGM facilities from supplementary data sources so that these facilities aren't double-counted. The simplest way to do that is to remove any facilities which fall within a grid cell that already has emissions from the SGM, but we must do this across the entire inventory domain even when the domain of interest is a subdomain.
The oil and gas sector implementation is likely to use a number of data sources, this will help keep them a bit better organised than all existing in a single file.
@aethr aethr force-pushed the 150/oil-gas-locations branch from 7f194b0 to 0a541ce Compare February 24, 2026 04:22
aethr added 2 commits March 10, 2026 17:08
When multiple GeoDataFrame objects are used in a layer and often combined, they must share a common CRS. The CRS of the domain projection may not be known at the time that parse_geo is run, so for now just normalise to a standard WGS84 projection.
@aethr aethr force-pushed the 150/oil-gas-locations branch 2 times, most recently from 9e29a86 to c488842 Compare March 15, 2026 21:56
aethr added 12 commits March 19, 2026 16:09
This sector implementation is complex enough to warrant its own documentation where we can explain methodology, data sources, and decisions.
Since emission sources for this sector will come from many different datasets, this defines a common structure of data as an interchange format.
NOPTA is the National Offshore Petroleum Title Administrator who manages Australian offshore resource titles. Using their titles and wells datasets we can identify likely offshore locations where oil and gas are being extracted within a prior period.
Combine NSW drillholes dataset with petroleum leases dataset to extract producing wells with an activity period matching the period of interest.
Combine WA petroleum wells dataset with petroleum titles dataset to extract producing wells with an activity period matching the title period.
Combine QLD boreholes dataset with petroleum leases dataset to extract producing wells with an activity period matching the lease period.
The NOPTA dataset has significant overlap with WA and VIC datasets, with many wells occurring in both. In the case of VIC fields dataset, the NOPTA dataset has more detail and includes all the same sources, so the simplest solution is not to use the VIC data.

In the case of WA, the WA dataset does include some wells that are not found in NOPTA, so we want to combine both datasets but remove any duplicates. The two datasets store coords with slightly different precision, so we allow for a small amount of distance between "duplicate" points.
@aethr

aethr commented Apr 16, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by #170 .

@aethr aethr closed this Apr 16, 2026
@aethr aethr deleted the 150/oil-gas-locations branch May 25, 2026 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant