[ENH] efficient _evaluate_by_index for GeometricMeanAbsoluteError#6461
[ENH] efficient _evaluate_by_index for GeometricMeanAbsoluteError#6461KaustubhUp025 wants to merge 25 commits intosktime:mainfrom KaustubhUp025:Ksktime
_evaluate_by_index for GeometricMeanAbsoluteError#6461Conversation
…etricMeanAbsoluteError
…MeanAbsoluteError with documentation as well
…MAE. This modification ensures that the errors are strictly positive before taking their logarithm, improving the numerical stability of the calculation.
…ient _evaluate_by_index for GMAE. Additional methods added :- _compute_pseudo_values: Computes the jackknife pseudo-values for the Geometric Mean Absolute Error (GMAE) metric, estimating the influence of each observation on the overall metric. _evaluate: Evaluates the GMAE metric on given inputs, providing the overall metric value. This method is the core logic called from the evaluate method and computes the arithmetic mean over time points by default.
fkiraly
left a comment
There was a problem hiding this comment.
Nice!
I think there's a bit of code bloat going on, can you perhaps have a look a MeanSquaredError, the square_root=True case? Have a look how the pseudo-values are implemented there.
_evaluate_by_index for GeometricMeanAbsoluteError
|
I checked it once more for the code bloat, by checking the implementation from the |
|
@KaustubhUp025, are you still working on this? |
|
Yes I am working on it @fkiraly and it will be solved soon. The code I wrote got a wrong answer on one of my custom test values that I took as a reference from the initial documentation of |
|
I am confused about your multiple PR, the other PR contains changes to two metrics classes. I would suggest to use this PR for the GMAE and the GMAE only. Could you take my changes and wrap them up? |
|
So should I close the other PR and work upon this on only @fkiraly |
Reference Issues/PRs
Towards #6244
What does this implement/fix? Explain your changes.
Added a new function
_compute_psuedo_valuesfor calculating jackknife pseudo-values.Does your contribution introduce a new dependency? If yes, which one?
No
What should a reviewer concentrate their feedback on?
Did you add any tests for the change?
No
Any other comments?
PR checklist
For all contributions
How to: add yourself to the all-contributors file in the
sktimeroot directory (not theCONTRIBUTORS.md). Common badges:code- fixing a bug, or adding code logic.doc- writing or improving documentation or docstrings.bug- reporting or diagnosing a bug (get this pluscodeif you also fixed the bug in the PR).maintenance- CI, test framework, release.See here for full badge reference
maintainerstag - do this if you want to become the owner or maintainer of an estimator you added.See here for further details on the algorithm maintainer role.
For new estimators
docs/source/api_reference/taskname.rst, follow the pattern.Examplessection.python_dependenciestag and ensureddependency isolation, see the estimator dependencies guide.