-
Notifications
You must be signed in to change notification settings - Fork 13
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
Mixed fs limiter #459
Mixed fs limiter #459
Conversation
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.
Thanks Tim, this looks really good and very neatly implemented.
I think the choice of DG1 and DG1 equispaced for the different spaces in the test makes sense, and it's good to demonstrate that this will in theory work when the tracers are in different spaces.
I have two very very trivial suggestions about docstrings, then this will be good to go on
gusto/limiters.py
Outdated
|
||
|
||
class MixedFSLimiter(object): | ||
"""An object to hold a dictionary that defines limiters for transported prognostic |
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.
"""An object to hold a dictionary that defines limiters for transported prognostic | |
""" | |
An object to hold a dictionary that defines limiters for transported prognostic |
When the docstrings go over more than one line, I think we should generally put the open quotation marks on their own line
gusto/limiters.py
Outdated
def __init__(self, equation, sublimiters): | ||
""" | ||
Args: | ||
equation (:class: 'PrognosticEquationSet'): the prognostic equation(s) |
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.
equation (:class: 'PrognosticEquationSet'): the prognostic equation(s) | |
equation (:class:`PrognosticEquationSet`): the prognostic equation(s) |
I think we need a back quotation here and not forward ones!
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.
Looks great Tim, thanks and sorry it's taken a while to get this approved!
This pull request adds the ability to apply individual limiters to specific prognostic variables. It does so through a MixedFSLimiter object in gusto/limiters.py which stores a dictionary with user defined sublimiters for certain prognostic variables. A test is of this new functionality is added to the integration-tests/transport/test_limiters.py file.