Skip to content

Commit

Permalink
fix: reading of price unit for text-report points to the correct data…
Browse files Browse the repository at this point in the history
… node
  • Loading branch information
JuanPedroGHM committed Jul 31, 2024
1 parent 78a5332 commit b27f2dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion perun/io/text_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def textReport(dataNode: DataNode, mr_id: str) -> str:
e_kWh = total_energy / (3600 * 1e3)
kgCO2 = dataNode.metrics[MetricType.CO2].sum # type: ignore
money = dataNode.metrics[MetricType.MONEY].sum # type: ignore
money_icon = dataNode.metadata["post-processing.price_unit"]
money_icon = mr_node.metadata["post-processing.price_unit"]

app_summary_str = f"Application Summary\n\nThe application has been run {n_runs} times. Throughout its runtime, it has used {e_kWh:.3f} kWh, released a total of {kgCO2:.3f} kgCO2e into the atmosphere, and you paid {money:.2f} {money_icon} in electricity for it."
else:
Expand Down

0 comments on commit b27f2dd

Please sign in to comment.