diff --git a/doc/whatsnew.rst b/doc/whatsnew.rst index fb9df4aec..3ff5e28a7 100644 --- a/doc/whatsnew.rst +++ b/doc/whatsnew.rst @@ -64,6 +64,7 @@ Investment and fixed costs - Add `cooling` technology variant/module (:pull:`222`). - Add functionality to specify cost reduction values and cost reduction scenarios in a module (:issue:`251`, :pull:`255`). - Fix technology mapping of ammonia CCS technologies in materials module (:pull:`258`). +- Remove unused `technology_type` column from tool (:pull:`269`). Others ------ diff --git a/message_ix_models/tools/costs/decay.py b/message_ix_models/tools/costs/decay.py index c55384ace..a28fcb034 100644 --- a/message_ix_models/tools/costs/decay.py +++ b/message_ix_models/tools/costs/decay.py @@ -81,9 +81,9 @@ def _get_module_scenarios_reduction( ) ] - # append scen_red_module to scen_red_energy - scenarios_joined = scenarios_energy._append(scenarios_module).reset_index( - drop=True + # concat scenarios_energy and scenarios_module + scenarios_joined = pd.concat( + [scenarios_energy, scenarios_module], ignore_index=True ) else: scenarios_joined = scenarios_energy.copy() @@ -207,7 +207,6 @@ def _get_module_cost_reduction( pd.concat([reduction_energy, reduction_energy_no_reduction], ignore_index=True) .sort_values("message_technology") .reset_index(drop=True) - .drop(columns=["technology_type"]) ) if module != "energy": @@ -224,11 +223,9 @@ def _get_module_cost_reduction( ) ] - # append scen_red_module to scen_red_energy - reduction_joined = ( - reduction_energy._append(reduction_module) - .reset_index(drop=True) - .drop(columns=["technology_type"]) + # concat reduction_energy and reduction_module + reduction_joined = pd.concat( + [reduction_energy, reduction_module], ignore_index=True ) else: reduction_joined = reduction_energy.copy()