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

[DOC] Fix double back tick inconsistencies in classification module docstrings #2695

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

ISHOOO
Copy link

@ISHOOO ISHOOO commented Mar 27, 2025

Reference Issues/PRs

Fixes #809

What does this implement/fix? Explain your changes.

This pull request fixes backtick inconsistencies in all docstrings of all classes in the classification module.
The preferred approach mentioned by the maintainers was to use double backticks (). So, I replaced all single quotes (') with double backticks () throughout the classification module.

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

No, this PR does not introduce any new dependencies.

Any other comments?

This is a documentation-only change, so no functional code modifications were made.

PR checklist

For all contributions
  • I've added myself to the list of contributors. Alternatively, you can use the @all-contributors bot to do this after the PR has been merged.
  • The PR title starts with [DOC] indicating that this is a documentation-related change.

@aeon-actions-bot aeon-actions-bot bot added classification Classification package documentation Improvements or additions to documentation labels Mar 27, 2025
@aeon-actions-bot
Copy link
Contributor

Thank you for contributing to aeon

I have added the following labels to this PR based on the title: [ $\color{#F3B9F8}{\textsf{documentation}}$ ].
I have added the following labels to this PR based on the changes made: [ $\color{#BCAE15}{\textsf{classification}}$ ]. Feel free to change these if they do not properly represent the PR.

The Checks tab will show the status of our automated tests. You can click on individual test runs in the tab or "Details" in the panel below to see more information if there is a failure.

If our pre-commit code quality check fails, any trivial fixes will automatically be pushed to your PR unless it is a draft.

Don't hesitate to ask questions on the aeon Slack channel if you have any.

PR CI actions

These checkboxes will add labels to enable/disable CI functionality for this PR. This may not take effect immediately, and a new commit may be required to run the new configuration.

  • Run pre-commit checks for all files
  • Run mypy typecheck tests
  • Run all pytest tests and configurations
  • Run all notebook example tests
  • Run numba-disabled codecov tests
  • Stop automatic pre-commit fixes (always disabled for drafts)
  • Disable numba cache loading
  • Push an empty commit to re-run CI checks

- The checkout step in .github/workflows/pr_precommit.yml was missing the fetch-depth property.
- By default, actions/checkout@v4 fetches only the latest commit (fetch-depth: 1), which prevents workflows from accessing the full commit history.
- This caused issues in detecting changed files properly.
- Setting fetch-depth: 0 ensures a full clone, allowing proper diff detection and resolving potential errors.
@ISHOOO ISHOOO requested a review from a team as a code owner March 28, 2025 13:07
@@ -30,6 +30,7 @@ jobs:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.head_ref }}
token: ${{ steps.app-token.outputs.token }}
fetch-depth: 0
Copy link
Member

Choose a reason for hiding this comment

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

Don't make this edit here. See #2723 if you want to help create help solve this issue

Comment on lines +35 to +37
Overview: Input ``n`` series length ``m`` with ``d`` dimensions
TDE searches ``k`` parameter values selected using a Gaussian processes
regressor, evaluating each with a LOOCV. It then retains ``s``
Copy link
Member

Choose a reason for hiding this comment

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

These are fine as is. This are the notation used in the paper, not the code.

Copy link
Member

Choose a reason for hiding this comment

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

Just noticed "lcoefficients" below. could you fix that also?

@@ -23,7 +23,7 @@ class WEASEL(BaseClassifier):
"""
Word Extraction for Time Series Classification (WEASEL).

As described in [1]_. Overview: Input 'n' series length 'm'
As described in [1]_. Overview: Input ``n`` series length ``m``
Copy link
Member

Choose a reason for hiding this comment

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

same here

Comment on lines +77 to +80
``chi2`` reduces the number of words, keeping those above the ``p_threshold``.
``random`` reduces the number to at most ``max_feature_count``,
by randomly selecting features.
'none' does not apply any feature selection and yields large bag of words.
``none`` does not apply any feature selection and yields large bag of words.
Copy link
Member

Choose a reason for hiding this comment

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

String parameters should still contain quotation marks even in code style.

@@ -34,7 +34,7 @@ class WEASEL_V2(BaseClassifier):
"""
Word Extraction for Time Series Classification (WEASEL) v2.0.

Overview: Input 'n' series length 'm'
Overview: Input ``n`` series length ``m``
Copy link
Member

Choose a reason for hiding this comment

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

Again

Comment on lines +75 to +79
``chi2_top_k`` reduces the number of words to at most 'max_feature_count',
dropping values based on p-value.
'random' reduces the number to at most 'max_feature_count', by randomly
``random`` reduces the number to at most ``max_feature_count``, by randomly
selecting features.
'none' does not apply any feature selection and yields large bag of words
``none`` does not apply any feature selection and yields large bag of words
Copy link
Member

Choose a reason for hiding this comment

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

Same as other weasel

@@ -83,7 +83,7 @@ def test_proportion_train_in_param_finding():


def test_all_distance_measures():
"""Test the 'all' option of the distance_measures parameter."""
"""Test the ``all`` option of the distance_measures parameter."""
Copy link
Member

Choose a reason for hiding this comment

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

no need to edit tests

@ISHOOO
Copy link
Author

ISHOOO commented Apr 5, 2025

Greetings @MatthewMiddlehurst, thanks for taking time to review my pull request. I've read all the remarks and will make sure to keep them in mind for all my future contributions to aeon.
Also the typo error 'lcoefficients' has been fixed to 'coefficients' along with a few others. I have made the commit to my branch and I suppose the current PR should get updated soon regarding this commit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
classification Classification package documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[DOC] Inconsistent double tick quotes in docstrings
2 participants