hestia-earth-models 0.74.17__py3-none-any.whl → 0.75.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of hestia-earth-models might be problematic. Click here for more details.

Files changed (633) hide show
  1. hestia_earth/models/__init__.py +0 -3
  2. hestia_earth/models/mocking/search-results.json +1 -1
  3. hestia_earth/models/version.py +1 -1
  4. hestia_earth/orchestrator/__init__.py +0 -3
  5. {hestia_earth_models-0.74.17.dist-info → hestia_earth_models-0.75.0.dist-info}/METADATA +10 -14
  6. {hestia_earth_models-0.74.17.dist-info → hestia_earth_models-0.75.0.dist-info}/RECORD +9 -633
  7. {hestia_earth_models-0.74.17.dist-info → hestia_earth_models-0.75.0.dist-info}/WHEEL +1 -1
  8. {hestia_earth_models-0.74.17.dist-info → hestia_earth_models-0.75.0.dist-info}/top_level.txt +0 -1
  9. hestia_earth/__init__.py +0 -1
  10. tests/models/__init__.py +0 -0
  11. tests/models/agribalyse2016/__init__.py +0 -0
  12. tests/models/agribalyse2016/test_fuelElectricity.py +0 -42
  13. tests/models/agribalyse2016/test_machineryInfrastructureDepreciatedAmountPerCycle.py +0 -36
  14. tests/models/akagiEtAl2011/__init__.py +0 -0
  15. tests/models/akagiEtAl2011/test_ch4ToAirCropResidueBurning.py +0 -33
  16. tests/models/akagiEtAl2011/test_nh3ToAirCropResidueBurning.py +0 -33
  17. tests/models/akagiEtAl2011/test_noxToAirCropResidueBurning.py +0 -33
  18. tests/models/akagiEtAl2011/test_pm25ToAirCropResidueBurning.py +0 -33
  19. tests/models/akagiEtAl2011/test_so2ToAirCropResidueBurning.py +0 -33
  20. tests/models/akagiEtAl2011/test_utils.py +0 -19
  21. tests/models/aware/__init__.py +0 -0
  22. tests/models/aware/test_scarcityWeightedWaterUse.py +0 -57
  23. tests/models/aware2_0/__init__.py +0 -0
  24. tests/models/aware2_0/test_scarcityWeightedWaterUse.py +0 -58
  25. tests/models/chaudharyBrooks2018/__init__.py +0 -0
  26. tests/models/chaudharyBrooks2018/test_damageToTerrestrialEcosystemsLandOccupation.py +0 -58
  27. tests/models/chaudharyBrooks2018/test_damageToTerrestrialEcosystemsLandTransformation.py +0 -58
  28. tests/models/chaudharyBrooks2018/test_damageToTerrestrialEcosystemsTotalLandUseEffects.py +0 -20
  29. tests/models/cml2001Baseline/__init__.py +0 -0
  30. tests/models/cml2001Baseline/test_abioticResourceDepletionFossilFuels.py +0 -141
  31. tests/models/cml2001Baseline/test_abioticResourceDepletionMineralsAndMetals.py +0 -105
  32. tests/models/cml2001Baseline/test_eutrophicationPotentialExcludingFate.py +0 -23
  33. tests/models/cml2001Baseline/test_resourceUseEnergyDepletionDuringCycle.py +0 -136
  34. tests/models/cml2001Baseline/test_resourceUseEnergyDepletionInputsProduction.py +0 -23
  35. tests/models/cml2001Baseline/test_resourceUseMineralsAndMetalsDuringCycle.py +0 -58
  36. tests/models/cml2001Baseline/test_resourceUseMineralsAndMetalsInputsProduction.py +0 -23
  37. tests/models/cml2001Baseline/test_terrestrialAcidificationPotentialIncludingFateAverageEurope.py +0 -25
  38. tests/models/cml2001NonBaseline/__init__.py +0 -0
  39. tests/models/cml2001NonBaseline/test_eutrophicationPotentialIncludingFateAverageEurope.py +0 -23
  40. tests/models/cml2001NonBaseline/test_terrestrialAcidificationPotentialExcludingFate.py +0 -23
  41. tests/models/cycle/__init__.py +0 -0
  42. tests/models/cycle/animal/__init__.py +0 -0
  43. tests/models/cycle/animal/input/__init__.py +0 -0
  44. tests/models/cycle/animal/input/test_hestiaAggregatedData.py +0 -40
  45. tests/models/cycle/animal/input/test_properties.py +0 -55
  46. tests/models/cycle/animal/test_milkYield.py +0 -30
  47. tests/models/cycle/animal/test_properties.py +0 -20
  48. tests/models/cycle/completeness/__init__.py +0 -0
  49. tests/models/cycle/completeness/test_animalFeed.py +0 -14
  50. tests/models/cycle/completeness/test_cropResidue.py +0 -19
  51. tests/models/cycle/completeness/test_electricityFuel.py +0 -21
  52. tests/models/cycle/completeness/test_excretaManagement.py +0 -14
  53. tests/models/cycle/completeness/test_freshForage.py +0 -21
  54. tests/models/cycle/completeness/test_material.py +0 -18
  55. tests/models/cycle/completeness/test_seed.py +0 -36
  56. tests/models/cycle/completeness/test_soilAmendment.py +0 -23
  57. tests/models/cycle/input/__init__.py +0 -0
  58. tests/models/cycle/input/test_hestiaAggregatedData.py +0 -91
  59. tests/models/cycle/input/test_properties.py +0 -55
  60. tests/models/cycle/input/test_value.py +0 -41
  61. tests/models/cycle/post_checks/__init__.py +0 -0
  62. tests/models/cycle/post_checks/test_cache.py +0 -8
  63. tests/models/cycle/post_checks/test_otherSites.py +0 -15
  64. tests/models/cycle/post_checks/test_site.py +0 -26
  65. tests/models/cycle/practice/__init__.py +0 -0
  66. tests/models/cycle/practice/test_landCover.py +0 -27
  67. tests/models/cycle/practice/test_value.py +0 -52
  68. tests/models/cycle/pre_checks/__init__.py +0 -0
  69. tests/models/cycle/pre_checks/test_otherSites.py +0 -21
  70. tests/models/cycle/pre_checks/test_site.py +0 -33
  71. tests/models/cycle/product/__init__.py +0 -0
  72. tests/models/cycle/product/test_currency.py +0 -41
  73. tests/models/cycle/product/test_economicValueShare.py +0 -158
  74. tests/models/cycle/product/test_price.py +0 -29
  75. tests/models/cycle/product/test_primary.py +0 -75
  76. tests/models/cycle/product/test_properties.py +0 -32
  77. tests/models/cycle/product/test_revenue.py +0 -32
  78. tests/models/cycle/product/test_value.py +0 -41
  79. tests/models/cycle/test_aboveGroundCropResidueTotal.py +0 -20
  80. tests/models/cycle/test_completeness.py +0 -51
  81. tests/models/cycle/test_cycleDuration.py +0 -31
  82. tests/models/cycle/test_endDate.py +0 -38
  83. tests/models/cycle/test_otherSitesArea.py +0 -68
  84. tests/models/cycle/test_otherSitesUnusedDuration.py +0 -54
  85. tests/models/cycle/test_post_checks.py +0 -11
  86. tests/models/cycle/test_pre_checks.py +0 -11
  87. tests/models/cycle/test_siteArea.py +0 -51
  88. tests/models/cycle/test_siteDuration.py +0 -83
  89. tests/models/cycle/test_siteUnusedDuration.py +0 -55
  90. tests/models/cycle/test_startDate.py +0 -58
  91. tests/models/cycle/test_startDateDefinition.py +0 -31
  92. tests/models/cycle/test_transformations.py +0 -17
  93. tests/models/dammgen2009/__init__.py +0 -0
  94. tests/models/dammgen2009/test_noxToAirExcreta.py +0 -58
  95. tests/models/data/__init__.py +0 -0
  96. tests/models/data/test_hestiaAggregatedData.py +0 -32
  97. tests/models/deRuijterEtAl2010/__init__.py +0 -0
  98. tests/models/deRuijterEtAl2010/test_nh3ToAirCropResidueDecomposition.py +0 -57
  99. tests/models/ecoalimV9/__init__.py +0 -0
  100. tests/models/ecoalimV9/test_cycle.py +0 -22
  101. tests/models/ecoalimV9/test_impact_assessment.py +0 -24
  102. tests/models/ecoinventV3/__init__.py +0 -0
  103. tests/models/ecoinventV3/test_cycle.py +0 -69
  104. tests/models/ecoinventV3AndEmberClimate/__init__.py +0 -0
  105. tests/models/ecoinventV3AndEmberClimate/test_cycle.py +0 -28
  106. tests/models/edip2003/__init__.py +0 -0
  107. tests/models/edip2003/test_ozoneDepletionPotential.py +0 -21
  108. tests/models/emepEea2019/__init__.py +0 -0
  109. tests/models/emepEea2019/test_co2ToAirFuelCombustion.py +0 -34
  110. tests/models/emepEea2019/test_n2OToAirFuelCombustionDirect.py +0 -34
  111. tests/models/emepEea2019/test_nh3ToAirExcreta.py +0 -36
  112. tests/models/emepEea2019/test_nh3ToAirFuelCombustion.py +0 -34
  113. tests/models/emepEea2019/test_nh3ToAirInorganicFertiliser.py +0 -64
  114. tests/models/emepEea2019/test_noxToAirFuelCombustion.py +0 -34
  115. tests/models/emepEea2019/test_pm10ToAirAnimalHousing.py +0 -21
  116. tests/models/emepEea2019/test_pm25ToAirAnimalHousing.py +0 -21
  117. tests/models/emepEea2019/test_so2ToAirFuelCombustion.py +0 -34
  118. tests/models/emepEea2019/test_tspToAirAnimalHousing.py +0 -21
  119. tests/models/emepEea2019/test_utils.py +0 -204
  120. tests/models/environmentalFootprintV3_1/__init__.py +0 -0
  121. tests/models/environmentalFootprintV3_1/test_environmentalFootprintSingleOverallScore.py +0 -138
  122. tests/models/environmentalFootprintV3_1/test_freshwaterEcotoxicityPotentialCtue.py +0 -26
  123. tests/models/environmentalFootprintV3_1/test_marineEutrophicationPotential.py +0 -21
  124. tests/models/environmentalFootprintV3_1/test_photochemicalOzoneCreationPotentialHumanHealthNmvocEq.py +0 -30
  125. tests/models/environmentalFootprintV3_1/test_scarcityWeightedWaterUse.py +0 -27
  126. tests/models/environmentalFootprintV3_1/test_soilQualityIndexLandOccupation.py +0 -160
  127. tests/models/environmentalFootprintV3_1/test_soilQualityIndexLandTransformation.py +0 -184
  128. tests/models/environmentalFootprintV3_1/test_soilQualityIndexTotalLandUseEffects.py +0 -78
  129. tests/models/epa2014/__init__.py +0 -0
  130. tests/models/epa2014/test_no3ToGroundwaterExcreta.py +0 -38
  131. tests/models/fantkeEtAl2016/__init__.py +0 -0
  132. tests/models/fantkeEtAl2016/test_damageToHumanHealthParticulateMatterFormation.py +0 -20
  133. tests/models/faostat2018/__init__.py +0 -0
  134. tests/models/faostat2018/product/__init__.py +0 -0
  135. tests/models/faostat2018/product/test_price.py +0 -117
  136. tests/models/faostat2018/test_coldCarcassWeightPerHead.py +0 -58
  137. tests/models/faostat2018/test_coldDressedCarcassWeightPerHead.py +0 -54
  138. tests/models/faostat2018/test_faostat_utils.py +0 -64
  139. tests/models/faostat2018/test_liveweightPerHead.py +0 -134
  140. tests/models/faostat2018/test_readyToCookWeightPerHead.py +0 -54
  141. tests/models/faostat2018/test_seed.py +0 -50
  142. tests/models/faostat2018/test_utils.py +0 -28
  143. tests/models/frischknechtEtAl2000/__init__.py +0 -0
  144. tests/models/frischknechtEtAl2000/test_ionisingRadiationKbqU235Eq.py +0 -138
  145. tests/models/geospatialDatabase/__init__.py +0 -0
  146. tests/models/geospatialDatabase/test_awareWaterBasinId.py +0 -27
  147. tests/models/geospatialDatabase/test_clayContent.py +0 -49
  148. tests/models/geospatialDatabase/test_croppingIntensity.py +0 -33
  149. tests/models/geospatialDatabase/test_drainageClass.py +0 -29
  150. tests/models/geospatialDatabase/test_ecoClimateZone.py +0 -32
  151. tests/models/geospatialDatabase/test_ecoregion.py +0 -27
  152. tests/models/geospatialDatabase/test_erodibility.py +0 -29
  153. tests/models/geospatialDatabase/test_heavyWinterPrecipitation.py +0 -29
  154. tests/models/geospatialDatabase/test_histosol.py +0 -33
  155. tests/models/geospatialDatabase/test_longFallowRatio.py +0 -33
  156. tests/models/geospatialDatabase/test_nutrientLossToAquaticEnvironment.py +0 -29
  157. tests/models/geospatialDatabase/test_organicCarbonPerKgSoil.py +0 -43
  158. tests/models/geospatialDatabase/test_potentialEvapotranspirationAnnual.py +0 -19
  159. tests/models/geospatialDatabase/test_potentialEvapotranspirationLongTermAnnualMean.py +0 -30
  160. tests/models/geospatialDatabase/test_potentialEvapotranspirationMonthly.py +0 -20
  161. tests/models/geospatialDatabase/test_precipitationAnnual.py +0 -20
  162. tests/models/geospatialDatabase/test_precipitationLongTermAnnualMean.py +0 -29
  163. tests/models/geospatialDatabase/test_precipitationMonthly.py +0 -20
  164. tests/models/geospatialDatabase/test_region.py +0 -27
  165. tests/models/geospatialDatabase/test_sandContent.py +0 -49
  166. tests/models/geospatialDatabase/test_siltContent.py +0 -37
  167. tests/models/geospatialDatabase/test_slope.py +0 -29
  168. tests/models/geospatialDatabase/test_slopeLength.py +0 -29
  169. tests/models/geospatialDatabase/test_soilPh.py +0 -43
  170. tests/models/geospatialDatabase/test_temperatureAnnual.py +0 -20
  171. tests/models/geospatialDatabase/test_temperatureLongTermAnnualMean.py +0 -29
  172. tests/models/geospatialDatabase/test_temperatureMonthly.py +0 -20
  173. tests/models/geospatialDatabase/test_totalNitrogenPerKgSoil.py +0 -43
  174. tests/models/geospatialDatabase/test_totalPhosphorusPerKgSoil.py +0 -29
  175. tests/models/geospatialDatabase/test_utils.py +0 -39
  176. tests/models/geospatialDatabase/test_waterDepth.py +0 -28
  177. tests/models/globalCropWaterModel2008/__init__.py +0 -0
  178. tests/models/globalCropWaterModel2008/test_rootingDepth.py +0 -84
  179. tests/models/haversineFormula/__init__.py +0 -0
  180. tests/models/haversineFormula/transport/__init__.py +0 -0
  181. tests/models/haversineFormula/transport/test_distance.py +0 -28
  182. tests/models/hestia/__init__.py +0 -0
  183. tests/models/hestia/test_aboveGroundCropResidue.py +0 -40
  184. tests/models/hestia/test_aboveGroundCropResidueTotal.py +0 -41
  185. tests/models/hestia/test_brackishWater.py +0 -32
  186. tests/models/hestia/test_cationExchangeCapacityPerKgSoil.py +0 -34
  187. tests/models/hestia/test_coldCarcassWeightPerHead.py +0 -47
  188. tests/models/hestia/test_coldDressedCarcassWeightPerHead.py +0 -47
  189. tests/models/hestia/test_concentrateFeed.py +0 -52
  190. tests/models/hestia/test_cropResidueManagement.py +0 -53
  191. tests/models/hestia/test_croppingIntensity.py +0 -53
  192. tests/models/hestia/test_default_emissions.py +0 -32
  193. tests/models/hestia/test_default_resourceUse.py +0 -32
  194. tests/models/hestia/test_energyContentLowerHeatingValue.py +0 -40
  195. tests/models/hestia/test_excretaKgMass.py +0 -97
  196. tests/models/hestia/test_excretaKgN.py +0 -36
  197. tests/models/hestia/test_excretaKgVs.py +0 -36
  198. tests/models/hestia/test_feedConversionRatio.py +0 -64
  199. tests/models/hestia/test_flowingWater.py +0 -44
  200. tests/models/hestia/test_freshWater.py +0 -32
  201. tests/models/hestia/test_histosol.py +0 -24
  202. tests/models/hestia/test_inorganicFertiliser.py +0 -20
  203. tests/models/hestia/test_irrigatedTypeUnspecified.py +0 -59
  204. tests/models/hestia/test_landCover.py +0 -100
  205. tests/models/hestia/test_landCover_utils.py +0 -233
  206. tests/models/hestia/test_landOccupationDuringCycle.py +0 -75
  207. tests/models/hestia/test_landTransformation100YearAverageDuringCycle.py +0 -30
  208. tests/models/hestia/test_landTransformation20YearAverageDuringCycle.py +0 -29
  209. tests/models/hestia/test_liveAnimal.py +0 -64
  210. tests/models/hestia/test_longFallowRatio.py +0 -49
  211. tests/models/hestia/test_management.py +0 -80
  212. tests/models/hestia/test_materialsAndSubstrate.py +0 -49
  213. tests/models/hestia/test_milkYield.py +0 -58
  214. tests/models/hestia/test_netPrimaryProduction.py +0 -38
  215. tests/models/hestia/test_organicCarbonPerHa.py +0 -104
  216. tests/models/hestia/test_organicCarbonPerKgSoil.py +0 -34
  217. tests/models/hestia/test_organicCarbonPerM3Soil.py +0 -34
  218. tests/models/hestia/test_organicMatterPerKgSoil.py +0 -34
  219. tests/models/hestia/test_organicMatterPerM3Soil.py +0 -34
  220. tests/models/hestia/test_pToSurfaceWaterAquacultureSystems.py +0 -56
  221. tests/models/hestia/test_pastureGrass.py +0 -31
  222. tests/models/hestia/test_pastureSystem.py +0 -47
  223. tests/models/hestia/test_potentialEvapotranspirationAnnual.py +0 -32
  224. tests/models/hestia/test_potentialEvapotranspirationMonthly.py +0 -32
  225. tests/models/hestia/test_precipitationAnnual.py +0 -32
  226. tests/models/hestia/test_precipitationMonthly.py +0 -32
  227. tests/models/hestia/test_rainfallAnnual.py +0 -32
  228. tests/models/hestia/test_rainfallMonthly.py +0 -32
  229. tests/models/hestia/test_readyToCookWeightPerHead.py +0 -47
  230. tests/models/hestia/test_residueBurnt.py +0 -37
  231. tests/models/hestia/test_residueIncorporated.py +0 -48
  232. tests/models/hestia/test_residueLeftOnField.py +0 -37
  233. tests/models/hestia/test_residueRemoved.py +0 -32
  234. tests/models/hestia/test_salineWater.py +0 -32
  235. tests/models/hestia/test_seed_emissions.py +0 -27
  236. tests/models/hestia/test_slope.py +0 -23
  237. tests/models/hestia/test_slopeLength.py +0 -23
  238. tests/models/hestia/test_soilClassification.py +0 -72
  239. tests/models/hestia/test_soilMeasurement.py +0 -156
  240. tests/models/hestia/test_stockingDensityAnimalHousingAverage.py +0 -42
  241. tests/models/hestia/test_temperatureAnnual.py +0 -32
  242. tests/models/hestia/test_temperatureMonthly.py +0 -32
  243. tests/models/hestia/test_totalNitrogenPerKgSoil.py +0 -36
  244. tests/models/hestia/test_unknownPreSeasonWaterRegime.py +0 -36
  245. tests/models/hestia/test_waterDepth.py +0 -34
  246. tests/models/hestia/test_waterSalinity.py +0 -38
  247. tests/models/impact_assessment/__init__.py +0 -0
  248. tests/models/impact_assessment/post_checks/__init__.py +0 -0
  249. tests/models/impact_assessment/post_checks/test_cycle.py +0 -28
  250. tests/models/impact_assessment/post_checks/test_remove_cache_fields.py +0 -6
  251. tests/models/impact_assessment/post_checks/test_remove_no_value.py +0 -17
  252. tests/models/impact_assessment/post_checks/test_site.py +0 -28
  253. tests/models/impact_assessment/pre_checks/__init__.py +0 -0
  254. tests/models/impact_assessment/pre_checks/test_cycle.py +0 -39
  255. tests/models/impact_assessment/pre_checks/test_site.py +0 -37
  256. tests/models/impact_assessment/product/__init__.py +0 -0
  257. tests/models/impact_assessment/product/test_economicValueShare.py +0 -36
  258. tests/models/impact_assessment/product/test_value.py +0 -36
  259. tests/models/impact_assessment/test_allocationMethod.py +0 -48
  260. tests/models/impact_assessment/test_emissions.py +0 -31
  261. tests/models/impact_assessment/test_irrigated.py +0 -14
  262. tests/models/impact_assessment/test_oganic.py +0 -14
  263. tests/models/impact_assessment/test_post_checks.py +0 -11
  264. tests/models/impact_assessment/test_pre_checks.py +0 -11
  265. tests/models/ipcc2006/__init__.py +0 -0
  266. tests/models/ipcc2006/test_aboveGroundCropResidueRemoved.py +0 -36
  267. tests/models/ipcc2006/test_aboveGroundCropResidueTotal.py +0 -48
  268. tests/models/ipcc2006/test_belowGroundCropResidue.py +0 -45
  269. tests/models/ipcc2006/test_n2OToAirCropResidueDecompositionDirect.py +0 -53
  270. tests/models/ipcc2006/test_n2OToAirCropResidueDecompositionIndirect.py +0 -45
  271. tests/models/ipcc2006/test_n2OToAirExcretaDirect.py +0 -68
  272. tests/models/ipcc2006/test_n2OToAirExcretaIndirect.py +0 -45
  273. tests/models/ipcc2006/test_n2OToAirInorganicFertiliserDirect.py +0 -55
  274. tests/models/ipcc2006/test_n2OToAirInorganicFertiliserIndirect.py +0 -43
  275. tests/models/ipcc2006/test_n2OToAirOrganicFertiliserDirect.py +0 -55
  276. tests/models/ipcc2006/test_n2OToAirOrganicFertiliserIndirect.py +0 -55
  277. tests/models/ipcc2013ExcludingFeedbacks/__init__.py +0 -0
  278. tests/models/ipcc2013ExcludingFeedbacks/test_gwp100.py +0 -23
  279. tests/models/ipcc2013IncludingFeedbacks/__init__.py +0 -0
  280. tests/models/ipcc2013IncludingFeedbacks/test_gwp100.py +0 -23
  281. tests/models/ipcc2019/__init__.py +0 -0
  282. tests/models/ipcc2019/animal/__init__.py +0 -0
  283. tests/models/ipcc2019/animal/test_fatContent.py +0 -22
  284. tests/models/ipcc2019/animal/test_hoursWorkedPerDay.py +0 -22
  285. tests/models/ipcc2019/animal/test_liveweightGain.py +0 -22
  286. tests/models/ipcc2019/animal/test_liveweightPerHead.py +0 -22
  287. tests/models/ipcc2019/animal/test_milkYieldPerAnimal.py +0 -21
  288. tests/models/ipcc2019/animal/test_pastureGrass.py +0 -47
  289. tests/models/ipcc2019/animal/test_pregnancyRateTotal.py +0 -22
  290. tests/models/ipcc2019/animal/test_trueProteinContent.py +0 -22
  291. tests/models/ipcc2019/animal/test_weightAtMaturity.py +0 -21
  292. tests/models/ipcc2019/test_aboveGroundBiomass.py +0 -189
  293. tests/models/ipcc2019/test_aboveGroundCropResidueTotal.py +0 -51
  294. tests/models/ipcc2019/test_belowGroundBiomass.py +0 -189
  295. tests/models/ipcc2019/test_belowGroundCropResidue.py +0 -77
  296. tests/models/ipcc2019/test_biocharOrganicCarbonPerHa.py +0 -132
  297. tests/models/ipcc2019/test_biomass_utils.py +0 -115
  298. tests/models/ipcc2019/test_carbonContent.py +0 -119
  299. tests/models/ipcc2019/test_ch4ToAirAquacultureSystems.py +0 -60
  300. tests/models/ipcc2019/test_ch4ToAirEntericFermentation.py +0 -199
  301. tests/models/ipcc2019/test_ch4ToAirExcreta.py +0 -83
  302. tests/models/ipcc2019/test_ch4ToAirFloodedRice.py +0 -25
  303. tests/models/ipcc2019/test_ch4ToAirOrganicSoilCultivation.py +0 -62
  304. tests/models/ipcc2019/test_co2ToAirAboveGroundBiomassStockChange.py +0 -120
  305. tests/models/ipcc2019/test_co2ToAirBelowGroundBiomassStockChange.py +0 -118
  306. tests/models/ipcc2019/test_co2ToAirBiocharStockChange.py +0 -90
  307. tests/models/ipcc2019/test_co2ToAirCarbonStockChange_utils.py +0 -50
  308. tests/models/ipcc2019/test_co2ToAirLimeHydrolysis.py +0 -49
  309. tests/models/ipcc2019/test_co2ToAirOrganicSoilCultivation.py +0 -63
  310. tests/models/ipcc2019/test_co2ToAirSoilOrganicCarbonStockChange.py +0 -151
  311. tests/models/ipcc2019/test_co2ToAirUreaHydrolysis.py +0 -30
  312. tests/models/ipcc2019/test_croppingDuration.py +0 -55
  313. tests/models/ipcc2019/test_ligninContent.py +0 -119
  314. tests/models/ipcc2019/test_n2OToAirAquacultureSystemsIndirect.py +0 -45
  315. tests/models/ipcc2019/test_n2OToAirCropResidueBurningDirect.py +0 -46
  316. tests/models/ipcc2019/test_n2OToAirCropResidueBurningIndirect.py +0 -45
  317. tests/models/ipcc2019/test_n2OToAirCropResidueDecompositionDirect.py +0 -79
  318. tests/models/ipcc2019/test_n2OToAirCropResidueDecompositionIndirect.py +0 -45
  319. tests/models/ipcc2019/test_n2OToAirExcretaDirect.py +0 -50
  320. tests/models/ipcc2019/test_n2OToAirExcretaIndirect.py +0 -45
  321. tests/models/ipcc2019/test_n2OToAirFuelCombustionIndirect.py +0 -45
  322. tests/models/ipcc2019/test_n2OToAirInorganicFertiliserDirect.py +0 -79
  323. tests/models/ipcc2019/test_n2OToAirInorganicFertiliserIndirect.py +0 -45
  324. tests/models/ipcc2019/test_n2OToAirNaturalVegetationBurningIndirect.py +0 -45
  325. tests/models/ipcc2019/test_n2OToAirOrganicFertiliserDirect.py +0 -79
  326. tests/models/ipcc2019/test_n2OToAirOrganicFertiliserIndirect.py +0 -45
  327. tests/models/ipcc2019/test_n2OToAirOrganicSoilBurningIndirect.py +0 -45
  328. tests/models/ipcc2019/test_n2OToAirOrganicSoilCultivationDirect.py +0 -62
  329. tests/models/ipcc2019/test_n2OToAirOrganicSoilCultivationIndirect.py +0 -45
  330. tests/models/ipcc2019/test_n2OToAir_indirect_emissions_utils.py +0 -19
  331. tests/models/ipcc2019/test_nh3ToAirInorganicFertiliser.py +0 -47
  332. tests/models/ipcc2019/test_nh3ToAirOrganicFertiliser.py +0 -35
  333. tests/models/ipcc2019/test_nitrogenContent.py +0 -107
  334. tests/models/ipcc2019/test_no3ToGroundwaterCropResidueDecomposition.py +0 -51
  335. tests/models/ipcc2019/test_no3ToGroundwaterExcreta.py +0 -64
  336. tests/models/ipcc2019/test_no3ToGroundwaterInorganicFertiliser.py +0 -48
  337. tests/models/ipcc2019/test_no3ToGroundwaterOrganicFertiliser.py +0 -48
  338. tests/models/ipcc2019/test_nonCo2EmissionsToAirNaturalVegetationBurning.py +0 -97
  339. tests/models/ipcc2019/test_noxToAirInorganicFertiliser.py +0 -47
  340. tests/models/ipcc2019/test_noxToAirOrganicFertiliser.py +0 -35
  341. tests/models/ipcc2019/test_organicCarbonPerHa.py +0 -415
  342. tests/models/ipcc2019/test_organicCarbonPerHa_tier_1.py +0 -465
  343. tests/models/ipcc2019/test_organicCarbonPerHa_tier_2.py +0 -148
  344. tests/models/ipcc2019/test_organicCarbonPerHa_utils.py +0 -31
  345. tests/models/ipcc2019/test_pastureGrass.py +0 -68
  346. tests/models/ipcc2021/__init__.py +0 -0
  347. tests/models/ipcc2021/test_gwp100.py +0 -23
  348. tests/models/jarvisAndPain1994/__init__.py +0 -0
  349. tests/models/jarvisAndPain1994/test_n2ToAirExcreta.py +0 -37
  350. tests/models/koble2014/__init__.py +0 -0
  351. tests/models/koble2014/test_cropResidueManagement.py +0 -19
  352. tests/models/koble2014/test_residueBurnt.py +0 -20
  353. tests/models/koble2014/test_residueLeftOnField.py +0 -21
  354. tests/models/koble2014/test_residueRemoved.py +0 -20
  355. tests/models/koble2014/test_utils.py +0 -52
  356. tests/models/lcImpactAllEffects100Years/__init__.py +0 -0
  357. tests/models/lcImpactAllEffects100Years/test_damageToFreshwaterEcosystemsClimateChange.py +0 -23
  358. tests/models/lcImpactAllEffects100Years/test_damageToFreshwaterEcosystemsFreshwaterEcotoxicity.py +0 -25
  359. tests/models/lcImpactAllEffects100Years/test_damageToFreshwaterEcosystemsFreshwaterEutrophication.py +0 -25
  360. tests/models/lcImpactAllEffects100Years/test_damageToFreshwaterEcosystemsPdfYear.py +0 -20
  361. tests/models/lcImpactAllEffects100Years/test_damageToFreshwaterEcosystemsWaterStress.py +0 -21
  362. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealth.py +0 -20
  363. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthClimateChange.py +0 -23
  364. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthHumanToxicityCancerogenic.py +0 -25
  365. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthHumanToxicityNonCancerogenic.py +0 -25
  366. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthParticulateMatterFormation.py +0 -25
  367. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthPhotochemicalOzoneFormation.py +0 -25
  368. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthStratosphericOzoneDepletion.py +0 -25
  369. tests/models/lcImpactAllEffects100Years/test_damageToHumanHealthWaterStress.py +0 -32
  370. tests/models/lcImpactAllEffects100Years/test_damageToMarineEcosystemsMarineEcotoxicity.py +0 -25
  371. tests/models/lcImpactAllEffects100Years/test_damageToMarineEcosystemsMarineEutrophication.py +0 -25
  372. tests/models/lcImpactAllEffects100Years/test_damageToMarineEcosystemsPdfYear.py +0 -20
  373. tests/models/lcImpactAllEffects100Years/test_damageToTerrestrialEcosystemsClimateChange.py +0 -25
  374. tests/models/lcImpactAllEffects100Years/test_damageToTerrestrialEcosystemsPdfYear.py +0 -20
  375. tests/models/lcImpactAllEffects100Years/test_damageToTerrestrialEcosystemsPhotochemicalOzoneFormation.py +0 -25
  376. tests/models/lcImpactAllEffects100Years/test_damageToTerrestrialEcosystemsTerrestrialAcidification.py +0 -25
  377. tests/models/lcImpactAllEffects100Years/test_damageToTerrestrialEcosystemsTerrestrialEcotoxicity.py +0 -25
  378. tests/models/lcImpactAllEffectsInfinite/__init__.py +0 -0
  379. tests/models/lcImpactAllEffectsInfinite/test_damageToFreshwaterEcosystemsClimateChange.py +0 -23
  380. tests/models/lcImpactAllEffectsInfinite/test_damageToFreshwaterEcosystemsFreshwaterEcotoxicity.py +0 -25
  381. tests/models/lcImpactAllEffectsInfinite/test_damageToFreshwaterEcosystemsFreshwaterEutrophication.py +0 -25
  382. tests/models/lcImpactAllEffectsInfinite/test_damageToFreshwaterEcosystemsPdfYear.py +0 -20
  383. tests/models/lcImpactAllEffectsInfinite/test_damageToFreshwaterEcosystemsWaterStress.py +0 -21
  384. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealth.py +0 -20
  385. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthClimateChange.py +0 -23
  386. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthHumanToxicityCancerogenic.py +0 -25
  387. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthHumanToxicityNonCancerogenic.py +0 -25
  388. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthParticulateMatterFormation.py +0 -25
  389. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthPhotochemicalOzoneFormation.py +0 -25
  390. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthStratosphericOzoneDepletion.py +0 -25
  391. tests/models/lcImpactAllEffectsInfinite/test_damageToHumanHealthWaterStress.py +0 -32
  392. tests/models/lcImpactAllEffectsInfinite/test_damageToMarineEcosystemsMarineEcotoxicity.py +0 -25
  393. tests/models/lcImpactAllEffectsInfinite/test_damageToMarineEcosystemsMarineEutrophication.py +0 -25
  394. tests/models/lcImpactAllEffectsInfinite/test_damageToMarineEcosystemsPdfYear.py +0 -20
  395. tests/models/lcImpactAllEffectsInfinite/test_damageToTerrestrialEcosystemsClimateChange.py +0 -25
  396. tests/models/lcImpactAllEffectsInfinite/test_damageToTerrestrialEcosystemsPdfYear.py +0 -20
  397. tests/models/lcImpactAllEffectsInfinite/test_damageToTerrestrialEcosystemsPhotochemicalOzoneFormation.py +0 -25
  398. tests/models/lcImpactAllEffectsInfinite/test_damageToTerrestrialEcosystemsTerrestrialAcidification.py +0 -25
  399. tests/models/lcImpactAllEffectsInfinite/test_damageToTerrestrialEcosystemsTerrestrialEcotoxicity.py +0 -25
  400. tests/models/lcImpactCertainEffects100Years/__init__.py +0 -0
  401. tests/models/lcImpactCertainEffects100Years/test_damageToFreshwaterEcosystemsFreshwaterEcotoxicity.py +0 -25
  402. tests/models/lcImpactCertainEffects100Years/test_damageToFreshwaterEcosystemsFreshwaterEutrophication.py +0 -25
  403. tests/models/lcImpactCertainEffects100Years/test_damageToFreshwaterEcosystemsPdfYear.py +0 -20
  404. tests/models/lcImpactCertainEffects100Years/test_damageToFreshwaterEcosystemsWaterStress.py +0 -21
  405. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealth.py +0 -20
  406. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthClimateChange.py +0 -23
  407. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthHumanToxicityCancerogenic.py +0 -25
  408. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthHumanToxicityNonCancerogenic.py +0 -25
  409. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthParticulateMatterFormation.py +0 -25
  410. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthPhotochemicalOzoneFormation.py +0 -25
  411. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthStratosphericOzoneDepletion.py +0 -25
  412. tests/models/lcImpactCertainEffects100Years/test_damageToHumanHealthWaterStress.py +0 -32
  413. tests/models/lcImpactCertainEffects100Years/test_damageToMarineEcosystemsMarineEcotoxicity.py +0 -25
  414. tests/models/lcImpactCertainEffects100Years/test_damageToMarineEcosystemsMarineEutrophication.py +0 -25
  415. tests/models/lcImpactCertainEffects100Years/test_damageToMarineEcosystemsPdfYear.py +0 -20
  416. tests/models/lcImpactCertainEffects100Years/test_damageToTerrestrialEcosystemsClimateChange.py +0 -25
  417. tests/models/lcImpactCertainEffects100Years/test_damageToTerrestrialEcosystemsPdfYear.py +0 -20
  418. tests/models/lcImpactCertainEffects100Years/test_damageToTerrestrialEcosystemsPhotochemicalOzoneFormation.py +0 -25
  419. tests/models/lcImpactCertainEffects100Years/test_damageToTerrestrialEcosystemsTerrestrialAcidification.py +0 -25
  420. tests/models/lcImpactCertainEffects100Years/test_damageToTerrestrialEcosystemsTerrestrialEcotoxicity.py +0 -25
  421. tests/models/lcImpactCertainEffectsInfinite/__init__.py +0 -0
  422. tests/models/lcImpactCertainEffectsInfinite/test_damageToFreshwaterEcosystemsFreshwaterEcotoxicity.py +0 -25
  423. tests/models/lcImpactCertainEffectsInfinite/test_damageToFreshwaterEcosystemsFreshwaterEutrophication.py +0 -25
  424. tests/models/lcImpactCertainEffectsInfinite/test_damageToFreshwaterEcosystemsPdfYear.py +0 -20
  425. tests/models/lcImpactCertainEffectsInfinite/test_damageToFreshwaterEcosystemsWaterStress.py +0 -21
  426. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealth.py +0 -20
  427. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthClimateChange.py +0 -23
  428. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthHumanToxicityCancerogenic.py +0 -25
  429. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthHumanToxicityNonCancerogenic.py +0 -25
  430. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthParticulateMatterFormation.py +0 -25
  431. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthPhotochemicalOzoneFormation.py +0 -25
  432. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthStratosphericOzoneDepletion.py +0 -25
  433. tests/models/lcImpactCertainEffectsInfinite/test_damageToHumanHealthWaterStress.py +0 -32
  434. tests/models/lcImpactCertainEffectsInfinite/test_damageToMarineEcosystemsMarineEcotoxicity.py +0 -25
  435. tests/models/lcImpactCertainEffectsInfinite/test_damageToMarineEcosystemsMarineEutrophication.py +0 -25
  436. tests/models/lcImpactCertainEffectsInfinite/test_damageToMarineEcosystemsPdfYear.py +0 -20
  437. tests/models/lcImpactCertainEffectsInfinite/test_damageToTerrestrialEcosystemsClimateChange.py +0 -25
  438. tests/models/lcImpactCertainEffectsInfinite/test_damageToTerrestrialEcosystemsPdfYear.py +0 -20
  439. tests/models/lcImpactCertainEffectsInfinite/test_damageToTerrestrialEcosystemsPhotochemicalOzoneFormation.py +0 -25
  440. tests/models/lcImpactCertainEffectsInfinite/test_damageToTerrestrialEcosystemsTerrestrialAcidification.py +0 -25
  441. tests/models/lcImpactCertainEffectsInfinite/test_damageToTerrestrialEcosystemsTerrestrialEcotoxicity.py +0 -25
  442. tests/models/linkedImpactAssessment/__init__.py +0 -0
  443. tests/models/linkedImpactAssessment/test_emissions.py +0 -22
  444. tests/models/linkedImpactAssessment/test_freshwaterWithdrawalsInputsProduction.py +0 -23
  445. tests/models/linkedImpactAssessment/test_landOccupationInputsProduction.py +0 -23
  446. tests/models/linkedImpactAssessment/test_landTransformation100YearAverageInputsProduction.py +0 -25
  447. tests/models/linkedImpactAssessment/test_landTransformation20YearAverageInputsProduction.py +0 -25
  448. tests/models/pooreNemecek2018/__init__.py +0 -0
  449. tests/models/pooreNemecek2018/test_aboveGroundCropResidueTotal.py +0 -45
  450. tests/models/pooreNemecek2018/test_belowGroundCropResidue.py +0 -45
  451. tests/models/pooreNemecek2018/test_ch4ToAirAquacultureSystems.py +0 -79
  452. tests/models/pooreNemecek2018/test_excretaKgN.py +0 -124
  453. tests/models/pooreNemecek2018/test_excretaKgVs.py +0 -107
  454. tests/models/pooreNemecek2018/test_freshwaterWithdrawalsDuringCycle.py +0 -60
  455. tests/models/pooreNemecek2018/test_landOccupationDuringCycle.py +0 -51
  456. tests/models/pooreNemecek2018/test_longFallowDuration.py +0 -29
  457. tests/models/pooreNemecek2018/test_n2OToAirAquacultureSystemsDirect.py +0 -59
  458. tests/models/pooreNemecek2018/test_n2ToAirAquacultureSystems.py +0 -59
  459. tests/models/pooreNemecek2018/test_nh3ToAirAquacultureSystems.py +0 -80
  460. tests/models/pooreNemecek2018/test_no3ToGroundwaterCropResidueDecomposition.py +0 -23
  461. tests/models/pooreNemecek2018/test_no3ToGroundwaterExcreta.py +0 -23
  462. tests/models/pooreNemecek2018/test_no3ToGroundwaterInorganicFertiliser.py +0 -23
  463. tests/models/pooreNemecek2018/test_no3ToGroundwaterOrganicFertiliser.py +0 -23
  464. tests/models/pooreNemecek2018/test_noxToAirAquacultureSystems.py +0 -59
  465. tests/models/pooreNemecek2018/test_nurseryDensity.py +0 -29
  466. tests/models/pooreNemecek2018/test_nurseryDuration.py +0 -29
  467. tests/models/pooreNemecek2018/test_plantationDensity.py +0 -29
  468. tests/models/pooreNemecek2018/test_plantationLifespan.py +0 -29
  469. tests/models/pooreNemecek2018/test_plantationProductiveLifespan.py +0 -29
  470. tests/models/pooreNemecek2018/test_rotationDuration.py +0 -29
  471. tests/models/pooreNemecek2018/test_saplingsDepreciatedAmountPerCycle.py +0 -46
  472. tests/models/pooreNemecek2018/test_utils.py +0 -26
  473. tests/models/poschEtAl2008/__init__.py +0 -0
  474. tests/models/poschEtAl2008/test_terrestrialAcidificationPotentialAccumulatedExceedance.py +0 -39
  475. tests/models/poschEtAl2008/test_terrestrialEutrophicationPotentialAccumulatedExceedance.py +0 -39
  476. tests/models/recipe2016Egalitarian/__init__.py +0 -0
  477. tests/models/recipe2016Egalitarian/test_damageToFreshwaterEcosystemsSpeciesYear.py +0 -20
  478. tests/models/recipe2016Egalitarian/test_damageToHumanHealth.py +0 -20
  479. tests/models/recipe2016Egalitarian/test_damageToMarineEcosystemsSpeciesYear.py +0 -20
  480. tests/models/recipe2016Egalitarian/test_damageToResourceAvailability.py +0 -23
  481. tests/models/recipe2016Egalitarian/test_damageToTerrestrialEcosystemsSpeciesYear.py +0 -20
  482. tests/models/recipe2016Egalitarian/test_ecosystemDamageOzoneFormation.py +0 -26
  483. tests/models/recipe2016Egalitarian/test_fossilResourceScarcity.py +0 -23
  484. tests/models/recipe2016Egalitarian/test_freshwaterAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  485. tests/models/recipe2016Egalitarian/test_freshwaterEutrophicationPotential.py +0 -23
  486. tests/models/recipe2016Egalitarian/test_humanCarcinogenicToxicity.py +0 -23
  487. tests/models/recipe2016Egalitarian/test_humanDamageOzoneFormation.py +0 -26
  488. tests/models/recipe2016Egalitarian/test_humanNonCarcinogenicToxicity.py +0 -23
  489. tests/models/recipe2016Egalitarian/test_marineAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  490. tests/models/recipe2016Egalitarian/test_marineEutrophicationPotential.py +0 -23
  491. tests/models/recipe2016Egalitarian/test_ozoneDepletionPotential.py +0 -26
  492. tests/models/recipe2016Egalitarian/test_terrestrialAcidificationPotential.py +0 -23
  493. tests/models/recipe2016Egalitarian/test_terrestrialEcotoxicityPotential14Dcbeq.py +0 -23
  494. tests/models/recipe2016Hierarchist/__init__.py +0 -0
  495. tests/models/recipe2016Hierarchist/test_damageToFreshwaterEcosystemsSpeciesYear.py +0 -20
  496. tests/models/recipe2016Hierarchist/test_damageToHumanHealth.py +0 -20
  497. tests/models/recipe2016Hierarchist/test_damageToMarineEcosystemsSpeciesYear.py +0 -20
  498. tests/models/recipe2016Hierarchist/test_damageToResourceAvailability.py +0 -23
  499. tests/models/recipe2016Hierarchist/test_damageToTerrestrialEcosystemsSpeciesYear.py +0 -20
  500. tests/models/recipe2016Hierarchist/test_ecosystemDamageOzoneFormation.py +0 -26
  501. tests/models/recipe2016Hierarchist/test_fossilResourceScarcity.py +0 -23
  502. tests/models/recipe2016Hierarchist/test_freshwaterAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  503. tests/models/recipe2016Hierarchist/test_freshwaterEutrophicationPotential.py +0 -23
  504. tests/models/recipe2016Hierarchist/test_humanCarcinogenicToxicity.py +0 -23
  505. tests/models/recipe2016Hierarchist/test_humanDamageOzoneFormation.py +0 -26
  506. tests/models/recipe2016Hierarchist/test_humanNonCarcinogenicToxicity.py +0 -23
  507. tests/models/recipe2016Hierarchist/test_marineAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  508. tests/models/recipe2016Hierarchist/test_marineEutrophicationPotential.py +0 -23
  509. tests/models/recipe2016Hierarchist/test_ozoneDepletionPotential.py +0 -26
  510. tests/models/recipe2016Hierarchist/test_terrestrialAcidificationPotential.py +0 -23
  511. tests/models/recipe2016Hierarchist/test_terrestrialEcotoxicityPotential14Dcbeq.py +0 -23
  512. tests/models/recipe2016Individualist/__init__.py +0 -0
  513. tests/models/recipe2016Individualist/test_damageToFreshwaterEcosystemsSpeciesYear.py +0 -20
  514. tests/models/recipe2016Individualist/test_damageToHumanHealth.py +0 -20
  515. tests/models/recipe2016Individualist/test_damageToMarineEcosystemsSpeciesYear.py +0 -20
  516. tests/models/recipe2016Individualist/test_damageToResourceAvailability.py +0 -23
  517. tests/models/recipe2016Individualist/test_damageToTerrestrialEcosystemsSpeciesYear.py +0 -20
  518. tests/models/recipe2016Individualist/test_ecosystemDamageOzoneFormation.py +0 -26
  519. tests/models/recipe2016Individualist/test_fossilResourceScarcity.py +0 -23
  520. tests/models/recipe2016Individualist/test_freshwaterAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  521. tests/models/recipe2016Individualist/test_freshwaterEutrophicationPotential.py +0 -23
  522. tests/models/recipe2016Individualist/test_humanCarcinogenicToxicity.py +0 -23
  523. tests/models/recipe2016Individualist/test_humanDamageOzoneFormation.py +0 -26
  524. tests/models/recipe2016Individualist/test_humanNonCarcinogenicToxicity.py +0 -23
  525. tests/models/recipe2016Individualist/test_marineAquaticEcotoxicityPotential14Dcbeq.py +0 -23
  526. tests/models/recipe2016Individualist/test_marineEutrophicationPotential.py +0 -23
  527. tests/models/recipe2016Individualist/test_ozoneDepletionPotential.py +0 -26
  528. tests/models/recipe2016Individualist/test_terrestrialAcidificationPotential.py +0 -23
  529. tests/models/recipe2016Individualist/test_terrestrialEcotoxicityPotential14Dcbeq.py +0 -23
  530. tests/models/schererPfister2015/__init__.py +0 -0
  531. tests/models/schererPfister2015/test_nErosionSoilFlux.py +0 -70
  532. tests/models/schererPfister2015/test_pErosionSoilFlux.py +0 -70
  533. tests/models/schererPfister2015/test_pToDrainageWaterSoilFlux.py +0 -33
  534. tests/models/schererPfister2015/test_pToGroundwaterSoilFlux.py +0 -33
  535. tests/models/schererPfister2015/test_pToSurfaceWaterSoilFlux.py +0 -45
  536. tests/models/schmidt2007/__init__.py +0 -0
  537. tests/models/schmidt2007/test_ch4ToAirWasteTreatment.py +0 -45
  538. tests/models/schmidt2007/test_h2SToAirWasteTreatment.py +0 -45
  539. tests/models/schmidt2007/test_n2OToAirWasteTreatmentDirect.py +0 -45
  540. tests/models/schmidt2007/test_nh3ToAirWasteTreatment.py +0 -45
  541. tests/models/schmidt2007/test_utils.py +0 -39
  542. tests/models/site/__init__.py +0 -0
  543. tests/models/site/measurement/__init__.py +0 -0
  544. tests/models/site/measurement/test_value.py +0 -41
  545. tests/models/site/post_checks/__init__.py +0 -0
  546. tests/models/site/post_checks/test_cache.py +0 -8
  547. tests/models/site/post_checks/test_country.py +0 -6
  548. tests/models/site/pre_checks/__init__.py +0 -0
  549. tests/models/site/pre_checks/test_cache_geospatialDatabase.py +0 -22
  550. tests/models/site/pre_checks/test_cache_years.py +0 -25
  551. tests/models/site/pre_checks/test_country.py +0 -13
  552. tests/models/site/test_defaultMethodClassification.py +0 -24
  553. tests/models/site/test_defaultMethodClassificationDescription.py +0 -24
  554. tests/models/site/test_grouped_measurement.py +0 -20
  555. tests/models/stehfestBouwman2006/__init__.py +0 -0
  556. tests/models/stehfestBouwman2006/test_n2OToAirCropResidueDecompositionDirect.py +0 -20
  557. tests/models/stehfestBouwman2006/test_n2OToAirExcretaDirect.py +0 -20
  558. tests/models/stehfestBouwman2006/test_n2OToAirInorganicFertiliserDirect.py +0 -20
  559. tests/models/stehfestBouwman2006/test_n2OToAirOrganicFertiliserDirect.py +0 -20
  560. tests/models/stehfestBouwman2006/test_noxToAirCropResidueDecomposition.py +0 -20
  561. tests/models/stehfestBouwman2006/test_noxToAirExcreta.py +0 -20
  562. tests/models/stehfestBouwman2006/test_noxToAirInorganicFertiliser.py +0 -20
  563. tests/models/stehfestBouwman2006/test_noxToAirOrganicFertiliser.py +0 -20
  564. tests/models/stehfestBouwman2006GisImplementation/__init__.py +0 -0
  565. tests/models/stehfestBouwman2006GisImplementation/test_noxToAirCropResidueDecomposition.py +0 -22
  566. tests/models/stehfestBouwman2006GisImplementation/test_noxToAirExcreta.py +0 -20
  567. tests/models/stehfestBouwman2006GisImplementation/test_noxToAirInorganicFertiliser.py +0 -20
  568. tests/models/stehfestBouwman2006GisImplementation/test_noxToAirOrganicFertiliser.py +0 -20
  569. tests/models/test_cache_nodes.py +0 -31
  570. tests/models/test_cache_sites.py +0 -93
  571. tests/models/test_config.py +0 -170
  572. tests/models/test_emissionNotRelevant.py +0 -32
  573. tests/models/test_log.py +0 -128
  574. tests/models/test_resourceUseNotRelevant.py +0 -27
  575. tests/models/test_utils.py +0 -6
  576. tests/models/transformation/__init__.py +0 -0
  577. tests/models/transformation/input/__init__.py +0 -0
  578. tests/models/transformation/input/test_excreta.py +0 -49
  579. tests/models/transformation/input/test_max.py +0 -34
  580. tests/models/transformation/input/test_min.py +0 -34
  581. tests/models/transformation/input/test_properties.py +0 -34
  582. tests/models/transformation/input/test_sd.py +0 -34
  583. tests/models/transformation/input/test_value.py +0 -34
  584. tests/models/transformation/product/__init__.py +0 -0
  585. tests/models/transformation/product/test_excreta.py +0 -54
  586. tests/models/usetoxV2/__init__.py +0 -0
  587. tests/models/usetoxV2/test_freshwaterEcotoxicityPotentialCtue.py +0 -23
  588. tests/models/utils/__init__.py +0 -0
  589. tests/models/utils/test_array_builders.py +0 -314
  590. tests/models/utils/test_background_emissions.py +0 -13
  591. tests/models/utils/test_blank_node.py +0 -1081
  592. tests/models/utils/test_cache_sources.py +0 -21
  593. tests/models/utils/test_crop.py +0 -27
  594. tests/models/utils/test_cropResidue.py +0 -26
  595. tests/models/utils/test_cropResidueManagement.py +0 -24
  596. tests/models/utils/test_currency.py +0 -13
  597. tests/models/utils/test_dataCompleteness.py +0 -52
  598. tests/models/utils/test_ecoClimateZone.py +0 -152
  599. tests/models/utils/test_emission.py +0 -74
  600. tests/models/utils/test_feedipedia.py +0 -26
  601. tests/models/utils/test_impact_assessment.py +0 -48
  602. tests/models/utils/test_indicator.py +0 -26
  603. tests/models/utils/test_input.py +0 -88
  604. tests/models/utils/test_liveAnimal.py +0 -34
  605. tests/models/utils/test_measurement.py +0 -116
  606. tests/models/utils/test_practice.py +0 -24
  607. tests/models/utils/test_product.py +0 -73
  608. tests/models/utils/test_property.py +0 -24
  609. tests/models/utils/test_site.py +0 -70
  610. tests/models/utils/test_source.py +0 -42
  611. tests/models/utils/test_term.py +0 -115
  612. tests/models/utils/test_time_series.py +0 -88
  613. tests/models/webbEtAl2012AndSintermannEtAl2012/__init__.py +0 -0
  614. tests/models/webbEtAl2012AndSintermannEtAl2012/test_nh3ToAirOrganicFertiliser.py +0 -79
  615. tests/orchestrator/__init__.py +0 -0
  616. tests/orchestrator/models/__init__.py +0 -0
  617. tests/orchestrator/models/emissions/__init__.py +0 -0
  618. tests/orchestrator/models/emissions/test_deleted.py +0 -21
  619. tests/orchestrator/models/test_transformations.py +0 -32
  620. tests/orchestrator/strategies/__init__.py +0 -0
  621. tests/orchestrator/strategies/merge/__init__.py +0 -0
  622. tests/orchestrator/strategies/merge/test_merge_append.py +0 -33
  623. tests/orchestrator/strategies/merge/test_merge_default.py +0 -7
  624. tests/orchestrator/strategies/merge/test_merge_list.py +0 -342
  625. tests/orchestrator/strategies/merge/test_merge_node.py +0 -95
  626. tests/orchestrator/strategies/run/__init__.py +0 -0
  627. tests/orchestrator/strategies/run/test_add_blank_node_if_missing.py +0 -109
  628. tests/orchestrator/strategies/run/test_add_key_if_missing.py +0 -14
  629. tests/orchestrator/strategies/run/test_always.py +0 -5
  630. tests/orchestrator/test_models.py +0 -70
  631. tests/orchestrator/test_orchestrator.py +0 -27
  632. tests/orchestrator/test_utils.py +0 -109
  633. {hestia_earth_models-0.74.17.dist-info → hestia_earth_models-0.75.0.dist-info}/licenses/LICENSE +0 -0
@@ -1,465 +0,0 @@
1
- from itertools import product
2
- import json
3
- from numpy import array
4
- from numpy.testing import assert_array_almost_equal
5
- from pytest import mark
6
- from unittest.mock import MagicMock, patch
7
-
8
- from hestia_earth.models.utils.ecoClimateZone import EcoClimateZone
9
- from hestia_earth.models.ipcc2019.organicCarbonPerHa import MODEL, TERM_ID
10
- from hestia_earth.models.ipcc2019.organicCarbonPerHa_utils import (
11
- IpccCarbonInputCategory, IpccLandUseCategory, IpccManagementCategory, IpccSoilCategory, sample_constant,
12
- sample_plus_minus_error, sample_plus_minus_uncertainty
13
- )
14
- from hestia_earth.models.ipcc2019.organicCarbonPerHa_tier_1 import (
15
- _assign_ipcc_carbon_input_category, _assign_ipcc_land_use_category, _assign_ipcc_management_category,
16
- _assign_ipcc_soil_category, _calc_missing_equilibrium_years, _calc_regime_start_years, _calc_soc_stocks,
17
- _check_cropland_low_category, _check_cropland_medium_category, _get_carbon_input_kwargs, _get_sample_func,
18
- _get_soc_ref_preview, _InventoryKey, _sample_parameter, _EXCLUDED_ECO_CLIMATE_ZONES
19
- )
20
-
21
- from tests.utils import fixtures_path
22
-
23
- class_path = f"hestia_earth.models.{MODEL}.{TERM_ID}_tier_1"
24
- utils_path = f"hestia_earth.models.{MODEL}.{TERM_ID}_utils"
25
- term_path = "hestia_earth.models.utils.term"
26
- property_path = "hestia_earth.models.utils.property"
27
-
28
- fixtures_folder = f"{fixtures_path}/{MODEL}/{TERM_ID}"
29
-
30
- ITERATIONS = 1000
31
-
32
- COVER_CROP_PROPERTY_TERM_IDS = [
33
- "catchCrop",
34
- "coverCrop",
35
- "groundCover",
36
- "longFallowCrop",
37
- "shortFallowCrop"
38
- ]
39
-
40
- IRRIGATED_TERM_IDS = [
41
- "rainfedDeepWater",
42
- "rainfedDeepWaterWaterDepth100Cm",
43
- "rainfedDeepWaterWaterDepth50100Cm",
44
- "irrigatedTypeUnspecified",
45
- "irrigatedCenterPivotIrrigation",
46
- "irrigatedContinuouslyFlooded",
47
- "irrigatedDripIrrigation",
48
- "irrigatedFurrowIrrigation",
49
- "irrigatedLateralMoveIrrigation",
50
- "irrigatedLocalizedIrrigation",
51
- "irrigatedManualIrrigation",
52
- "irrigatedSurfaceIrrigationMultipleDrainagePeriods",
53
- "irrigatedSurfaceIrrigationSingleDrainagePeriod",
54
- "irrigatedSprinklerIrrigation",
55
- "irrigatedSubIrrigation",
56
- "irrigatedSurfaceIrrigationDrainageRegimeUnspecified"
57
- ]
58
-
59
- RESIDUE_REMOVED_OR_BURNT_TERM_IDS = [
60
- "residueBurnt",
61
- "residueRemoved"
62
- ]
63
-
64
- UPLAND_RICE_LAND_COVER_TERM_IDS = [
65
- "ricePlantUpland"
66
- ]
67
-
68
-
69
- # kwargs, sample_func, expected_shape
70
- PARAMS_GET_SAMPLE_FUNC = [
71
- ({"value": 1}, sample_constant),
72
- ({"value": 1, "error": 10}, sample_plus_minus_error),
73
- ({"value": 1, "uncertainty": 10}, sample_plus_minus_uncertainty)
74
- ]
75
- IDS_GET_SAMPLE_FUNC = ["constant", "+/- error", "+/- uncertainty"]
76
-
77
-
78
- @mark.parametrize("kwargs, sample_func", PARAMS_GET_SAMPLE_FUNC, ids=IDS_GET_SAMPLE_FUNC)
79
- def test_get_sample_func(kwargs, sample_func):
80
- result = _get_sample_func(kwargs)
81
- assert result == sample_func
82
-
83
-
84
- SOC_REF_PARAMS = [p for p in product(IpccSoilCategory, EcoClimateZone) if _get_soc_ref_preview(*p)]
85
- FACTOR_PARAMS = list(product(
86
- [c for c in IpccLandUseCategory] + [c for c in IpccManagementCategory] + [c for c in IpccCarbonInputCategory],
87
- [e for e in EcoClimateZone if e not in _EXCLUDED_ECO_CLIMATE_ZONES]
88
- ))
89
-
90
- # ipcc_category, eco_climate_zone
91
- PARAMS_SAMPLE_PARAMETER = SOC_REF_PARAMS + FACTOR_PARAMS
92
- IDS_SAMPLE_PARAMETER = [f"{p[0]} + {p[1].name}" for p in PARAMS_SAMPLE_PARAMETER]
93
-
94
-
95
- @mark.parametrize("ipcc_category, eco_climate_zone", PARAMS_SAMPLE_PARAMETER, ids=IDS_SAMPLE_PARAMETER)
96
- def test_sample_parameter(ipcc_category, eco_climate_zone):
97
- """
98
- Check that every combination of parameter and eco_climate_zone can be sampled without raising an error.
99
- """
100
- EXPECTED_SHAPE = (1, ITERATIONS)
101
- result = _sample_parameter(ITERATIONS, ipcc_category, eco_climate_zone)
102
- assert result.shape == EXPECTED_SHAPE
103
-
104
-
105
- # subfolder, expected
106
- SOIL_CATEGORY_PARAMS = [
107
- ("fractional", IpccSoilCategory.WETLAND_SOILS),
108
- ("no-measurements", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS),
109
- ("sandy-override", IpccSoilCategory.SANDY_SOILS),
110
- ("soilType/hac", IpccSoilCategory.HIGH_ACTIVITY_CLAY_SOILS),
111
- ("soilType/lac", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS),
112
- ("soilType/org", IpccSoilCategory.ORGANIC_SOILS),
113
- ("soilType/pod", IpccSoilCategory.SPODIC_SOILS),
114
- ("soilType/san", IpccSoilCategory.SANDY_SOILS),
115
- ("soilType/vol", IpccSoilCategory.VOLCANIC_SOILS),
116
- ("soilType/wet", IpccSoilCategory.WETLAND_SOILS),
117
- ("usdaSoilType/hac", IpccSoilCategory.HIGH_ACTIVITY_CLAY_SOILS),
118
- ("usdaSoilType/lac", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS),
119
- ("usdaSoilType/org", IpccSoilCategory.ORGANIC_SOILS),
120
- ("usdaSoilType/pod", IpccSoilCategory.SPODIC_SOILS),
121
- ("usdaSoilType/san", IpccSoilCategory.SANDY_SOILS),
122
- ("usdaSoilType/vol", IpccSoilCategory.VOLCANIC_SOILS),
123
- ("usdaSoilType/wet", IpccSoilCategory.WETLAND_SOILS),
124
- ("with-depths", IpccSoilCategory.HIGH_ACTIVITY_CLAY_SOILS) # Closes #1248
125
- ]
126
-
127
-
128
- @mark.parametrize(
129
- "subfolder, expected",
130
- SOIL_CATEGORY_PARAMS,
131
- ids=[params[0] for params in SOIL_CATEGORY_PARAMS]
132
- )
133
- def test_assign_ipcc_soil_category(subfolder: str, expected: IpccSoilCategory):
134
- folder = f"{fixtures_folder}/IpccSoilCategory/{subfolder}"
135
-
136
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
137
- site = json.load(f)
138
-
139
- result, *_ = _assign_ipcc_soil_category(site.get("measurements", []))
140
- assert result == expected
141
-
142
-
143
- # subfolder, soil_category, expected
144
- LAND_USE_CATEGORY_PARAMS = [
145
- ("annual-crops", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.ANNUAL_CROPS),
146
- ("annual-crops-wet", IpccSoilCategory.WETLAND_SOILS, IpccLandUseCategory.ANNUAL_CROPS_WET),
147
- ("forest", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.FOREST),
148
- ("fractional", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.PERENNIAL_CROPS),
149
- ("grassland", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.GRASSLAND),
150
- ("irrigated-upland-rice", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.PADDY_RICE_CULTIVATION),
151
- ("native", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.NATIVE),
152
- ("other", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.OTHER),
153
- ("paddy-rice-cultivation", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.PADDY_RICE_CULTIVATION),
154
- ("perennial-crops", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.PERENNIAL_CROPS),
155
- ("set-aside", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.SET_ASIDE),
156
- ("set-aside-override", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.SET_ASIDE),
157
- ("upland-rice", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.ANNUAL_CROPS),
158
- ("unknown", IpccSoilCategory.LOW_ACTIVITY_CLAY_SOILS, IpccLandUseCategory.UNKNOWN)
159
- ]
160
-
161
-
162
- @mark.parametrize(
163
- "subfolder, soil_category, expected",
164
- LAND_USE_CATEGORY_PARAMS,
165
- ids=[params[0] for params in LAND_USE_CATEGORY_PARAMS]
166
- )
167
- @patch(f"{class_path}.get_upland_rice_land_cover_terms", return_value=UPLAND_RICE_LAND_COVER_TERM_IDS)
168
- @patch(f"{utils_path}.get_irrigated_terms", return_value=IRRIGATED_TERM_IDS)
169
- @patch(f"{utils_path}.get_cover_crop_property_terms", return_value=COVER_CROP_PROPERTY_TERM_IDS)
170
- @patch(f"{term_path}.search")
171
- def test_assign_ipcc_land_use_category(
172
- search_mock: MagicMock,
173
- _get_cover_crop_property_terms_mock: MagicMock,
174
- _get_irrigated_terms_mock: MagicMock,
175
- _get_upland_rice_land_cover_terms_mock: MagicMock,
176
- subfolder: str,
177
- soil_category: IpccSoilCategory,
178
- expected: IpccLandUseCategory
179
- ):
180
- folder = f"{fixtures_folder}/IpccLandUseCategory/{subfolder}"
181
-
182
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
183
- site = json.load(f)
184
-
185
- result = _assign_ipcc_land_use_category(site.get("management", []), soil_category)
186
- assert result == expected
187
-
188
- search_mock.assert_not_called() # Ensure that the term utils are properly mocked.
189
-
190
-
191
- # subfolder, land_use_category, expected
192
- MANAGEMENT_CATEGORY_PARAMS = [
193
- ("fractional-annual-crops", IpccLandUseCategory.ANNUAL_CROPS, IpccManagementCategory.REDUCED_TILLAGE),
194
- ("fractional-annual-crops-wet", IpccLandUseCategory.ANNUAL_CROPS_WET, IpccManagementCategory.REDUCED_TILLAGE),
195
- ("fractional-grassland", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.IMPROVED_GRASSLAND),
196
- ("full-tillage", IpccLandUseCategory.ANNUAL_CROPS, IpccManagementCategory.FULL_TILLAGE),
197
- ("high-intensity-grazing", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.HIGH_INTENSITY_GRAZING),
198
- ("improved-grassland", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.IMPROVED_GRASSLAND),
199
- ("no-tillage", IpccLandUseCategory.ANNUAL_CROPS, IpccManagementCategory.NO_TILLAGE),
200
- ("nominally-managed/native-pasture", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.NOMINALLY_MANAGED),
201
- (
202
- "nominally-managed/nominally-managed-pasture",
203
- IpccLandUseCategory.GRASSLAND,
204
- IpccManagementCategory.NOMINALLY_MANAGED
205
- ),
206
- ("not-relevant", IpccLandUseCategory.OTHER, IpccManagementCategory.NOT_RELEVANT),
207
- ("reduced-tillage", IpccLandUseCategory.ANNUAL_CROPS, IpccManagementCategory.REDUCED_TILLAGE),
208
- ("severely-degraded", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.SEVERELY_DEGRADED),
209
- ("unknown/annual-crops", IpccLandUseCategory.ANNUAL_CROPS, IpccManagementCategory.UNKNOWN),
210
- ("unknown/annual-crops-wet", IpccLandUseCategory.ANNUAL_CROPS_WET, IpccManagementCategory.UNKNOWN),
211
- ("unknown/grassland", IpccLandUseCategory.GRASSLAND, IpccManagementCategory.UNKNOWN)
212
- ]
213
-
214
-
215
- @mark.parametrize(
216
- "subfolder, land_use_category, expected",
217
- MANAGEMENT_CATEGORY_PARAMS,
218
- ids=[params[0] for params in MANAGEMENT_CATEGORY_PARAMS]
219
- )
220
- def test_assign_ipcc_management_category(
221
- subfolder: str, land_use_category: IpccLandUseCategory, expected: IpccManagementCategory
222
- ):
223
- folder = f"{fixtures_folder}/IpccManagementCategory/{subfolder}"
224
-
225
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
226
- site = json.load(f)
227
-
228
- result = _assign_ipcc_management_category(site.get("management", []), land_use_category)
229
- assert result == expected
230
-
231
-
232
- @mark.parametrize("key", [1, 2, 3, 4], ids=lambda key: f"scenario-{key}")
233
- @patch(f"{class_path}.get_residue_removed_or_burnt_terms", return_value=RESIDUE_REMOVED_OR_BURNT_TERM_IDS)
234
- @patch(f"{utils_path}.get_irrigated_terms", return_value=IRRIGATED_TERM_IDS)
235
- @patch(f"{utils_path}.get_cover_crop_property_terms", return_value=COVER_CROP_PROPERTY_TERM_IDS)
236
- @patch(f"{term_path}.search")
237
- def test_check_cropland_medium_category(
238
- search_mock: MagicMock,
239
- _get_cover_crop_property_terms_mock: MagicMock,
240
- _get_irrigated_terms_mock: MagicMock,
241
- _get_residue_removed_or_burnt_terms_mock: MagicMock,
242
- key: int
243
- ):
244
- """
245
- Tests each set of cropland medium conditions against a list of nodes that such satisfy it. The function returns the
246
- key of the matching condition set, which should match the suffix of the fixtures subfolder.
247
- """
248
- folder = f"{fixtures_folder}/IpccCarbonInputCategory/cropland-medium/scenario-{key}"
249
-
250
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
251
- site = json.load(f)
252
-
253
- result = _check_cropland_medium_category(**_get_carbon_input_kwargs(site.get("management", [])))
254
- assert result == key
255
-
256
- search_mock.assert_not_called() # Ensure that the term utils are properly mocked.
257
-
258
-
259
- @mark.parametrize("key", [1, 2, 3], ids=lambda key: f"scenario-{key}")
260
- @patch(f"{class_path}.get_residue_removed_or_burnt_terms", return_value=RESIDUE_REMOVED_OR_BURNT_TERM_IDS)
261
- @patch(f"{utils_path}.get_irrigated_terms", return_value=IRRIGATED_TERM_IDS)
262
- @patch(f"{utils_path}.get_cover_crop_property_terms", return_value=COVER_CROP_PROPERTY_TERM_IDS)
263
- @patch(f"{term_path}.search")
264
- def test_check_cropland_low_category(
265
- search_mock: MagicMock,
266
- _get_cover_crop_property_terms_mock: MagicMock,
267
- _get_irrigated_terms_mock: MagicMock,
268
- _get_residue_removed_or_burnt_terms_mock: MagicMock,
269
- key: int
270
- ):
271
- """
272
- Tests each set of cropland low conditions against a list of nodes that such satisfy it. The function returns the
273
- key of the matching condition set, which should match the suffix of the fixtures subfolder.
274
- """
275
- folder = f"{fixtures_folder}/IpccCarbonInputCategory/cropland-low/scenario-{key}"
276
-
277
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
278
- site = json.load(f)
279
-
280
- result = _check_cropland_low_category(**_get_carbon_input_kwargs(site.get("management", [])))
281
- assert result == key
282
-
283
- search_mock.assert_not_called() # Ensure that the term utils are properly mocked.
284
-
285
-
286
- # subfolder, management_category, expected
287
- CARBON_INPUT_CATEGORY_PARAMS = [
288
- (
289
- "cropland-high-with-manure",
290
- IpccManagementCategory.FULL_TILLAGE,
291
- IpccCarbonInputCategory.CROPLAND_HIGH_WITH_MANURE
292
- ),
293
- (
294
- "cropland-high-without-manure/organic-fertiliser", # Closes issue 743
295
- IpccManagementCategory.FULL_TILLAGE,
296
- IpccCarbonInputCategory.CROPLAND_HIGH_WITHOUT_MANURE
297
- ),
298
- (
299
- "cropland-high-without-manure/soil-amendment", # Closes issue 743
300
- IpccManagementCategory.FULL_TILLAGE,
301
- IpccCarbonInputCategory.CROPLAND_HIGH_WITHOUT_MANURE
302
- ),
303
- ("cropland-low/scenario-1", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_LOW),
304
- ("cropland-low/scenario-2", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_LOW),
305
- ("cropland-low/scenario-3", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_LOW),
306
- ("cropland-medium/scenario-1", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_MEDIUM),
307
- ("cropland-medium/scenario-2", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_MEDIUM),
308
- ("cropland-medium/scenario-3", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_MEDIUM),
309
- ("cropland-medium/scenario-4", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.CROPLAND_MEDIUM),
310
- ("grassland-high", IpccManagementCategory.IMPROVED_GRASSLAND, IpccCarbonInputCategory.GRASSLAND_HIGH),
311
- (
312
- "grassland-medium/0-improvements",
313
- IpccManagementCategory.IMPROVED_GRASSLAND,
314
- IpccCarbonInputCategory.GRASSLAND_MEDIUM
315
- ),
316
- (
317
- "grassland-medium/1-improvements",
318
- IpccManagementCategory.IMPROVED_GRASSLAND,
319
- IpccCarbonInputCategory.GRASSLAND_MEDIUM
320
- ),
321
- ("not-relevant", IpccManagementCategory.NOT_RELEVANT, IpccCarbonInputCategory.NOT_RELEVANT),
322
- ("unknown/cropland", IpccManagementCategory.FULL_TILLAGE, IpccCarbonInputCategory.UNKNOWN),
323
- ("unknown/grassland", IpccManagementCategory.IMPROVED_GRASSLAND, IpccCarbonInputCategory.UNKNOWN)
324
- ]
325
-
326
-
327
- @mark.parametrize(
328
- "subfolder, management_category, expected",
329
- CARBON_INPUT_CATEGORY_PARAMS,
330
- ids=[params[0] for params in CARBON_INPUT_CATEGORY_PARAMS]
331
- )
332
- @patch(f"{class_path}.get_residue_removed_or_burnt_terms", return_value=RESIDUE_REMOVED_OR_BURNT_TERM_IDS)
333
- @patch(f"{utils_path}.get_irrigated_terms", return_value=IRRIGATED_TERM_IDS)
334
- @patch(f"{utils_path}.get_cover_crop_property_terms", return_value=COVER_CROP_PROPERTY_TERM_IDS)
335
- @patch(f"{term_path}.search")
336
- def test_assign_ipcc_carbon_input_category(
337
- search_mock: MagicMock,
338
- _get_cover_crop_property_terms_mock: MagicMock,
339
- _get_irrigated_terms_mock: MagicMock,
340
- _get_residue_removed_or_burnt_terms_mock: MagicMock,
341
- subfolder: str,
342
- management_category: IpccManagementCategory,
343
- expected: IpccCarbonInputCategory
344
- ):
345
- folder = f"{fixtures_folder}/IpccCarbonInputCategory/{subfolder}"
346
-
347
- with open(f"{folder}/site.jsonld", encoding='utf-8') as f:
348
- site = json.load(f)
349
-
350
- result = _assign_ipcc_carbon_input_category(site.get("management", []), management_category)
351
- assert result == expected
352
-
353
- search_mock.assert_not_called() # Ensure that the term utils are properly mocked.
354
-
355
-
356
- TIMESTAMPS_CALC_SOC_STOCK = [1990, 1995, 2000, 2005, 2010, 2015, 2020]
357
-
358
- # regime_start_years, soc_equilibriums, expected
359
- PARAMS_CALC_SOC_STOCK = [
360
- (
361
- [1970, 1995, 1995, 1995, 1995, 1995, 1995],
362
- array([[77.000], [70.840], [70.840], [70.840], [70.840], [70.840], [70.840]]),
363
- array([[77.000], [75.460], [73.920], [72.380], [70.840], [70.840], [70.840]])
364
- ),
365
- (
366
- [1970, 1995, 1995, 1995, 2010, 2010, 2010],
367
- array([[77.000], [70.840], [70.840], [70.840], [80.850], [80.850], [80.850]]),
368
- array([[77.000], [75.460], [73.920], [72.380], [74.498], [76.615], [78.733]])
369
- ),
370
- (
371
- [1970, 1995, 1995, 1995, 1995, 2015, 2015],
372
- array([[80.850], [70.840], [70.840], [70.840], [70.840], [80.850], [80.850]]),
373
- array([[80.850], [78.348], [75.845], [73.343], [70.840], [73.343], [75.845]])
374
- ),
375
- (
376
- [1970, 1970, 2000, 2000, 2000, 2000, 2000],
377
- array([[80.850], [80.850], [77.000], [77.000], [77.000], [77.000], [77.000]]),
378
- array([[80.850], [80.850], [79.888], [78.925], [77.963], [77.000], [77.000]])
379
- ),
380
- (
381
- [1970, 1970, 1970, 1970, 2010, 2010, 2010],
382
- array([[70.840], [70.840], [70.840], [70.840], [80.850], [80.850], [80.850]]),
383
- array([[70.840], [70.840], [70.840], [70.840], [73.343], [75.845], [78.348]])
384
- ),
385
- (
386
- [1970, 1970, 2000, 2000, 2000, 2015, 2020],
387
- array([[70.840], [70.840], [80.850], [80.850], [80.850], [70.840], [80.850]]),
388
- array([[70.840], [70.840], [73.343], [75.845], [78.348], [76.471], [77.565]])
389
- )
390
- ]
391
- IDS_CALC_SOC_STOCK = [f"land-unit-{i+1}" for i in range(len(PARAMS_CALC_SOC_STOCK))]
392
-
393
-
394
- @mark.parametrize("regime_start_years, soc_equilibriums, expected", PARAMS_CALC_SOC_STOCK, ids=IDS_CALC_SOC_STOCK)
395
- def test_calc_soc_stocks(regime_start_years, soc_equilibriums, expected):
396
- """
397
- Test the interpolation between SOC equilibriums using test data provided in IPCC (2019).
398
- """
399
- result = _calc_soc_stocks(
400
- TIMESTAMPS_CALC_SOC_STOCK, regime_start_years, soc_equilibriums
401
- )
402
- assert_array_almost_equal(result, expected, decimal=3)
403
-
404
-
405
- TEST_INVENTORY = {
406
- 1960: {
407
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.FOREST,
408
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.NOT_RELEVANT,
409
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.NOT_RELEVANT
410
- },
411
- 1965: {
412
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.FOREST,
413
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.NOT_RELEVANT,
414
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.NOT_RELEVANT
415
- },
416
- 1970: {
417
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.GRASSLAND,
418
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.NOMINALLY_MANAGED,
419
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.NOT_RELEVANT
420
- },
421
- 1995: {
422
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.ANNUAL_CROPS,
423
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.FULL_TILLAGE,
424
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.CROPLAND_LOW
425
- },
426
- 2003: {
427
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.ANNUAL_CROPS,
428
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.FULL_TILLAGE,
429
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.CROPLAND_MEDIUM
430
- },
431
- 2025: {
432
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.ANNUAL_CROPS,
433
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.FULL_TILLAGE,
434
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.CROPLAND_MEDIUM
435
- },
436
- 2026: {
437
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.ANNUAL_CROPS,
438
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.REDUCED_TILLAGE,
439
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.CROPLAND_MEDIUM
440
- }
441
- }
442
-
443
- EXPECTED_MISSING_YEARS = {
444
- 1990: {
445
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.GRASSLAND,
446
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.NOMINALLY_MANAGED,
447
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.NOT_RELEVANT
448
- },
449
- 2023: {
450
- _InventoryKey.LU_CATEGORY: IpccLandUseCategory.ANNUAL_CROPS,
451
- _InventoryKey.MG_CATEGORY: IpccManagementCategory.FULL_TILLAGE,
452
- _InventoryKey.CI_CATEGORY: IpccCarbonInputCategory.CROPLAND_MEDIUM
453
- }
454
- }
455
-
456
-
457
- def test_calc_missing_equilibrium_years():
458
- result = _calc_missing_equilibrium_years(TEST_INVENTORY)
459
- assert result == EXPECTED_MISSING_YEARS
460
-
461
-
462
- def test_calc_regime_start_years():
463
- EXPECTED = [1940, 1940, 1970, 1995, 2003, 2003, 2026]
464
- result = _calc_regime_start_years(TEST_INVENTORY)
465
- assert result == EXPECTED
@@ -1,148 +0,0 @@
1
- from numpy import array
2
- from numpy.testing import assert_array_almost_equal
3
- from numpy.typing import NDArray
4
- from pytest import mark
5
-
6
- from hestia_earth.utils.stats import discrete_uniform_2d, repeat_single
7
-
8
- from hestia_earth.models.ipcc2019.organicCarbonPerHa import MODEL, TERM_ID
9
- from hestia_earth.models.ipcc2019.organicCarbonPerHa_tier_2 import (
10
- _calc_temperature_factor_annual, _calc_water_factor_annual, _Parameter, _sample_parameter
11
- )
12
-
13
- from tests.utils import fixtures_path
14
-
15
- class_path = f"hestia_earth.models.{MODEL}.{TERM_ID}_tier_2"
16
- utils_path = f"hestia_earth.models.{MODEL}.{TERM_ID}_utils"
17
- term_path = "hestia_earth.models.utils.term"
18
- property_path = "hestia_earth.models.utils.property"
19
-
20
- fixtures_folder = f"{fixtures_path}/{MODEL}/{TERM_ID}"
21
-
22
- ITERATIONS = 1000
23
- SEED = 0
24
- YEARS = 100
25
- MONTHS = 12
26
-
27
-
28
- def assert_elements_between(arr: NDArray, min: float, max: float):
29
- assert ((min <= arr) & (arr <= max)).all()
30
-
31
-
32
- def assert_rows_unique(arr: NDArray):
33
- """
34
- Covert array to a set to remove repeated rows and check that number remaining rows is the same as the number of
35
- original rows.
36
- """
37
- assert len(set(map(tuple, arr))) == len(arr)
38
-
39
-
40
- PARAMS_SAMPLE_PARAMETER = [p for p in _Parameter]
41
- IDS_SAMPLE_PARAMETER = [p.name for p in _Parameter]
42
-
43
-
44
- @mark.parametrize("parameter", PARAMS_SAMPLE_PARAMETER, ids=IDS_SAMPLE_PARAMETER)
45
- def test_sample_parameter(parameter):
46
- """
47
- Check that every parameter can be sampled without raising an error.
48
- """
49
- EXPECTED_SHAPE = (1, ITERATIONS)
50
- result = _sample_parameter(ITERATIONS, parameter)
51
- assert result.shape == EXPECTED_SHAPE
52
-
53
-
54
- # temperature_monthly, expected
55
- PARAMS_TEMPERATURE_FACTOR = [
56
- (array([[-100] for _ in range(12)]), array([[1.4946486e-27]])),
57
- (array([[0] for _ in range(12)]), array([[0.0803555]])),
58
- (array([[33.69] for _ in range(12)]), array([[1]])),
59
- (array([[45] for _ in range(12)]), array([[0]])),
60
- (array([[50] for _ in range(12)]), array([[0]])),
61
- (
62
- array([
63
- [22.71129032258065], [20.310714285714287], [19.479032258064514],
64
- [14.993333333333334], [11.206451612903225], [9.055],
65
- [8.008064516129034], [11.254838709677419], [11.276666666666666],
66
- [14.148387096774192], [19.980000000000004], [16.372580645161293]
67
- ]),
68
- array([[0.4904241436936742]])
69
- )
70
- ]
71
- IDS_TEMPERATURE_FACTOR = ["-100", "0", "33.69", "45", "50", "ipcc"]
72
-
73
-
74
- @mark.parametrize("temperature_monthly, expected", PARAMS_TEMPERATURE_FACTOR, ids=IDS_TEMPERATURE_FACTOR)
75
- def test_calc_annual_temperature_factors(temperature_monthly, expected):
76
- result = _calc_temperature_factor_annual(temperature_monthly)
77
- assert_array_almost_equal(result, expected)
78
-
79
-
80
- def test_calc_annual_temperature_factors_random():
81
- SHAPE = (YEARS * MONTHS, ITERATIONS)
82
- MIN, MAX = 0, 1
83
-
84
- TEMPERATURE_MONTHLY = discrete_uniform_2d(SHAPE, -60, 60, seed=SEED)
85
-
86
- result = _calc_temperature_factor_annual(TEMPERATURE_MONTHLY)
87
-
88
- assert_elements_between(result, MIN, MAX)
89
- assert_rows_unique(result)
90
- assert result.shape == (YEARS, ITERATIONS)
91
-
92
-
93
- # precipitation_monthly, pet_monthly, expected
94
- PARAMS_WATER_FACTOR = [
95
- (array([[0] for _ in range(12)]), array([[0] for _ in range(12)]), array([[2.24942813]])), # Closes issue 771
96
- (array([[1] for _ in range(12)]), array([[10000] for _ in range(12)]), array([[0.3195496]])),
97
- (array([[10000] for _ in range(12)]), array([[1] for _ in range(12)]), array([[2.24942813]])),
98
- (
99
- array([
100
- [4.8], [23.900000000000002], [24.7],
101
- [3.5999999999999996], [11.3], [11.200000000000001],
102
- [27.400000000000006], [53], [30.7],
103
- [39.3], [9.399999999999999], [41.8]
104
- ]),
105
- array([
106
- [253.80000000000007], [214.4], [176.59999999999994],
107
- [104.19999999999997], [62.79999999999997], [41.59999999999999],
108
- [45.60000000000001], [64.80000000000001], [91.60000000000001],
109
- [140.00000000000006], [189.99999999999994], [233.00000000000006]
110
- ]),
111
- array([[0.7793321739983536]])
112
- )
113
- ]
114
- IDS_WATER_FACTOR = ["0/0", "1/10000", "10000/1", "ipcc"]
115
-
116
-
117
- @mark.parametrize("precipitation_monthly, pet_monthly, expected", PARAMS_WATER_FACTOR, ids=IDS_WATER_FACTOR)
118
- def test_calc_calc_annual_water_factors(precipitation_monthly, pet_monthly, expected):
119
- result = _calc_water_factor_annual(precipitation_monthly, pet_monthly)
120
- assert_array_almost_equal(result, expected)
121
-
122
-
123
- def test_calc_calc_annual_water_factors_random():
124
- SHAPE = (YEARS * MONTHS, ITERATIONS)
125
- MIN, MAX = 0.31935, 2.24942813
126
-
127
- PRECIPITATION_MONTHLY = discrete_uniform_2d(SHAPE, 0, 1000, seed=SEED)
128
- PET_MONTHLY = discrete_uniform_2d(SHAPE, 0, 2500, seed=SEED+1)
129
-
130
- result = _calc_water_factor_annual(PRECIPITATION_MONTHLY, PET_MONTHLY)
131
-
132
- assert_elements_between(result, MIN, MAX)
133
- assert_rows_unique(result)
134
- assert result.shape == (YEARS, ITERATIONS)
135
-
136
-
137
- def test_calc_calc_annual_water_factors_irrigated():
138
- EXPECTED = 0.775 * 1.5
139
-
140
- SHAPE = (YEARS * MONTHS, ITERATIONS)
141
- PRECIPITATION_MONTHLY = discrete_uniform_2d(SHAPE, 0, 1000, seed=SEED)
142
- PET_MONTHLY = discrete_uniform_2d(SHAPE, 0, 2500, seed=SEED+1)
143
- IRRIGATED_MONTHLY = repeat_single(SHAPE, True)
144
-
145
- result = _calc_water_factor_annual(PRECIPITATION_MONTHLY, PET_MONTHLY, IRRIGATED_MONTHLY)
146
-
147
- (result == EXPECTED).all() # assert all elements in result are the expected value
148
- assert result.shape == (YEARS, ITERATIONS)
@@ -1,31 +0,0 @@
1
- from pytest import mark
2
-
3
- from hestia_earth.models.ipcc2019.organicCarbonPerHa_utils import format_bool_list, format_float_list
4
-
5
-
6
- @mark.parametrize(
7
- "value, expected",
8
- [
9
- ([True, True, False], "True True False"),
10
- ([], "None"),
11
- (["Yes", "No", ""], "None None None"),
12
- (None, "None")
13
- ],
14
- ids=["list", "empty list", "list[str]", "None"]
15
- )
16
- def test_format_bool_list(value, expected):
17
- assert format_bool_list(value) == expected
18
-
19
-
20
- @mark.parametrize(
21
- "value, expected",
22
- [
23
- ([3.14, 31.4, 314], "3.1 31.4 314"),
24
- ([], "None"),
25
- (["Yes", "No", ""], "None None None"),
26
- (None, "None")
27
- ],
28
- ids=["list", "empty list", "list[str]", "None"]
29
- )
30
- def test_format_number_list(value, expected):
31
- assert format_float_list(value) == expected