-
Notifications
You must be signed in to change notification settings - Fork 294
Fix issue 1287 bug in subcritical powerplant report method #1720
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
base: main
Are you sure you want to change the base?
Fix issue 1287 bug in subcritical powerplant report method #1720
Conversation
the change tags components that exist in the stream, e.g. for flue-gas streams, it tags N2, O2, NO, etc.; for water/steam streams, it only tags H2O, as the IAPWS95 property package only contains water.
removed duplicate pressure tag; removed dividend by 1000 for hmass and pressure as their unit are in J/kg and Pa, respectively
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1720 +/- ##
==========================================
+ Coverage 73.66% 73.74% +0.08%
==========================================
Files 397 398 +1
Lines 65041 65094 +53
Branches 10949 10954 +5
==========================================
+ Hits 47910 48002 +92
+ Misses 14628 14588 -40
- Partials 2503 2504 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Edit: except that the changes aren't being tested. A way you could test these changes is by extracting lines 2211 to 2238 into a helper function that returns the tags and tags_formats dictionaries, then test the outputs of that function.
|
@Lingyan90, can you get to adding tests before the February release? |
The original testing code didn't cover the info from line 2211 to 2238. The exiting testing code is neat and concise. My changes from line 2211 to line 2224 are mainly correct the unit shown in plot |
When we fix issues that were not covered by our current tests, we like to write new tests to verify that the functionality does not break in the future. That way we can increase the overall test coverage of the repository. |
modified the subcritical_power_plant.py with healer function for tags, tag formats, and tag_group to support a cleaner and simpler tags, tag formats, and tag_group test in the test file.
…hod' of https://github.com/Lingyan90/idaes-pse-lyd into fix-issue_1287-bug-in-subcritical-powerplant-report-method
Fixes
Fix training issue: bug in subcritical powerplant report method #1287.
Also updated the tags units to remove duplicate units in output
plant_pdf_results.svg.Summary/Motivation:
Reproduced the KeyError issue in local machine. The second error regarding solver "IPOPT" was not observed when testing in local machine. This PR helps resolve the KeyError mentioned in the issue.
Changes proposed in this PR:
plant_pdf_results.svg./1000.Legal Acknowledgement
By contributing to this software project, I agree to the following terms and conditions for my contribution: