Created
June 26, 2018 20:10
-
-
Save wimglenn/fb4e4c04c067d6d566f7f2ca023bdd2a to your computer and use it in GitHub Desktop.
numpy wat
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
>>> import numpy as np | |
>>> import builtins | |
>>> np.random.randn(3,3) | |
array([[-0.24401213, -0.19773938, 0.47278806], | |
[-0.6083566 , -0.65160561, 0.78145811], | |
[ 0.14546934, -0.86849935, 2.07570471]]) | |
>>> np.empty((3,3)) # sign loss | |
array([[0.24401213, 0.19773938, 0.47278806], | |
[0.6083566 , 0.65160561, 0.78145811], | |
[0.14546934, 0.86849935, 2.07570471]]) | |
>>> np.random.randn(3,3) | |
array([[ 0.16574423, -0.46423738, 0.03250756], | |
[ 1.73511269, 1.32196368, -0.10191454], | |
[-1.10077353, -0.12643854, 1.29953623]]) | |
>>> del builtins._ | |
>>> np.empty((3,3)) # no sign loss | |
array([[ 0.16574423, -0.46423738, 0.03250756], | |
[ 1.73511269, 1.32196368, -0.10191454], | |
[-1.10077353, -0.12643854, 1.29953623]]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment