-
Notifications
You must be signed in to change notification settings - Fork 54
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
MVP Surrogate Plugin ML/AI #1163
MVP Surrogate Plugin ML/AI #1163
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #1163 +/- ##
==========================================
+ Coverage 37.67% 38.52% +0.85%
==========================================
Files 160 163 +3
Lines 36439 36880 +441
Branches 5961 5995 +34
==========================================
+ Hits 13727 14208 +481
+ Misses 21609 21562 -47
- Partials 1103 1110 +7 ☔ View full report in Codecov by Sentry. |
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.
@franflame this is very nice! I tested it locally and it ran smoothly. Just a few minor comments, overall the MVP looks good.
Also fixed spacing in keras_nn.py description
…rogate-plugin-ml-ai
@franflame @lbianchi-lbl I just tested this by manually executing the "Simple_flow" test in the GUI, checking the save locations and loading behavior of the saved model files, and fixing a few typos to make the Spell Checker happy. It looks very nice, great work! The .keras extension is different than the .h5 extension we use in the ML AI Plugin but seems to work properly. The Plugin currently assumes file extensions directly correspond to model types and doesn't account for same-name models of different extensions, so we should probably update that in a separate PR. I wasn't able to add samples after loading from a CSV file. Loading from a flowsheet node worked great. Would there be a way to use loaded data that does exist on the flowsheet to generate samples that the "Variables" tab can recognize? The UQ module may give some inspiration for how to do this. |
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.
Everything is good, GUI and data improvements planned for future updates.
#1158
Summary/Motivation:
Added MVP surrogate plugin for creating ML/AI models
Instructions to run new plugins, applicable to all three:
keras_nn
,pytorch_nn
, andscikit_nn
:(optional steps are marked with *)
Click on home button/"Session" and select "Open Session..."
Open the file
FOQUS/examples/tutorial_files/Flowsheets/Tutorial_4/Simple_flow.foqus
Click on "Surrogate"
Under the "Tool:" dropdown, select either keras_nn, pytorch_nn, or scikit_nn
*If you go to the "Data" tab, you should see that the "Flowsheet Results" have been populated
Go to the tab "Variables" to select your desired input and output variables
*You can change various settings with "Method Settings"
Press the green play button to start the training process
Go to the "Execution" tab to see the output of the plugin
Legal Acknowledgement
By contributing to this software project, I agree to the following terms and conditions for my contribution: