Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ Upcoming Release

* Update scenarios for US-specific eletrolyzer investment cost (https://github.com/PyPSA/technology-data/pull/194)

* Adds a Makefile (https://github.com/PyPSA/technology-data/pull/204)

* Adds rounding for the value column of the csv files produced by compile_cost_assumptions_usa (https://github.com/PyPSA/technology-data/pull/206)

`v0.11.0 <https://github.com/PyPSA/technology-data/releases/tag/v0.11.0>`__ (24th January 2025)
=======================================================================================

Expand Down
2,996 changes: 1,498 additions & 1,498 deletions outputs/US/costs_2020.csv

Large diffs are not rendered by default.

4,046 changes: 2,023 additions & 2,023 deletions outputs/US/costs_2025.csv

Large diffs are not rendered by default.

4,204 changes: 2,102 additions & 2,102 deletions outputs/US/costs_2030.csv

Large diffs are not rendered by default.

4,240 changes: 2,120 additions & 2,120 deletions outputs/US/costs_2035.csv

Large diffs are not rendered by default.

4,244 changes: 2,122 additions & 2,122 deletions outputs/US/costs_2040.csv

Large diffs are not rendered by default.

4,244 changes: 2,122 additions & 2,122 deletions outputs/US/costs_2045.csv

Large diffs are not rendered by default.

4,228 changes: 2,114 additions & 2,114 deletions outputs/US/costs_2050.csv

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions scripts/compile_cost_assumptions_usa.py
Original file line number Diff line number Diff line change
Expand Up @@ -1104,7 +1104,7 @@ def duplicate_fuel_cost(input_file_path: str, list_of_years: list) -> pd.DataFra
by=["technology", "parameter"]
).reset_index(drop=True)

# Correct for inflation for technology-parameter pairs having units that contain USD
# correct for inflation for technology-parameter pairs having units that contain USD
inflation_rate_series_usd = prepare_inflation_rate(
input_file_inflation_rate, "USD"
)
Expand All @@ -1123,13 +1123,19 @@ def duplicate_fuel_cost(input_file_path: str, list_of_years: list) -> pd.DataFra
)["value"]
)

# round the value column
rounded_df = inflation_adjusted_updated_cost_df.copy()
rounded_df.loc[:, "value"] = round(
inflation_adjusted_updated_cost_df.value.astype(float), num_digits
)

# output the modified cost dataframe
output_cost_path_list = [
path for path in snakemake.output if str(year_val) in path
]
if len(output_cost_path_list) == 1:
output_cost_path = output_cost_path_list[0]
inflation_adjusted_updated_cost_df.to_csv(output_cost_path, index=False)
rounded_df.to_csv(output_cost_path, index=False)
logger.info(
f"The cost assumptions file for the US has been compiled for year {year_val}"
)
Expand Down