Skip to content

ENH Accelerate plot_mlp_alpha.py#21648

Merged
thomasjpfan merged 1 commit intoscikit-learn:mainfrom
yuanx749:plot_mlp_alpha
Nov 12, 2021
Merged

ENH Accelerate plot_mlp_alpha.py#21648
thomasjpfan merged 1 commit intoscikit-learn:mainfrom
yuanx749:plot_mlp_alpha

Conversation

@yuanx749
Copy link
Copy Markdown
Contributor

@yuanx749 yuanx749 commented Nov 12, 2021

Reference Issues/PRs

#21598

What does this implement/fix? Explain your changes.

  • Reduce hidden_layer_sizes to speed up. Moreover I think 100 is too large for these small datasets.
  • random_state is missing in train_test_split. Add and tune it to preserve the trend showing overfitting to underfitting when increasing alpha.

before: 33 seconds
before
after: 5 seconds
after

Any other comments?

Copy link
Copy Markdown
Member

@TomDLT TomDLT left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Member

@thomasjpfan thomasjpfan left a comment

Choose a reason for hiding this comment

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

Thank you for the PR @yuanx749 !

LGTM

@thomasjpfan thomasjpfan changed the title [MRG] Accelerate plot_mlp_alpha.py ENH Accelerate plot_mlp_alpha.py Nov 12, 2021
@thomasjpfan thomasjpfan merged commit 53495a2 into scikit-learn:main Nov 12, 2021
@TomDLT TomDLT mentioned this pull request Nov 12, 2021
41 tasks
@yuanx749 yuanx749 deleted the plot_mlp_alpha branch November 12, 2021 22:54
glemaitre pushed a commit to glemaitre/scikit-learn that referenced this pull request Nov 22, 2021
glemaitre pushed a commit to glemaitre/scikit-learn that referenced this pull request Nov 29, 2021
samronsin pushed a commit to samronsin/scikit-learn that referenced this pull request Nov 30, 2021
glemaitre pushed a commit to glemaitre/scikit-learn that referenced this pull request Dec 24, 2021
glemaitre pushed a commit that referenced this pull request Dec 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants