How emit-sds/emit-sds-tgp works
Purpose and operational entry point
This repository controls an EMIT trace-gas plume workflow: ingesting manual or ML delineations, enriching and filtering them, quantifying emissions, and preparing products for delivery. The operational orchestrator is src/scrape_refine_upload.py, invoked with an authentication token, source layer, output directory, product version, database configuration, and track-coverage file.
Workflow orchestration and source boundary
src/scrape_refine_upload.py is the primary control-plane boundary between external delineation sources and downstream processing. It coordinates scraping, refinement, upload/delivery-oriented output handling, and operational inputs such as credentials, a database configuration file, and coverage metadata. The layer argument indicates that delineations are selected from an external layer/source rather than created by this repository.
Paths:
• src/scrape_refine_upload.py
• src/annotate/plume_io.py
Annotation ingestion, metadata, and filtering
The annotation package normalizes plume/delineation data, attaches workflow metadata, and applies acceptance or rejection criteria before quantification or publication. This is the interface intended for both manual and ML-based plume boundaries. Plume I/O separates source/product representations from processing logic, while filtering establishes a quality-control boundary.
Paths:
• src/annotate/plume_io.py
• src/annotate/filter.py
• src/annotate/utils.py
Quantification engine
Quantification is a separable scientific subsystem that converts accepted plume geometry and supporting measurements into emission-rate estimates and uncertainties. The implementation includes a simple Integrated Mass Enhancement (IME) approach, wind-speed handling, flux computation, and uncertainty utilities. It can run independently of the full operational scrape/refine/delivery path.
Paths:
• src/quantification/simple_ime.py
• src/quantification/compute_Q_and_Qunc_simple_IME.py
• src/quantification/compute_flux.py
Wind and uncertainty dependencies
Emission estimates depend on wind-speed inputs and uncertainty propagation; these are explicit stages rather than incidental calculations. Wind handling feeds flux/IME calculations, while shared uncertainty utilities support reported Q and Qunc outputs. This is the principal scientific boundary between delineated plume observations and quantified trace-gas products.
Paths:
• src/quantification/windspeed.py
• src/quantification/compute_Q_and_uncertainty_utils.py
• src/quantification/compute_Q_and_Qunc_simple_IME.py
Product discovery and delivery
Delivery logic discovers Cloud Optimized GeoTIFF (COG) products eligible for release and submits/packages them for the DAAC-facing delivery process. This forms the final boundary between internally generated/refined outputs and external distribution infrastructure.
Paths:
• src/delivery/find_cogs_to_deliver.py
• src/delivery/daac_delivery.py
Documentation and operational contract
The algorithm and user-facing behavior are specified in the trace-gas ATBD and User Guide; quantification-specific usage is documented alongside the quantification code. These documents define the scientific and product contract that the pipeline implements.
Paths:
• docs/EMIT_L2B_TRACE_GAS_ATBD.md
• docs/EMIT_L2B_TRACE_GAS_User_Guide.md
• src/quantification/quantification_readme.md
Main entry points: compute_Q_and_Qunc_simple_IME.py Q and Qunc estimates · scrape_refine_upload.py Scrape, refine, upload · simple_ime.py Simple IME · compute_flux.py Flux computation
Components 16
Operations
- Operational inputs · Token, database configuration, output directory, version, and track coverage.
- Scrape, refine, upload · Operational entry point for the end-to-end plume workflow.
src/scrape_refine_upload.py
Annotation QC
- Plume I/O · Normalizes source and product plume representations.
src/annotate/plume_io.py - Annotation metadata · Attaches processing metadata to plume records.
src/annotate/utils.py - Plume quality filter · Accepts or rejects delineations before downstream use.
src/annotate/filter.py
Quantification
- Wind-speed handling · Supplies wind information for emission estimates.
src/quantification/windspeed.py - Simple IME · Computes integrated mass enhancement quantities.
src/quantification/simple_ime.py - Flux computation · Converts plume and wind inputs into flux terms.
src/quantification/compute_flux.py - Uncertainty utilities · Provides shared uncertainty propagation.
src/quantification/compute_Q_and_uncertainty_utils.py - Q and Qunc estimates · Produces emission-rate estimates and uncertainties.
src/quantification/compute_Q_and_Qunc_simple_IME.py
Delivery
- COG release discovery · Finds Cloud Optimized GeoTIFF products eligible for release.
src/delivery/find_cogs_to_deliver.py - DAAC delivery · Packages and submits products to external delivery infrastructure.
src/delivery/daac_delivery.py
Scientific contract
- Trace-gas ATBD · Defines the scientific algorithm contract.
docs/EMIT_L2B_TRACE_GAS_ATBD.md - Trace-gas User Guide · Defines user-facing product behavior.
docs/EMIT_L2B_TRACE_GAS_User_Guide.md - Quantification guide · Documents quantification-specific operation.
src/quantification/quantification_readme.md
Other components
- External delineation layers · Manual and ML plume boundaries selected by layer.
Connections 18
- External delineation layers → Scrape, refine, upload: selected layer
- Operational inputs → Scrape, refine, upload: runtime parameters
- Scrape, refine, upload → Plume I/O: ingests delineations
- Plume I/O → Annotation metadata: normalized plumes
- Annotation metadata → Plume quality filter: annotated plumes
- Plume quality filter → Simple IME: accepted plumes
- Wind-speed handling → Simple IME: wind input
- Simple IME → Flux computation: IME quantities
- Wind-speed handling → Flux computation: wind speed
- Flux computation → Q and Qunc estimates: flux estimate
- Uncertainty utilities → Q and Qunc estimates: propagation
- Simple IME → Q and Qunc estimates: plume quantities
- Scrape, refine, upload → COG release discovery: prepares release outputs
- Q and Qunc estimates → COG release discovery: quantified products
- COG release discovery → DAAC delivery: eligible COGs
- Trace-gas ATBD → Q and Qunc estimates: specifies algorithm
- Trace-gas User Guide → Scrape, refine, upload: defines behavior
- Quantification guide → Q and Qunc estimates: documents usage