THE MACHINE · IN THE OPEN · FROM THE WITNESSED RUN OF 2026-10-09
carbon.py, every command showing its working.
A small Python program, standard library only. Your AI runs it; you can too. Every block below is pasted from the card’s own WITNESS.md, as printed.
factors | the built-in factors, each with source, year and scope |
|---|
electricity | emissions from grid power (US eGRID2023 by state or subregion, UK 2026 or 2025 government factors) |
|---|
fuel | fuel burned (US EPA GHG Emission Factors Hub 2025) |
|---|
flight | great-circle distance, haul band, class factors from the UK 2026 factors, with and without the RF uplift |
|---|
vehicle | the three diesel vans |
|---|
footprint | an annual footprint by scope, with a Markdown summary |
|---|
green-premium | the extra cost per tonne avoided, in your own currency |
|---|
offsets | the five questions to ask of any offset |
|---|
selftest | 31 checks that prove the machine; it must print 31/31 |
|---|
factors · THE BUILT-IN FACTORS, EACH WITH SOURCE, YEAR AND SCOPE
$ carbon.py factors --kind flight
FLIGHT · scope 3, category 6 · kg CO2e per passenger-km, with RF / without RF · UK DESNZ, Greenhouse gas reporting: conversion factors 2026 (published 2026-06-11), business travel - air, kg CO2e per passenger-km, with and without the radiative-forcing uplift
domestic average 0.22928 / 0.13552
short average 0.12786 / 0.07559
short economy 0.12576 / 0.07435
short business 0.18863 / 0.11152
long average 0.15282 / 0.09043
long economy 0.11704 / 0.06926
long premium 0.18726 / 0.11081
long business 0.33940 / 0.20083
long first 0.46814 / 0.27701
international average 0.14253 / 0.08420
GWPs: IPCC AR5 100-year, CH4 28 and N2O 265, as eGRID2023 and the EPA Hub 2025 use.
Read and checked on 2026-10-09. A newer edition replaces each of these; every command takes --factor to override.
electricity · EMISSIONS FROM GRID POWER (US EGRID2023 BY STATE OR SUBREGION, UK 2026 OR 2025 GOVERNMEN
$ carbon.py electricity --kwh 12000 --region us-co
electricity · 12,000 kWh · Colorado (eGRID2023 state rate)
factor: 1,091.1 lb CO2e/MWh = 0.49491 kg CO2e/kWh (CO2 alone 1,085.0 lb/MWh)
emissions: 5,939 kg CO2e = 5.94 t CO2e (CO2 alone 5,906 kg)
scope: 2, location-based (the grid average). A market-based figure needs your supplier's own factor: --factor KG_PER_KWH --source "...".
note: EPA recommends the eGRID subregion rate for scope 2. Find your subregion by ZIP code in EPA's Power Profiler, then use --region us-<subregion> (e.g. us-rmpa).
formula: kg CO2e = kWh × lb CO2e per MWh × 0.45359237 ÷ 1,000
source: US EPA eGRID2023 (data year 2023), revision 2 released 2025-06-12, summary tables: total output emission rates, lb/MWh; CO2e with IPCC AR5 GWPs (CH4 28, N2O 265), Table 3 State Output Emission Rates. Read 2026-10-09.
limit: the 2023 annual average of generation in that area, not the hour you used it; grid losses are left out (EPA's Hub: do not add them to scope 2); a newer eGRID edition replaces it.
electricity · EMISSIONS FROM GRID POWER (US EGRID2023 BY STATE OR SUBREGION, UK 2026 OR 2025 GOVERNMEN
$ carbon.py electricity --kwh 12000 --region us-rmpa
electricity · 12,000 kWh · RMPA, WECC Rockies (eGRID2023 subregion rate)
factor: 1,042.5 lb CO2e/MWh = 0.47287 kg CO2e/kWh (CO2 alone 1,036.6 lb/MWh)
emissions: 5,674 kg CO2e = 5.67 t CO2e (CO2 alone 5,642 kg)
scope: 2, location-based (the grid average). A market-based figure needs your supplier's own factor: --factor KG_PER_KWH --source "...".
formula: kg CO2e = kWh × lb CO2e per MWh × 0.45359237 ÷ 1,000
source: US EPA eGRID2023 (data year 2023), revision 2 released 2025-06-12, summary tables: total output emission rates, lb/MWh; CO2e with IPCC AR5 GWPs (CH4 28, N2O 265), Table 1 Subregion Output Emission Rates. Read 2026-10-09.
limit: the 2023 annual average of generation in that area, not the hour you used it; grid losses are left out (EPA's Hub: do not add them to scope 2); a newer eGRID edition replaces it.
fuel · FUEL BURNED (US EPA GHG EMISSION FACTORS HUB 2025)
$ carbon.py fuel --therms 1800 --fuel natural-gas
fuel · 1,800.0 therms of natural-gas = 180.000 mmBtu (1 therm = 0.1 mmBtu)
CO2: 9,550.8 kg
CH4: 180.0 g × 28 · N2O: 18.0 g × 265
emissions: 9,561 kg CO2e = 9.56 t CO2e
scope: 1 if it burned in something you own or control (a boiler, a generator, a company vehicle); a rented or staff car on business is scope 3, category 6.
formula: kg CO2e = quantity × kg CO2 per unit + g CH4 × 28 ÷ 1,000 + g N2O × 265 ÷ 1,000
source: US EPA GHG Emission Factors Hub 2025 (January 2025), Table 1 (natural gas, per mmBtu; 0.05444 kg CO2 per scf at 0.001026 mmBtu/scf). Read 2026-10-09.
limit: a US average carbon content for pipeline gas; therms and kWh on a bill are already heat, so only the volume units (scf, ccf, mcf) lean on the average heat content.
vehicle · THE THREE DIESEL VANS
$ carbon.py vehicle --miles 20000 --mpg 18 --fuel diesel --vehicles 3
vehicle · 3 × 20,000 miles · diesel light-duty trucks (vans, pickups, SUVs), model years 2007-2022 · 1,111.1 gallons a vehicle (3,333.3 in all)
CO2: 34,033 kg (10.21 kg CO2 per gallon)
CH4: 0.029 g/mile → 1.74 kg × 28 · N2O: 0.0214 g/mile → 1.28 kg × 265
emissions: 34,422 kg CO2e = 34.42 t CO2e (11.47 t a vehicle)
scope: 1 for vehicles the business owns or leases and controls; staff cars and rentals on business are scope 3, category 6.
formula: kg CO2e = gallons × kg CO2 per gallon + miles × (g CH4 × 28 + g N2O × 265) ÷ 1,000; gallons = miles ÷ mpg
source: US EPA GHG Emission Factors Hub 2025 (January 2025), Table 2 (CO2) and Tables 3-4 (CH4, N2O: diesel light-duty trucks (vans, pickups, SUVs), model years 2007-2022). Read 2026-10-09.
limit: your mpg is the biggest input: fuel bought ÷ miles driven is better than a brochure figure. CH4 and N2O use the newest model-year row; older vehicles emit a little more.
flight · GREAT-CIRCLE DISTANCE, HAUL BAND, CLASS FACTORS FROM THE UK 2026 FACTORS, WITH AND WITHO
$ carbon.py flight --from DEN --to LHR --class economy --return
flight · DEN (Denver) → LHR (London Heathrow), 7,497 km great circle · return · economy · 1 passenger
band: long-haul (over 3,700 km)
passenger-km: 14,994
without the RF uplift: 0.06926 kg CO2e/passenger-km → 1,039 kg CO2e = 1.04 t CO2e
with the RF uplift: 0.11704 kg CO2e/passenger-km → 1,755 kg CO2e = 1.75 t CO2e
RF: the radiative-forcing uplift stands for the extra warming of flying at altitude (contrails, nitrogen oxides, water vapour). DESNZ multiplies the CO2 part by 1.7; the size of these effects is uncertain. Report which figure you used.
scope: 3, category 6 (business travel).
formula: kg CO2e = one-way km × legs × passengers × kg CO2e per passenger-km; km by the haversine formula on a 6,371.0 km sphere
source: UK DESNZ, Greenhouse gas reporting: conversion factors 2026 (published 2026-06-11), business travel - air, kg CO2e per passenger-km, with and without the radiative-forcing uplift. The factors include DESNZ's 8 per cent uplift for indirect routes, so they apply to great-circle km. The 2026 workbook could not be opened here on 2026-10-09; the values were read from published copies of it that agree, and each with-RF value is 1.69 times its without-RF value, as the 1.7 multiplier on CO2 predicts.
limit: an average seat on an average aircraft; a real flight's load, aircraft and route differ. Airport coordinates are to two decimals (distance good to a few km).
flight · GREAT-CIRCLE DISTANCE, HAUL BAND, CLASS FACTORS FROM THE UK 2026 FACTORS, WITH AND WITHO
$ carbon.py flight --from LHR --to CDG --class first
error: DESNZ gives no first-class factor for short-haul flights; it gives: average, economy, business
electricity · EMISSIONS FROM GRID POWER (US EGRID2023 BY STATE OR SUBREGION, UK 2026 OR 2025 GOVERNMEN
$ carbon.py electricity --kwh 5000 --region br
error: no built-in factor for "br". Built in: us, us-<state> (e.g. us-co), us-<eGRID subregion> (e.g. us-rmpa), uk, uk-2025. Anywhere else, give --factor KG_PER_KWH --source "publisher, edition, year".
electricity · EMISSIONS FROM GRID POWER (US EGRID2023 BY STATE OR SUBREGION, UK 2026 OR 2025 GOVERNMEN
$ carbon.py electricity --kwh 5000 --factor 0.1 --source "FAKE supplier disclosure 2025"
electricity · 5,000 kWh · your factor
factor: 0.10000 kg CO2e/kWh
emissions: 500 kg CO2e = 0.50 t CO2e
scope: 2 — location-based if your factor is a grid average, market-based if it is your supplier's own; say which.
formula: kg CO2e = kWh × kg CO2e per kWh
source: given by you: FAKE supplier disclosure 2025
limit: only as good as the factor you gave; say whose it is and its year.
footprint · AN ANNUAL FOOTPRINT BY SCOPE, WITH A MARKDOWN SUMMARY
$ carbon.py footprint activities.csv --md summary.md
footprint · activities.csv · 5 activities
scope 2 electricity 12,000 kWh · us-co 5,939 kg CO2e (FAKE bakery: the shop meter)
scope 1 fuel 1,800.0 therms natural-gas 9,561 kg CO2e (FAKE bakery: ovens and heating)
scope 1 vehicle 3 × 20,000 miles diesel light-truck 34,422 kg CO2e (FAKE bakery: three delivery vans)
scope 3 flight DEN-LHR long economy × 1 return 1,039 kg CO2e (FAKE bakery: a trade fair in London)
scope 3 fuel 40.0 gallons gasoline 351 kg CO2e (FAKE bakery: a staff car on business)
SCOPE 1: 43.98 t CO2e
SCOPE 2: 5.94 t CO2e
SCOPE 3: 1.39 t CO2e
TOTAL: 51.31 t CO2e (flights without the RF uplift; with it, 52.03 t)
wrote summary.md
formula: t CO2e = Σ activity × factor ÷ 1,000, summed by scope; each row worked as its own command works it
source: per row: EPA eGRID2023 rev 2 or UK DESNZ 2026/2025 (electricity), EPA GHG Emission Factors Hub 2025 (fuel, vehicles), UK DESNZ 2026 (flights)
limit: covers scope 1, scope 2 (location-based) and scope 3 business flights; other scope 3 categories (purchases, freight, waste, commuting) are not counted.
vehicle · THE THREE DIESEL VANS
$ carbon.py vehicle --miles 20000 --kwh-per-mile 0.45 --region us-co --vehicles 3
vehicle · electric · 3 × 20,000 miles at 0.450 kWh/mile = 27,000 kWh · grid: Colorado (eGRID2023 state rate) (0.49491 kg CO2e/kWh)
emissions: 13,363 kg CO2e = 13.36 t CO2e
note: use kWh at the charger or the meter (charging losses included); a dashboard figure leaves them out.
scope: 2 if charged on your own meter, and then it is already inside your electricity bill: count it once, not twice. Charged elsewhere and paid for, scope 3.
formula: kg CO2e = miles × kWh per mile × vehicles × kg CO2e per kWh
source: US EPA eGRID2023 (data year 2023), revision 2 released 2025-06-12, summary tables: total output emission rates, lb/MWh; CO2e with IPCC AR5 GWPs (CH4 28, N2O 265), Table 3 State Output Emission Rates
limit: the grid factor is an annual average; when and where the van charges changes the real figure.
green-premium · THE EXTRA COST PER TONNE AVOIDED, IN YOUR OWN CURRENCY
$ carbon.py green-premium --clean-cost 150000 --fossil-cost 120000 --fossil-tonnes 34.42 --clean-tonnes 13.36
green premium · clean 150,000.00 vs fossil 120,000.00, in your currency, over the same period
premium: 150,000.00 − 120,000.00 = 30,000.00 (25.0% of the fossil cost)
tonnes: 34.42 t (fossil) − 13.36 t (clean) = 21.06 t avoided
cost per tonne avoided: 30,000.00 ÷ 21.06 = 1,424.50 per t CO2e
read it: each tonne avoided costs 1,424.50. Compare it with your other ways to cut a tonne, and with an offset's price only after the offset questions (offsets).
formula: premium = clean cost − fossil cost; per tonne = premium ÷ tonnes avoided (same period, same scope of costs: buy, run, maintain)
source: the green premium, the extra cost of the zero- or low-carbon way of doing a thing, as set out in the book "How to Avoid a Climate Disaster" (2021).
limit: the costs and tonnes are yours; both must cover the same years and the same things. A purchase spread over years needs its yearly share or a whole-life total on both sides.
green-premium · THE EXTRA COST PER TONNE AVOIDED, IN YOUR OWN CURRENCY
$ carbon.py green-premium --clean-cost 110000 --fossil-cost 120000 --fossil-tonnes 34.42 --clean-tonnes 13.36
green premium · clean 110,000.00 vs fossil 120,000.00, in your currency, over the same period
premium: 110,000.00 − 120,000.00 = -10,000.00 (-8.3% of the fossil cost)
tonnes: 34.42 t (fossil) − 13.36 t (clean) = 21.06 t avoided
cost per tonne avoided: -10,000.00 ÷ 21.06 = -474.83 per t CO2e
read it: a negative green premium. The cleaner choice costs less and cuts emissions; the question is cash up front, not cost.
formula: premium = clean cost − fossil cost; per tonne = premium ÷ tonnes avoided (same period, same scope of costs: buy, run, maintain)
source: the green premium, the extra cost of the zero- or low-carbon way of doing a thing, as set out in the book "How to Avoid a Climate Disaster" (2021).
limit: the costs and tonnes are yours; both must cover the same years and the same things. A purchase spread over years needs its yearly share or a whole-life total on both sides.
offsets · THE FIVE QUESTIONS TO ASK OF ANY OFFSET
$ carbon.py offsets
offsets · five questions to ask of any offset before you buy one or count one
1. ADDITIONALITY — Would the cut or the removal have happened anyway, without the money from the credit? If yes, the credit buys nothing.
2. PERMANENCE — How long is the carbon kept out of the air, and what happens if it comes back (a forest fire, a project that stops)? Is there a buffer or a replacement promise?
3. LEAKAGE — Did the project push the emissions somewhere else (logging moved to the next valley, production moved abroad)? Was that counted?
4. VERIFICATION — Did an independent third party validate the project and verify the tonnes, under a named standard and methodology? Can you read the report?
5. DOUBLE COUNTING — Is the same tonne claimed twice — by the seller, by a country's target, or by another buyer? Is it retired in a public registry in your name, with a serial number?
and: keep offsets out of your scope totals. Report the footprint first, cut what you can, and list any credits apart.
This card does not rate projects, pick credits or give trading or investment advice.
formula: none: these are questions, not a score
source: Integrity Council for the Voluntary Carbon Market, Core Carbon Principles (first published 2023): additionality, permanence, robust quantification, no double counting, independent validation and verification; GHG Protocol Corporate Standard: offsets are reported apart from the inventory.
limit: a credit can pass all five questions and still be a weaker step than cutting your own emissions.
electricity · EMISSIONS FROM GRID POWER (US EGRID2023 BY STATE OR SUBREGION, UK 2026 OR 2025 GOVERNMEN
$ carbon.py electricity --kwh 12000 --region uk
electricity · 12,000 kWh · United Kingdom grid, 2026 factors (data year 2025)
factor: 0.13096 kg CO2e/kWh
emissions: 1,572 kg CO2e = 1.57 t CO2e
grid losses (scope 3, category 3, reported apart): 12,000 kWh × 0.01299 = 156 kg CO2e
scope: 2, location-based (the grid average). A market-based figure needs your supplier's own factor: --factor KG_PER_KWH --source "...".
formula: kg CO2e = kWh × kg CO2e per kWh (generation); T&D losses = kWh × the T&D factor, reported in scope 3
source: UK DESNZ, Greenhouse gas reporting: conversion factors 2026 (published 2026-06-11), methodology report Table 9: electricity generated 0.13096, T&D losses 0.01299, consumed 0.14396 kg CO2e/kWh; data year 2025. Read 2026-10-09.
limit: an annual UK average, not the hour you used it; a newer DESNZ edition replaces it; use the edition for the year the power was used.
THE RUNS ARE PASTED FROM THE CARD’S OWN WITNESS.MD AS PRINTED. FIGURES MARKED FAKE ARE THE STUDIO’S OWN EXAMPLES, INVENTED FOR THE RECORD; PUBLISHED FIGURES ARE NAMED WITH THEIR SOURCES. NO PRIVATE PERSON IS NAMED.