-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fix deprecation warnings #33
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #33 +/- ##
==========================================
+ Coverage 88.45% 88.47% +0.01%
==========================================
Files 67 67
Lines 7295 7287 -8
Branches 1179 1179
==========================================
- Hits 6453 6447 -6
+ Misses 573 571 -2
Partials 269 269 ☔ View full report in Codecov by Sentry. |
ca0619d
to
4fb0ac4
Compare
This should fix the failures in https://github.com/hyperspy/hyperspy-extensions-list/actions/runs/8494826786/job/23270443981. |
@@ -60,16 +60,14 @@ def _estimate_gain( | |||
variance2fit = variance | |||
average2fit = average | |||
|
|||
fit = np.polyfit(average2fit, variance2fit, pol_order) | |||
fit = np.polynomial.Polynomial.fit(average2fit, variance2fit, pol_order) |
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.
The whole function seems to be missing a test as all touched lines raise a warning.
@@ -46,7 +46,7 @@ def __init__(self): | |||
self.right.value = np.nan | |||
self.side_vignetting = False | |||
self.fix_side_vignetting() | |||
self.gaussian = Gaussian() | |||
self.gaussian = hs.model.components1D.Gaussian() |
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.
no test for this component?
4fb0ac4
to
1b59c0c
Compare
1b59c0c
to
bae3882
Compare
For the missing tests, I had a look and I have no idea, what these functions are supposed to do! I would suggest to leave it for another PR which will need help from @francisco-dlp. |
@jlaehne, do you want to have another look at this PR? |
Progress of the PR
upcoming_changes
folder (seeupcoming_changes/README.rst
),docs/readthedocs.org:exspy
build of this PR (link in github checks)