rougier/numpy-100

'numpy.ndarray' object has no attribute 'random'

coco202222 opened this issue · 2 comments

Hello, does anyone know how to fix this attribute error?

In [34]: np.random.randint(0,100,size=(5,3))

AttributeError Traceback (most recent call last)
in
----> 1 np.random.randint(0,100,size=(5,3))

AttributeError: 'numpy.ndarray' object has no attribute 'random'

What is np in your session? If you first import numpy as np, does it fail too?

What is np in your session? If you first import numpy as np, does it fail too?

thanks i got it!