Created
July 24, 2018 10:19
-
-
Save vinaykudari/c0352e3f44b0e6a87388514e2b0422a9 to your computer and use it in GitHub Desktop.
Random Seed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
np.random.seed(25) #setting a seed | |
print(np.random.rand(3)) | |
>> [0.87012414 0.58227693 0.27883894] | |
np.random.seed(25) | |
print(np.random.rand(3)) | |
>> [0.87012414 0.58227693 0.27883894] | |
print(np.random.rand(3)) | |
>> [0.52071879 0.32605113 0.69918624] | |
print(np.random.rand(3)) | |
>> [0.36639455 0.83637451 0.48134294] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment