Skip to content

Commit

Permalink
Fix capex linear initialization bug for PWA
Browse files Browse the repository at this point in the history
  • Loading branch information
johburger committed Apr 30, 2024
1 parent 6696d96 commit 22f1b87
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions zen_garden/model/objects/technology/conversion_technology.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,9 @@ def get_capex_all_elements(cls, optimization_setup, index_names=None):
# extract for pwa
if not getattr(element, is_pwa_attribute):
dict_of_attributes, _, dict_of_units = optimization_setup.append_attribute_of_element_to_dict(element, attribute_name_linear, dict_of_attributes, dict_of_units={})
if not dict_of_attributes:
_, index_names = cls.create_custom_set(index_names, optimization_setup)
return dict_of_attributes, index_names, dict_of_units
if not dict_of_attributes:
_, index_names = cls.create_custom_set(index_names, optimization_setup)
return dict_of_attributes, index_names, dict_of_units
dict_of_attributes = pd.concat(dict_of_attributes, keys=dict_of_attributes.keys())
if not index_names:
logging.warning(f"Initializing the parameter capex without the specifying the index names will be deprecated!")
Expand Down

0 comments on commit 22f1b87

Please sign in to comment.