8000 Docs duplication between attributes and properties · Issue #30957 · scikit-learn/scikit-learn · GitHub
[go: up one dir, main page]

Skip to content

Docs duplication between attributes and properties #30957

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
david-cortes opened this issue Mar 7, 2025 · 1 comment · Fixed by #30989
Closed

Docs duplication between attributes and properties #30957

david-cortes opened this issue Mar 7, 2025 · 1 comment · Fixed by #30989

Comments

@david-cortes
Copy link
Contributor

Describe the issue linked to the documentation

Docs for some classes mention some fitted-model attributes twice: first as 'attribute', then as 'property'.

For example, class SVC here:
https://scikit-learn.org/stable/modules/generated/sklearn.svm.SVC.html

Shows coef_ first under 'Attributes':
Image

And then shows it again as a property:
Image

I am guessing this might be the autodoc plugin for sphinx being too eager with what it includes.

Suggest a potential alternative/fix

Should show up only under 'attributes'.

@david-cortes david-cortes added Documentation Needs Triage Issue requires triage labels Mar 7, 2025
@lesteve lesteve added help wanted and removed Needs Triage Issue requires triage labels Mar 11, 2025
@lesteve
Copy link
Member
lesteve commented Mar 11, 2025

Indeed, by any means if you find a way to improve the situation, feel free to open a PR! Full disclosure: I don't think it is that easy, because coef_ attribute is documented by hand and coef_ property is automatically documented by sphinx ....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants
0