question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Better documentation for random_state

See original GitHub issue

Sort of like https://github.com/scikit-learn/scikit-learn/issues/14228, but for random_state.

For any public object that accepts a random_state parameter, we should document what parts of the algorithm are randomized. It’s not always obvious what is and what isn’t randomized. We should also always link to the glossary, where the different possible values of random_state are clearly explained.

For example for the random forest estimators, it would be helpful to indicate that random_state determines in particular the subsampling of the samples and the subsampling of the features. Something like:


random_state : int, np.random.RandomStateInstance or None, default=None
	Controls the randomness of the estimator, in particular the subsampling
    of the samples and the subsampling of the features. See 
	term:`random_state` for details.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
jnothmancommented, Oct 19, 2019

I think it would be helpful, @nicolashug, to give some examples of what this should look like. Thanks for continuing this work.

1reaction
mschaffenrothcommented, Oct 12, 2019

The script from #14228 (see here) adapted for the random_state parameter got the following results:

Read more comments on GitHub >

github_iconTop Results From Across the Web

randomstate 1.14.0+1.gb397db9 documentation
This package contains drop-in replacements for the NumPy RandomState object that change the core random number generator. What's New or Different¶. randomstate.
Read more >
numpy.random.RandomState — NumPy v1.16 Manual
This is documentation for an old release of NumPy (version 1.16). Read this page Search for this page in the documentation of the...
Read more >
bashtage/ng-numpy-randomstate - GitHub
Numpy-compatible random number generator that supports multiple core psuedo RNGs and explicitly parallel generation.
Read more >
sklearn.utils.check_random_state
Turn seed into a np.random.RandomState instance. Parameters: seedNone, int or instance of RandomState. If seed is None ...
Read more >
numpy.random.RandomState.uniform
This is documentation for an old release of NumPy (version 1.10.1). Read this page Search for this page in the documentation of the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found