-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
[MRG] add random_state in tests estimators #8563
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
this has lots of conflicts :-/ |
I remember at some point a couple of senior devs (I can't find now exactly where, at an email probably) agreeing that random state should not be passed at tests. That's why I left it as it is. In hindsight, my personal --inexperienced-- opinion is that it is not always the best idea. Perhaps each test has different value if it is deterministic or not. If you want I could try to quickly resolve those conflicts but I cannot look into each test and understand if it's the best thing to do. |
Sorry I don't understand you comment. I thought we agreed we wanted to add the random state. What does that have to do with the conflicts? |
If we want to add the random state at almost all tests, then I will resolve the conflicts. If it is going to be integrated in the master then great. I think there was a discussion here #8194 |
ping @lesteve @agramfort @ogrisel @GaelVaroquaux So what's the consensus? I think we should set them. |
ping @lesteve @agramfort @ogrisel @GaelVaroquaux So what's the consensus? I
think we should set them.
I am clearly convinced that we should set them. How bad would be the
conflict situation with other PRs?
|
Seems like a lot of conflicts.. Would monkeypatching |
Just for the record, I am not really convinced that this is worth the pain as I tried to explain in #8194 (comment). |
Reference Issue
Fix #8194
What does this implement/fix? Explain your changes.
Pass random_state in all test cases where it was missing in the estimator's invocation.
Any other comments?
Added only in a few tests yet, nosetests ran OK. If it is correct and there are no further problems, I will add all the rest. Also, should I add in the contributing docs that when possible all estimators in new tests must be invoked with random_state set?