Skip to content

aeromaps.models.sustainability_assessment.climate.comparison

comparison

This module contains classes to compute the share of carbon budget and temperature target consumed by aviation.

CarbonBudgetConsumedShare

CarbonBudgetConsumedShare(name='carbon_budget_consumed_share', *args, **kwargs)

Bases: AeroMAPSModel

This class computes the share of carbon budget consumed by aviation.

Parameters:

Name Type Description Default
name str

Name of the model instance ('carbon_budget_consumed_share' by default).

'carbon_budget_consumed_share'
Source code in aeromaps/models/sustainability_assessment/climate/comparison.py
20
21
def __init__(self, name="carbon_budget_consumed_share", *args, **kwargs):
    super().__init__(name=name, *args, **kwargs)

compute

compute(cumulative_co2_emissions, gross_carbon_budget_2050)

Carbon budget consumption share calculation.

Parameters:

Name Type Description Default
cumulative_co2_emissions Series

Cumulative CO2 emissions from aviation over time [GtCO2].

required
gross_carbon_budget_2050 float

Gross carbon budget allocated to aviation over 2020-2050 [GtCO2].

required

Returns:

Name Type Description
carbon_budget_consumed_share float

Share of carbon budget consumed by aviation up to 2050 (%).

Source code in aeromaps/models/sustainability_assessment/climate/comparison.py
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
def compute(
    self,
    cumulative_co2_emissions: pd.Series,
    gross_carbon_budget_2050: float,
) -> float:
    """
    Carbon budget consumption share calculation.

    Parameters
    ----------
    cumulative_co2_emissions : pd.Series
        Cumulative CO2 emissions from aviation over time [GtCO2].
    gross_carbon_budget_2050 : float
        Gross carbon budget allocated to aviation over 2020-2050 [GtCO2].

    Returns
    -------
    carbon_budget_consumed_share : float
        Share of carbon budget consumed by aviation up to 2050 (%).
    """

    year = 2050
    if self.end_year < 2050:
        warnings.warn("End year is before 2050, carbon budget consumed share may be underestimated.")
        year = self.end_year
    # TODO: handle case where prospection_start_year used in cumulative_co2_emissions differs from 2020.

    carbon_budget_consumed_share = (
        cumulative_co2_emissions.loc[year] / gross_carbon_budget_2050 * 100
    )

    self.float_outputs["carbon_budget_consumed_share"] = carbon_budget_consumed_share

    return carbon_budget_consumed_share

TemperatureTargetConsumedShare

TemperatureTargetConsumedShare(name='temperature_target_consumed_share', *args, **kwargs)

Bases: AeroMAPSModel

This class computes the share of temperature target consumed by aviation.

Parameters:

Name Type Description Default
name str

Name of the model instance ('temperature_target_consumed_share' by default).

'temperature_target_consumed_share'
Source code in aeromaps/models/sustainability_assessment/climate/comparison.py
68
69
def __init__(self, name="temperature_target_consumed_share", *args, **kwargs):
    super().__init__(name=name, *args, **kwargs)

compute

compute(historical_temperature_increase, temperature_target, temperature_increase_from_aviation)

Temperature target consumption share calculation.

Parameters:

Name Type Description Default
historical_temperature_increase float

Historical temperature increase before prospection_start_year (°C).

required
temperature_target float

Global temperature target (°C) at end year of simulation.

required
temperature_increase_from_aviation Series

Temperature increase from aviation over time (°C).

required

Returns:

Name Type Description
temperature_target_consumed_share float

Share of temperature target consumed by aviation up to end year (%).

Source code in aeromaps/models/sustainability_assessment/climate/comparison.py
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
def compute(
    self,
    historical_temperature_increase: float,
    temperature_target: float,
    temperature_increase_from_aviation: pd.Series,
) -> float:
    """
    Temperature target consumption share calculation.

    Parameters
    ----------
    historical_temperature_increase : float
        Historical temperature increase before prospection_start_year (°C).
    temperature_target : float
        Global temperature target (°C) at end year of simulation.
    temperature_increase_from_aviation : pd.Series
        Temperature increase from aviation over time (°C).

    Returns
    -------
    temperature_target_consumed_share : float
        Share of temperature target consumed by aviation up to end year (%).
    """

    temperature_target_consumed_share = (
        (temperature_increase_from_aviation.loc[self.end_year] -
        temperature_increase_from_aviation.loc[self.prospection_start_year]) / (
                     temperature_target - historical_temperature_increase) * 100
         )

    self.float_outputs["temperature_target_consumed_share"] = temperature_target_consumed_share

    return temperature_target_consumed_share