Adding custom index support for MAPE#1641
Merged
Merged
Conversation
freddyaboulton
force-pushed
the
1634-custom-index-mape
branch
from
January 4, 2021 22:20
70846c4 to
e35bdb9
Compare
Codecov Report
@@ Coverage Diff @@
## main #1641 +/- ##
=========================================
+ Coverage 100.0% 100.0% +0.1%
=========================================
Files 240 240
Lines 18255 18263 +8
=========================================
+ Hits 18247 18255 +8
Misses 8 8
Continue to review full report at Codecov.
|
freddyaboulton
marked this pull request as ready for review
January 4, 2021 22:47
freddyaboulton
requested review from
ParthivNaresh,
angela97lin,
bchen1116,
chukarsten,
dsherry and
jeremyliweishih
January 4, 2021 22:48
chukarsten
approved these changes
Jan 5, 2021
dsherry
approved these changes
Jan 5, 2021
| y_predicted = y_predicted.values | ||
| difference = np.subtract(y_true, y_predicted) | ||
| scaled_difference = np.divide(difference, y_true) | ||
| return np.abs(scaled_difference).mean() * 100 |
Contributor
There was a problem hiding this comment.
@freddyaboulton very cool!
The call to .values converts to a np type -- is that necessary here, or will the first call to one of the np ufuncs do that conversion for you?
Contributor
Author
There was a problem hiding this comment.
I ended up removing the ufuncs cause calling .values is all we need!
freddyaboulton
force-pushed
the
1634-custom-index-mape
branch
from
January 5, 2021 15:53
e35bdb9 to
c732925
Compare
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request Description
Fixes #1634
After creating the pull request: in order to pass the release_notes_updated check you will need to update the "Future Release" section of
docs/source/release_notes.rstto include this pull request by adding :pr:123.