Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Objective Cost Calculation #240

Merged
merged 10 commits into from
Nov 12, 2024
Merged

Update Objective Cost Calculation #240

merged 10 commits into from
Nov 12, 2024

Conversation

trevorb1
Copy link
Member

@trevorb1 trevorb1 commented Nov 8, 2024

Description

In this PR I have updated the objective cost calculation to account for storage costs. Additionally, I have added result calculations for non-discounted storage investment costs, discounted storage investment costs, discounted storage salvage value, and total discounted cost by storage.

Issue Ticket Number

Closes #237

Documentation

na

@trevorb1 trevorb1 requested a review from willu47 November 8, 2024 00:26
@trevorb1
Copy link
Member Author

trevorb1 commented Nov 8, 2024

@willu47 would you be able to review this? Since Im modifying the objective cost calculation, a double check that everything looks correct would be great! If you dont have time right now though, no worries at all :)

@trevorb1
Copy link
Member Author

trevorb1 commented Nov 8, 2024

Oh. Actually, sorry, maybe hold off on reviewing this @willu47. I dont think its working correctly. If no storage is in the model, total discounted cost isnt calculated and this warning comes up. It originates from the fact that if no storage is invested in, NewStorageCapacity isnt an available result and the rest of storage calculations fail. Il sort this out and tag you for a review when its fixed!

DEBUG:otoole.results.results:Error calculating TotalDiscountedCost: 'Cannot calculate TotalDiscountedCost due to missing data: \'Cannot calculate TotalDiscountedCostByStorage due to missing data: \\\'Cannot calculate DiscountedCapitalInvestmentStorage due to missing data: "Cannot calculate CapitalInvestmentStorage due to missing data: \\\\\\\'NewStorageCapacity is not accessible or available\\\\\\\'"\\\'\''

@willu47
Copy link
Member

willu47 commented Nov 8, 2024

NewStorageCapacity isnt an available result

Sounds like a good candidate for a unit test...

@trevorb1
Copy link
Member Author

trevorb1 commented Nov 8, 2024

Great! I believe I addressed the issue in this commit and is ready for a review; if you have a chance please, @willu47!

@willu47 willu47 merged commit 097fa2d into develop Nov 12, 2024
18 checks passed
@willu47 willu47 deleted the issue-237 branch November 12, 2024 13:04
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