|
@@ -6,6 +6,15 @@ Definitions for category aggregation.
|
|
|
# There are discrepancies of up to 100% due to rounding errors for small values,
|
|
|
# for example, 0.0001 (rounded from 0.00006) + 0.0004 (rounded from 0.00036)
|
|
|
# = 0.00042 which is then rounded to 0.0004, while the consistency check expects 0.0005
|
|
|
+# There are even more extreme example, where we need a tolerance of 100%:
|
|
|
+# Eswatini, 1976:
|
|
|
+# 1.A.1.a Crop residues (emissions N2O) = 0.0001
|
|
|
+# 1.A.1.a.i Crop residues (Indirect emissions N2O) = 0
|
|
|
+# 1.A.1.a.ii Crop residues (Direct emissions N2O) = 0
|
|
|
+# Our way to deal with it, was to set the tolerance to 1% and look at the
|
|
|
+# countries / sectors that yielded an error. If only a few countries and years
|
|
|
+# are affected, it is likely just a rounding error. If all years are affected
|
|
|
+# there may be something wrong with the data
|
|
|
agg_info_fao = {
|
|
|
"category (FAO)": {
|
|
|
"1.A.1.a": { # wheat
|
|
@@ -203,6 +212,18 @@ agg_info_fao = {
|
|
|
],
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
|
+ # Only some crop types are burned on the field
|
|
|
+ # Rounding errors up to 100% (see explanation above)
|
|
|
+ "M.1.BCR": {
|
|
|
+ "tolerance": 1,
|
|
|
+ "sources": [
|
|
|
+ "1.A.1.b", # wheat
|
|
|
+ "1.A.2.b", # rice
|
|
|
+ "1.A.6.b", # maize (corn)
|
|
|
+ "1.A.7.b", # sugar cane
|
|
|
+ ],
|
|
|
+ "sel": {"variable": ["N2O", "CH4"]},
|
|
|
+ },
|
|
|
"1.A": {
|
|
|
# crops
|
|
|
"tolerance": 1,
|
|
@@ -374,83 +395,66 @@ agg_info_fao = {
|
|
|
}
|
|
|
|
|
|
# aggregating each gas separately to make this easier to understand
|
|
|
-# We can change it back to one dict once it's all organised
|
|
|
+# We can change it back to one dict, once it's all sorted out
|
|
|
agg_info_ipcc2006_primap_N2O = {
|
|
|
"category (IPCC2006_PRIMAP)": {
|
|
|
- "3.C.1": { # Emissions from Biomass Burning
|
|
|
+ "M.3.C.1.AG": { # AG-related emissions from Biomass Burning
|
|
|
"sources": [
|
|
|
- # "3.C.1.a", # leaving out "Biomass Burning In Forest Lands", because not included in 2023 release
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
+ "3.C.1.b", # Biomass Burning In Croplands (FAO M.1.BCR All Crops - Burning crop residues)
|
|
|
+ "3.C.1.c", # Biomass Burning in Grasslands (FAO 6.B savanna fires)
|
|
|
],
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
|
- "M.3.C.1.AG": { # AG-related emissions from Biomass Burning
|
|
|
+ "3.C.1": { # Emissions from Biomass Burning (the same as M.3.C.1.AG)
|
|
|
+ "sources": ["M.3.C.1.AG"],
|
|
|
+ "sel": {"variable": ["N2O"]},
|
|
|
+ },
|
|
|
+ "3.C.4": { # Direct N2O Emissions from Managed Soils
|
|
|
+ # We currently only have direct and indirect emissions combined in one category.
|
|
|
+ # Therefore, we need to make a decision how to classify it. We decided to map it all to
|
|
|
+ # direct emissions. In does not make a difference for the primap-hist sectors,
|
|
|
+ # but TODO direct / indirect should be mapped individually
|
|
|
+ "sources": [
|
|
|
+ "M.3.C.45.MP", # Direct and indirect emissions from manure left on pasture (FAO M.3.MP)
|
|
|
+ "M.3.C.45.MA", # Direct and indirect emissions from manure applied to soils (FAO M.3.MA)
|
|
|
+ "M.3.C.45.CR", # Direct and indirect emissions from crop residues (FAO M.1.CR)
|
|
|
+ "3.C.4.a", # synthetic fertilisers direct (FAO 1.B.1)
|
|
|
+ "M.3.C.4.DOS.CL", # Drained cropland (FAO 5.A drained cropland)
|
|
|
+ "M.3.C.4.DOS.GL", # Drained grassland (FAO 5.B drained grassland)
|
|
|
+ ],
|
|
|
+ "sel": {"variable": ["N2O"]},
|
|
|
+ },
|
|
|
+ "3.C.5": { # Indirect N2O Emissions from Managed Soils
|
|
|
"sources": [
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
+ # Similarly to 3.C.4, 3.C.5 does not accurately represent the IPCC categories
|
|
|
+ # There should be only indirect emissions in this category, but we only have direct and indirect combined,
|
|
|
+ # except for "M.3.C.5.SF" which is only indirect
|
|
|
+ "M.3.C.5.SF", # synthetic fertilisers indirect - there is no IPCC sub-category for this
|
|
|
],
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
|
"M.3.C.AG": {
|
|
|
"sources": [
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands - looks good (CH4, N2O)
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands - looks good (CH4)
|
|
|
+ "M.3.C.1.AG", # AG-related emissions from Biomass Burning, same as 3.C.1
|
|
|
"3.C.4", # Direct N2O Emissions from Managed Soils
|
|
|
- "M.3.C.4.SF", # synthetic fertilisers direct
|
|
|
- # "3.C.5", # Indirect N2O Emissions from Managed Soils, currently empty
|
|
|
- "M.3.C.5.SF", # synthetic fertilisers indirect
|
|
|
- # "3.C.6", # Indirect N2O Emissions from Manure Management, currently empty
|
|
|
- "3.C.7", # rice cultivation
|
|
|
- "3.B.2", # Drained grassland, was in LULUCF orginally
|
|
|
- "3.B.3", # Drained cropland, was in LULUCF originally
|
|
|
+ "3.C.5", # Indirect N2O Emissions from Managed Soils
|
|
|
],
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
|
"M.AG.ELV": {
|
|
|
"sources": ["M.3.C.AG"],
|
|
|
- "sel": {"variable": ["N2O"]}, # "M.3.D.AG" is zero
|
|
|
+ "sel": {
|
|
|
+ "variable": ["N2O"]
|
|
|
+ }, # "M.3.D.AG" would be part of this, but does not exist
|
|
|
},
|
|
|
"3.C": {
|
|
|
- "sources": [
|
|
|
- "M.3.C.1.AG", # TODO 3.C.1 would be correct, but doesn't match 2023
|
|
|
- "3.C.4", # Direct N2O Emissions from Managed Soils
|
|
|
- "M.3.C.4.SF", # synthetic fertilisers direct
|
|
|
- # "3.C.5", # Indirect N2O Emissions from Managed Soils, empty
|
|
|
- "M.3.C.5.SF", # synthetic fertilisers indirect
|
|
|
- # "3.C.6", # Indirect N2O Emissions from Manure Management, empty
|
|
|
- "3.C.7", # rice cultivation
|
|
|
- "3.B.2", # Drained grassland, was in LULUCF orginally
|
|
|
- "3.B.3", # Drained cropland, was in LULUCF originally
|
|
|
- ],
|
|
|
- "sel": {"variable": ["N2O"]},
|
|
|
- },
|
|
|
- # TODO 3.A.2.x are currently not read in
|
|
|
- # "3.A.2.a": { # decomposition of manure - CH4, N2O
|
|
|
- # "sources": [
|
|
|
- # "3.A.2.a.i", # cattle (dairy)
|
|
|
- # "3.A.2.a.ii", # cattle (non-dairy)
|
|
|
- # ],
|
|
|
- # "sel": {"variable": ["N2O"]},
|
|
|
- # },
|
|
|
- # # consistency check
|
|
|
- # "3.A.2": { # decomposition of manure - CH4, N2O
|
|
|
- # "sources": [
|
|
|
- # "3.A.2.a",
|
|
|
- # "3.A.2.b",
|
|
|
- # "3.A.2.c",
|
|
|
- # "3.A.2.d",
|
|
|
- # "3.A.2.e",
|
|
|
- # "3.A.2.f",
|
|
|
- # "3.A.2.g",
|
|
|
- # "3.A.2.h",
|
|
|
- # "3.A.2.i",
|
|
|
- # "3.A.2.j",
|
|
|
- # ],
|
|
|
- # "sel": {"variable": ["N2O"]},
|
|
|
- # },
|
|
|
+ "sources": ["M.3.C.AG"],
|
|
|
+ "sel": {"variable": ["N2O"]},
|
|
|
+ },
|
|
|
"3.A": {
|
|
|
- "sources": ["3.A.1", "3.A.2"],
|
|
|
+ "sources": [
|
|
|
+ "3.A.2"
|
|
|
+ ], # Manure management (3.A.1 is enteric fermentation and CH4 only)
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
|
"M.AG": {
|
|
@@ -463,10 +467,10 @@ agg_info_ipcc2006_primap_N2O = {
|
|
|
"M.LULUCF": {
|
|
|
"sources": [
|
|
|
"3.B.1", # Carbon stock change in forests (FAO 4, or 4.A and 4.B)
|
|
|
- "M.NFC",
|
|
|
- # "3.B.2", # Drained grassland
|
|
|
- # "3.B.3", # Drained cropland
|
|
|
- "3.C.1.a", # Biomass Burning In Forests
|
|
|
+ # Note that IPCC M.3.C.1.a biomass burning in forest goes to LULUCF and not to AG. According to the FAO
|
|
|
+ # mapping document it is part of forest land.
|
|
|
+ # M.3.C.1.a for CO2 is an exception, because it is already included in the carbon stock change (FAO 4)
|
|
|
+ "M.3.C.1.a", # Biomass Burning In Forests (FAO 6.A forest fires)
|
|
|
],
|
|
|
"sel": {"variable": ["N2O"]},
|
|
|
},
|
|
@@ -479,55 +483,42 @@ agg_info_ipcc2006_primap_N2O = {
|
|
|
|
|
|
agg_info_ipcc2006_primap_CO2 = {
|
|
|
"category (IPCC2006_PRIMAP)": {
|
|
|
- "3.C.1": { # Emissions from Biomass Burning
|
|
|
- "sources": [
|
|
|
- # "3.C.1.a", # Biomass Burning In Forest Lands, because not there in 2023 release
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
- ],
|
|
|
- "sel": {"variable": ["CO2"]},
|
|
|
- },
|
|
|
- "M.3.C.1.AG": { # AG-related emissions from Biomass Burning
|
|
|
- "sources": [
|
|
|
- # "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
- ],
|
|
|
- "sel": {"variable": ["CO2"]},
|
|
|
- },
|
|
|
- "M.3.C.AG": {
|
|
|
- "sources": ["M.3.C.1.AG"],
|
|
|
- "sel": {"variable": ["CO2"]},
|
|
|
- },
|
|
|
- "3.C": {
|
|
|
- "sources": [
|
|
|
- "M.3.C.1.AG",
|
|
|
- ],
|
|
|
- "sel": {"variable": ["CO2"]},
|
|
|
- },
|
|
|
- "M.AG.ELV": {
|
|
|
+ # CO2 is LULUCF only
|
|
|
+ # To see which CO2 categories are mapped to LULUCF, go to the FAOSTAT data explorer
|
|
|
+ # and select for item: IPCC aggregates -> LULUCF list, elements: Emissions (CO2), years: any, country: any
|
|
|
+ # There will be four items for each country: Forestland, Net Forest Conversion, Fires in Organic Soils,
|
|
|
+ # and Drained Organic Soils (CO2)
|
|
|
+ # The selection for IPCC Agriculture will be empty, that means CO2 is all LULUCF
|
|
|
+ "3.B.2": {
|
|
|
"sources": [
|
|
|
- "M.3.C.AG",
|
|
|
+ "M.3.B.2.FOS", # crop land - fires in organic soils (6.C Fires in organic soils)
|
|
|
+ "M.3.B.2.DOS", # crop land - drained organic soils (FAO 5.B Drained cropland)
|
|
|
],
|
|
|
"sel": {"variable": ["CO2"]},
|
|
|
},
|
|
|
- "M.AG": {
|
|
|
+ "3.B.3": {
|
|
|
"sources": [
|
|
|
- "3.A",
|
|
|
- "M.AG.ELV",
|
|
|
+ "M.3.B.3.DOS", # grass land - drained organic soils (FAO 5.A Drained grassland)
|
|
|
],
|
|
|
"sel": {"variable": ["CO2"]},
|
|
|
},
|
|
|
"M.LULUCF": {
|
|
|
"sources": [
|
|
|
+ # Note that IPCC 3.B.1 comes from FAO 4 Carbon stock change in forests,
|
|
|
+ # which is the sum of forestland and net forest conversion.
|
|
|
+ # Also note that the category M.3.C.1.a (or FAO 6.A) forest fires would theoretically go
|
|
|
+ # into LULUCF. However, according to https://files-faostat.fao.org/production/GT/GT_en.pdf
|
|
|
+ # "The estimates from Forest fires exclude CO2, since these are
|
|
|
+ # already covered in the carbon stock changes calculations carried out in the FAOSTAT
|
|
|
+ # Forests domain." -> meaning CO2 is computed but not added to the LULUCF totals
|
|
|
"3.B.1", # Carbon stock change in forests (FAO 4, or 4.A and 4.B)
|
|
|
- "M.3.B.2.DOS", # crop land - drained organic soils
|
|
|
- "M.3.B.2.FOS", # crop land - fires in organic soils
|
|
|
+ "3.B.2", # crop land
|
|
|
"3.B.3", # grass land
|
|
|
],
|
|
|
"sel": {"variable": ["CO2"]},
|
|
|
},
|
|
|
"3": {
|
|
|
- "sources": ["M.AG", "M.LULUCF"],
|
|
|
+ "sources": ["M.LULUCF"],
|
|
|
"sel": {"variable": ["CO2"]},
|
|
|
},
|
|
|
}
|
|
@@ -535,75 +526,30 @@ agg_info_ipcc2006_primap_CO2 = {
|
|
|
|
|
|
agg_info_ipcc2006_primap_CH4 = {
|
|
|
"category (IPCC2006_PRIMAP)": {
|
|
|
- "3.A.1.a": { # enteric fermentation
|
|
|
- "sources": [
|
|
|
- "3.A.1.a.i", # cattle (dairy)
|
|
|
- "3.A.1.a.ii", # cattle (non-dairy)
|
|
|
- ],
|
|
|
- "sel": {"variable": ["CH4"]},
|
|
|
- },
|
|
|
- "3.A.1": { # enteric fermentation
|
|
|
+ "3.A": { # Livestock
|
|
|
"sources": [
|
|
|
- "3.A.1.a",
|
|
|
- "3.A.1.b",
|
|
|
- "3.A.1.c",
|
|
|
- "3.A.1.d",
|
|
|
- "3.A.1.e",
|
|
|
- "3.A.1.f",
|
|
|
- "3.A.1.g",
|
|
|
- "3.A.1.h",
|
|
|
- "3.A.1.j",
|
|
|
+ "3.A.1", # enteric fermentation (FAO M.3.EF)
|
|
|
+ "3.A.2", # manure management (FAO M.3.MM)
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|
|
|
- # TODO 3.A.2.x are currently not read in
|
|
|
- # "3.A.2.a": { # decomposition of manure - CH4, N2O
|
|
|
- # "sources": [
|
|
|
- # "3.A.2.a.i", # cattle (dairy)
|
|
|
- # "3.A.2.a.ii", # cattle (non-dairy)
|
|
|
- # ],
|
|
|
- # "sel": {"variable": ["CH4"]},
|
|
|
- # },
|
|
|
- # # consistency check
|
|
|
- # "3.A.2": { # decomposition of manure - CH4, N2O
|
|
|
- # "sources": [
|
|
|
- # "3.A.2.a",
|
|
|
- # "3.A.2.b",
|
|
|
- # "3.A.2.c",
|
|
|
- # "3.A.2.d",
|
|
|
- # "3.A.2.e",
|
|
|
- # "3.A.2.f",
|
|
|
- # "3.A.2.g",
|
|
|
- # "3.A.2.h",
|
|
|
- # "3.A.2.i",
|
|
|
- # "3.A.2.j",
|
|
|
- # ],
|
|
|
- # "sel": {"variable": ["CH4"]},
|
|
|
- # },
|
|
|
- "3.A": {
|
|
|
- "sources": ["3.A.1", "3.A.2"],
|
|
|
- "sel": {"variable": ["CH4"]},
|
|
|
- },
|
|
|
"3.C.1": { # Emissions from Biomass Burning
|
|
|
"sources": [
|
|
|
- # "3.C.1.a", # Biomass Burning In Forest Lands, because not there in 2023 release
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
+ "3.C.1.b", # Biomass Burning In Croplands (FAO M.1.BCR))
|
|
|
+ "3.C.1.c", # Biomass Burning in Grasslands (FAO 6.B savanna fires)
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|
|
|
"M.3.C.1.AG": { # AG-related emissions from Biomass Burning
|
|
|
"sources": [
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands
|
|
|
+ "3.C.1", # Emissions from Biomass Burning
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|
|
|
"M.3.C.AG": {
|
|
|
"sources": [
|
|
|
- "3.C.1.b", # Biomass Burning In Croplands - looks good (CH4, N2O)
|
|
|
- "3.C.1.c", # Biomass Burning in Grasslands - looks good (CH4)
|
|
|
- "3.C.7", # rice cultivation
|
|
|
+ "M.3.C.1.AG", # AG-related emissions from Biomass Burning
|
|
|
+ "3.C.7", # rice cultivation (FAO 1.A.2.c Rice cultivation)
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|
|
@@ -621,17 +567,15 @@ agg_info_ipcc2006_primap_CH4 = {
|
|
|
},
|
|
|
"M.AG": {
|
|
|
"sources": [
|
|
|
- "3.A",
|
|
|
- "M.AG.ELV",
|
|
|
+ "3.A", # Livestock
|
|
|
+ "M.AG.ELV", # Agriculture excluding livestock
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|
|
|
"M.LULUCF": {
|
|
|
"sources": [
|
|
|
- "3.B.1", # Carbon stock change in forests
|
|
|
- "3.B.2", # Drained grassland
|
|
|
- "3.B.3", # Drained cropland
|
|
|
- "3.C.1.a", # Biomass Burning In Forests
|
|
|
+ "M.3.C.1.a", # Biomass Burning In Forests (FAO 6.A forest fires)
|
|
|
+ "M.3.B.2.FOS", # cropland - fires in organic soils (FAO 6.C fires in organic soils)
|
|
|
],
|
|
|
"sel": {"variable": ["CH4"]},
|
|
|
},
|