Skip to content
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

[ENH] homogenization of sktime and skchange detection API - predict, predict_points, predict_segments #7476

Merged
merged 24 commits into from
Dec 3, 2024

Conversation

fkiraly
Copy link
Collaborator

@fkiraly fkiraly commented Dec 2, 2024

This PR carries out some remaining steps of interface homogenization with skchange:

  • index of returns of predict, predict_points, predict_segments is now always a RangeIndex - no key information requires index manipulation anymore.
  • return of predict, predict_points, predict_segments is now always a pd.DataFrame, with one column "ilocs" for the event indices, and additional potential columns in supervised and semi-supervised cases
  • return of predict is now identical with one of predict_points or predict_segments in the supervised and semi-supervised case

Also updates some estimators to function as expected:

  • existing estimators through coercions to the desired output
  • dummy estimators

@fkiraly fkiraly added implementing framework Implementing or improving framework for learning tasks, e.g., base class functionality module:detection detectors module: outliers, change points, segmentation enhancement Adding new functionality labels Dec 2, 2024
@fkiraly
Copy link
Collaborator Author

fkiraly commented Dec 2, 2024

FYI @Tveten, @Alex-JG3

@Tveten
Copy link

Tveten commented Dec 3, 2024

Looks good!

@fkiraly
Copy link
Collaborator Author

fkiraly commented Dec 3, 2024

Why keep the special case of pd.Series for unsupervised predict? For backward compatibility or deprecation?

Yes, that's what I thought - although I would change this to pd.DataFrame rather earlier than later. Should we do it now?

@Tveten
Copy link

Tveten commented Dec 3, 2024

Why keep the special case of pd.Series for unsupervised predict? For backward compatibility or deprecation?

Yes, that's what I thought - although I would change this to pd.DataFrame rather earlier than later. Should we do it now?

Now is fine with me.

Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@fkiraly fkiraly merged commit 9bf1324 into main Dec 3, 2024
64 of 65 checks passed
@fkiraly fkiraly deleted the detection-final-hom branch December 3, 2024 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Adding new functionality implementing framework Implementing or improving framework for learning tasks, e.g., base class functionality module:detection detectors module: outliers, change points, segmentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants