-
Notifications
You must be signed in to change notification settings - Fork 24
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
Adding default n_steps and adding ndim #20
Conversation
Thanks for getting this started @iangrooms! Let me know when you're ready for some feedback. The "pre-commit" part of the checks does code linting (checking that the code formatting conforms to standards, etc.) You can set it up locally following the contributor guide and have it run automatically every time you commit. It will give hints on how to satisfy its checks. |
@rabernat this pull request should be ready. Not sure why it says it's failing the pre-commit, since it passes on my machine. Also, all tests currently pass. |
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.
This is great @iangrooms! Congrats on successfully jumping through all of the hoops (tests, pre-commit, etc.)
I don't understand the pre-commit failure either, but for now I think we can safely ignore it.
I have a few tiny suggestions for docstring formatting and a question about how to handle the ndim
parameter.
Co-authored-by: Ryan Abernathey <[email protected]>
Co-authored-by: Ryan Abernathey <[email protected]>
Codecov Report
@@ Coverage Diff @@
## master #20 +/- ##
==========================================
- Coverage 97.64% 95.94% -1.70%
==========================================
Files 7 7
Lines 212 222 +10
==========================================
+ Hits 207 213 +6
- Misses 5 9 +4
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Ok great! Do you see anything in the tutorial that needs to be updated because of the API change? If not, I think this is ready to merge. |
I checked the tutorial, and there shouldn't be any changes. I also added an error if the user tries to use |
Ok great, I'll merge. Thanks a lot @iangrooms! For reference, the coverage report is referring to the fact that some parts of the new if / else block for To keep test coverage high, technically we should add test scenarios for each of these different options, including the errors. However, that feels a little too strict for the early stage this package is at, so we will let it slide for now. I'll put a reminder in #18 about this. |
@jbusecke it won't let me merge because of the pre-commit failure. Can you look at this and try to figure out what's going on? Ian says the pre-commit passes locally, but the workflow is still failing. If the pre-commit is going to be flaky like this, I feel like we should disable it as a required check. |
Let me look into this. |
I can reproduce the error locally on my machine. @iangrooms could you confirm which conda environment you used? Did you run Another thing I noticed is that you started this PR from your master branch. Not sure if that is causing this trouble though. In general it is recommended to check out a new branch with |
Oh I see this was solved. What was the culprit in the end? |
pre-commit changes files, including ones that I wasn't working on ( |
Yet strangely, kernels.py does not show up in the files changed tab of this PR. 🧐 I'm still learning about pre-commit myself, so it's useful to get this feedback. |
Thanks for the feedback @iangrooms. That is quite strange, actually. It should not let you push the commit if there are problems with the committed files. Or at least that is how I understand it. For what its worth, I personally always do a manual pre-commit run |
This PR does a few things:
n_steps
that depends on the coarsening factor (filter_scale/dx_min
)ndmin
filter_scale
in both filter shapes, so that it always corresponds to a boxcar of widthfilter_scale