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

SDoE: embedding SDoE plots into QDialog windows #1171

Merged
merged 19 commits into from
Nov 28, 2023

Conversation

sotorrio1
Copy link
Member

Fixes/Addresses:

Attempt to fix window stack ordering embedding matplotlib plots into QDialog windows

Summary/Motivation:

When plotting in SDoE, plots are shown as matplotlib objects and when the plots are closed the window stack ordering gets all messed up

Changes proposed in this PR:

  • returning plots as figure objects instead of using plot.show()
  • creating Window class to add figure object to it

Legal Acknowledgement

By contributing to this software project, I agree to the following terms and conditions for my contribution:

  1. I agree my contributions are submitted under the copyright and license terms described in the LICENSE.md file at the top level of this directory.
  2. I represent I am authorized to make the contributions and grant the license. If my employer has rights to intellectual property that includes these contributions, I represent that I have received permission to make contributions and grant the required license on behalf of that employer.

@sotorrio1 sotorrio1 linked an issue Sep 29, 2023 that may be closed by this pull request
@sotorrio1 sotorrio1 self-assigned this Oct 2, 2023
@sotorrio1 sotorrio1 added the SDoE Sequential Design of Experiments label Oct 2, 2023
@ksbeattie ksbeattie added the Priority:High High Priority Issue or PR label Oct 3, 2023
@ksbeattie
Copy link
Member

ksbeattie commented Oct 31, 2023

It is likely that the tests are failing here because of the changes in the way the new QDialog windows are used. If so, then the tests themselves will need updating for this PR. Looking at the OUU and UQ gui-tests and code are structured could help.

Copy link

codecov bot commented Nov 1, 2023

Codecov Report

Attention: 41 lines in your changes are missing coverage. Please review.

Comparison is base (f69912d) 37.31% compared to head (6dc445b) 37.67%.

Files Patch % Lines
foqus_lib/gui/sdoe/sdoePreview.py 10.52% 34 Missing ⚠️
foqus_lib/gui/sdoe/sdoeAnalysisDialog.py 16.66% 5 Missing ⚠️
foqus_lib/framework/sdoe/plot_utils.py 81.81% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1171      +/-   ##
==========================================
+ Coverage   37.31%   37.67%   +0.35%     
==========================================
  Files         160      160              
  Lines       36396    36439      +43     
  Branches     5956     5961       +5     
==========================================
+ Hits        13582    13727     +145     
+ Misses      21726    21609     -117     
- Partials     1088     1103      +15     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sotorrio1 sotorrio1 marked this pull request as ready for review November 1, 2023 18:34
@sotorrio1
Copy link
Member Author

@lbianchi-lbl was right, the problem with SDoE GUI tests was the way sdoeAnalysisDialog was getting open.

@ksbeattie
Copy link
Member

@sotorrio1 is this ready for review now? Were there more tests you were going to write?

@sotorrio1
Copy link
Member Author

@ksbeattie Yes, it's ready for review. I added a couple of tests for plotting functions and tried to add some extra stuff into the existing GUI testing. @lbianchi-lbl might have some comments on the GUI testing stuff

@ksbeattie ksbeattie merged commit cb938bf into CCSI-Toolset:master Nov 28, 2023
13 of 14 checks passed
@sotorrio1 sotorrio1 deleted the issue-978 branch November 28, 2023 23:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:High High Priority Issue or PR SDoE Sequential Design of Experiments
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SDoE UX: Investigate window stack ordering after closing a plot
2 participants