Skip to content

Commit

Permalink
Send plot data to logfile in CSV format
Browse files Browse the repository at this point in the history
  • Loading branch information
salewis38 authored Aug 10, 2023
1 parent a53deda commit 6314f39
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions palm_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -491,14 +491,14 @@ def compute_tgt_soc(self, gen_fcast, weight: int, commit: bool) -> str:
i += 1
day += 1

# Send plot data to stdout in CSV format
print("SoC Chart Data")
print("Time,", plot_x)
print("Calculated SoC,", plot_y1)
print("Adjusted SoC,", plot_y2)
print("Max,", plot_y3)
print("Reserve,", plot_y4)
print("End of SoC Chart Data")
# Send plot data to logfile in CSV format
logger.info("SoC Chart Data")
logger.info("Time,"+ str(plot_x))
logger.info("Calculated SoC,"+ str(plot_y1))
logger.info("Adjusted SoC,"+ str(plot_y2))
logger.info("Max,"+ str(plot_y3))
logger.info("Reserve,"+ str(plot_y4))
logger.info("End of SoC Chart Data")

logger.info("{:<25} {:>10} {:>10} {:>10} {:>10} {:>10}".format("SoC Calc Summary;",
"Max Charge", "Min Charge", "Max %", "Min %", "Target SoC"))
Expand Down

0 comments on commit 6314f39

Please sign in to comment.