常用numpy的函数汇总

np.ones(shapem dtype=None, order='C')
//return a new array of given shape and type

e.g:

常用numpy的函数汇总_第1张图片

numpy.eye(N,M=None, k=0, dtype=, order='C')
//return a 2-D array with ones on the diagonal and zeros else where

e.g

常用numpy的函数汇总_第2张图片

np.zeros(shape, dtype=float, order='C')
//return a new array of given shape and type, filled with zeros

e.g

常用numpy的函数汇总_第3张图片

np.random.randint(low, high=None, size=None, dtype='l')
//return random integers from low(inclusive) to high(exclusive)

e.g

常用numpy的函数汇总_第4张图片

常用numpy的函数汇总_第5张图片

np.mod(x1, x2, /, out=None, *, where=True, casting='same_kind', order='K', \
dtype=None, subok=True[, signature, extobj]) = 
//return element-wise remainder of division

e.g

常用numpy的函数汇总_第6张图片

你可能感兴趣的:(机器学习,强化学习,深度学习)