Skip to content

Added documentation reference to plot_segmentation_toy.py to spectral.py #30978

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

Closed

Conversation

tassonem
Copy link

Reference Issues/PRs

Adds links to examples/cluster mentioned in #30621

What does this implement/fix? Explain your changes.

This PR improves the SpectralClustering documentation by adding a reference to plot_segmentation_toy.py, which demonstrates the application of Spectral Clustering in image segmentation using normalized cuts.

Any other comments?

Examples linked:

examples/cluster
plot_segmentation_toy.p

Copy link

✔️ Linting Passed

All linting checks passed. Your pull request is in excellent shape! ☀️

Generated for commit: 98da8d0. Link to the linter CI: here

Copy link
Contributor

@StefanieSenger StefanieSenger left a comment

Choose a reason for hiding this comment

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

Hello @tassonem,

thanks for opening this PR for adding the link. The linked example seems a rather special use case to me and as such I would not put it into the more general model description right on top.

I am also not so sure it this need so be linked at all. (Do you have an opinion on that, @adrinjalali?) If so, then I would suggest to put it in the end of the Examples section starting in line 590.

Please be aware that adding two empty lines caused the docstring-test to break, which is this output from the CI. So while you move the link below, please only add one empty line.

Thanks for your effort!

Comment on lines +393 to +394
:ref:`sphx_glr_auto_examples_cluster_plot_segmentation_toy.py`
Copy link
Contributor

@StefanieSenger StefanieSenger Mar 14, 2025

Choose a reason for hiding this comment

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

Suggested change
:ref:`sphx_glr_auto_examples_cluster_plot_segmentation_toy.py`
:ref:`sphx_glr_auto_examples_cluster_plot_segmentation_toy.py`.

Also, please delete one of the empty lines below. It causes one of the CI tests to fail.

@adrinjalali
Copy link
Member

I agree with @StefanieSenger here that it doesn't feel like we need a link to this example, and the user guide already links to it nicely.

Thanks for your contribution @tassonem , and sorry that this one didn't get merged.

@adrinjalali adrinjalali closed this May 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants