-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Implicitly setting a random seed? #1868
Comments
pl doesn’t set the seed anywhere. we have a function you can use to do it. search the codebase for the word seed |
Yes, but why do I get deterministic random int every time I run the script? I didn't set any seed explicitly. It's only 3 lines, you can try it yourself. |
Also if I simply remove the first line |
|
I don't know why I'm getting the deterministic behavior - I'm on PL 0.7.5, both OS X and Ubuntu 16.04 give me the same issue |
Not sure... we're very aware of correct research practices. Double check your environment or how you're running this... Here's a discussion showing how hard we thought about adding the seed_everything function... we don't do new feature decisions lightly. Check this PR |
thanks! |
🐛 Bug
To Reproduce
Steps to reproduce the behavior:
If you run this script repeatedly, you will get the same 'random' integer. PyTorch-lightning seems to be setting a random seed behind the hood. This is very dangerous because I want to show the variance of my algorithm, and PTL actually makes (part of) it deterministic.
Expected behavior
PTL shouldn't set the seed without the user's permission.
The text was updated successfully, but these errors were encountered: