Skip to content

Fix updating CHP.installed_cost_per_kw if scalar#612

Merged
Bill-Becker merged 1 commit into
developfrom
chp-cost-update
Nov 6, 2024
Merged

Fix updating CHP.installed_cost_per_kw if scalar#612
Bill-Becker merged 1 commit into
developfrom
chp-cost-update

Conversation

@Bill-Becker
Copy link
Copy Markdown
Collaborator

@Bill-Becker Bill-Becker commented Nov 4, 2024

  • Fix issue with CHP.installed_cost_per_kw not being an array when updating the inputs model object (which expects an array) in process_results.py, from Julia.
  • For context, we rely on REopt.jl logic to assign CHP defaults, and then we have to update the API model fields after REopt.jl runs, in process_results.py. Since CHP.installed_cost_per_kw can be either a float or an array in REopt.jl, while in the API model field it's processed to always be an array, we need to check and convert to an array if it comes back from REopt.jl as a float.

@Bill-Becker Bill-Becker requested a review from rathod-b November 4, 2024 22:56
@rathod-b
Copy link
Copy Markdown
Collaborator

rathod-b commented Nov 5, 2024

@Bill-Becker this looks good. We may need to merge develop into this branch and update the changelog.

@Bill-Becker Bill-Becker merged commit 8d04979 into develop Nov 6, 2024
@Bill-Becker Bill-Becker deleted the chp-cost-update branch November 6, 2024 19:55
@Bill-Becker Bill-Becker mentioned this pull request Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants