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] RDSTClassifier and transformer tests #529

Merged
merged 14 commits into from
Jul 19, 2023
Merged

[ENH] RDSTClassifier and transformer tests #529

merged 14 commits into from
Jul 19, 2023

Conversation

baraline
Copy link
Member

@baraline baraline commented Jul 1, 2023

Reference Issues/PRs

What does this implement/fix? Explain your changes.

  • Add a classifier warper for RDST with a ridge classifier
  • Delete some docstring on RDST transformer that were not up-to-date with the current implementation.
  • Debug some test functions
  • Add sanity checks and debug edges cases for RDST Transformer

Does your contribution introduce a new dependency? If yes, which one?

No.

What should a reviewer concentrate their feedback on?

Check if the implementation of RDSTClassifier is matching the standards of aeon.

Did you add any tests for the change?

I added a default test parameter set for the get_test_params method.

PR checklist

For all contributions
  • I've added myself to the list of contributors.
  • Optionally, I've updated aeon's CODEOWNERS to receive notifications about future changes to these files.
  • The PR title starts with either [ENH], [MNT], [DOC], or [BUG] indicating whether the PR topic is related to enhancement, maintenance, documentation, or bug.
  • For new estimators, I've added the estimator to the online documentation.

@baraline baraline marked this pull request as draft July 2, 2023 09:06
@MatthewMiddlehurst MatthewMiddlehurst added enhancement New feature, improvement request or other non-bug code enhancement classification Classification package transformations Transformations package labels Jul 3, 2023
Copy link
Member

@MatthewMiddlehurst MatthewMiddlehurst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will get back to you Re: MacOS if i can figure it out

aeon/classification/shapelet_based/_rdst.py Show resolved Hide resolved
aeon/classification/shapelet_based/_rdst.py Outdated Show resolved Hide resolved
aeon/classification/shapelet_based/_rdst.py Outdated Show resolved Hide resolved
@MatthewMiddlehurst
Copy link
Member

MatthewMiddlehurst commented Jul 14, 2023

Macs are miserable. But either the latest commit solves the different results or my VM does not work as intended.

Tried for a while to get a UEA Macbook working then found an old setup for Catch22 which used to have the same issue!

@baraline
Copy link
Member Author

I was getting numba type error for passing a RandomState object to random_dilated_shapelet_extraction rather than an integer on my windows (what i changed in the latest commit). Hopefully it's this ? If not, I'm a bit out of ideas ...

@MatthewMiddlehurst
Copy link
Member

Nope, I would just remove/skip/comment out the test for now. Setting up a Mac will take a little bit more work on my end unless anyone else can get one.

@baraline
Copy link
Member Author

I added some checks and the end of the fit method to avoid cases where we have no shapelets or NaN values in the shapelets values. So now more informative errors will be raised if these cases happen. Tests for the classifier seem to be OK on MacOS.

@MatthewMiddlehurst
Copy link
Member

MatthewMiddlehurst commented Jul 16, 2023

Also there appears to be an out of index error on one of the numba functions, see https://github.com/aeon-toolkit/aeon/actions/runs/5565449870/jobs/10165816706 (numba does not check for this by default)

@baraline
Copy link
Member Author

This is due to a mistake in the data given to the function in the test for. This should now work as intended, I needed to transpose the array to have the expected shape from the testing data. This should not impact normal execution as the correct shape is given by the sliding_mean_std_one_series function in the transform.

@baraline baraline marked this pull request as ready for review July 16, 2023 17:22
@baraline
Copy link
Member Author

Is the readthedocs issue due to something wrong with the docs ? Only see a timeout on the errors

Copy link
Member

@MatthewMiddlehurst MatthewMiddlehurst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Docs issue is not related to this PR, happening on other PRs and we have to figure out why!

@MatthewMiddlehurst MatthewMiddlehurst merged commit 4a8525e into aeon-toolkit:main Jul 19, 2023
@baraline baraline deleted the rdst_classifier branch July 19, 2023 21:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
classification Classification package enhancement New feature, improvement request or other non-bug code enhancement transformations Transformations package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants