-
Notifications
You must be signed in to change notification settings - Fork 105
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
Turning off extraneous aeroProblem print outs from MPhys wrapper #307
Conversation
Codecov Report
@@ Coverage Diff @@
## main #307 +/- ##
==========================================
- Coverage 41.94% 41.87% -0.08%
==========================================
Files 13 13
Lines 4005 4017 +12
==========================================
+ Hits 1680 1682 +2
- Misses 2325 2335 +10
📣 Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today! |
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, could you just update the description by adding a printout example for reference?
I just updated the description. I realized I turned off printing in |
Bump on this |
@lamkina I just posted a response today, it should already be there #307 (comment). |
Sorry I missed the notification. Thanks! |
@eirikurj @A-CGray @marcomangano I updated this PR based on the feedback to switch to option and module variables to control the printing. I removed all the arguments and replaced them with a module variable in the fortran layer that we only call in MPhys called I also added some new logic to determine when to print the BC warnings and alpha updates in the mphys layer in |
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.
I ran this myself and it does what it's supposed to do
@marcomangano @ArshSaja this is good to go |
@marcomangano @ArshSaja bump |
@ArshSaja @marcomangano bump again |
@eirikurj needs to approve because he requested changes |
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.
Sorry for the delay. Added few minor comments.
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.
If @eirikurj 's happy with this PR then I am too
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, thanks for the effort on this. BTW, instead of requesting changes, I just adjusted the case on the Fortran variable to be consistent.
I approve but don't have permission to merge |
Purpose
This PR adds arguments to
setAeroproblem
and_setAeroProblemData
inpyADflow
to turn off printing of angle of attach and BC warnings.To turn off boundary condition warning messages, a new logical argument was added tosetBCDataFineGrid
subroutine in theBCData
module. The usage of thesetBCDataFineGrid
in other subroutines was updated to maintain current functionality.Now we turn off the boundary conition printing with fortran module variables.
The docstrings forsetAeroproblem
and_setAeroProblemData
were also updated.The docstrings were set back to their previous state now that we use a module variable.
An example of the printouts that happen everytime
setAeroproblem
is called is shown below. This happens during the coupled adjoint and primal solve. The angle of attack and boundary condition warnings are printed several times because of the extra calls required in MPhys, even though sometimes we are not actually switching the aeroproblem.Expected time until merged
1 week
Type of change
Testing
Only visual testing. I ran runscripts with and without the change to ensure the printing flags were working correctly.
Checklist
flake8
andblack
to make sure the Python code adheres to PEP-8 and is consistently formattedfprettify
or C/C++ code withclang-format
as applicable