- 博客(4)
- 收藏
- 关注
原创 numpy.isin()
numpy.isin(element, test_elements, assume_unique=False, invert=False) Calculates element in test_elements, broadcasting over element only. Returns a boolean array of the same shape as element that i...
2018-11-05 21:27:30 3154
原创 numpy.where()
numpy.wherenumpy.where(condition, [x, y])Return elements, either from x or y, depending on condition.满足条件(condition),输出x,不满足输出yIf only condition is given, return condition.nonzero().Parameters: ...
2018-11-05 21:00:00 283
原创 numpy.cumsum()
numpy.cumsum(a, axis=None, dtype=None, out=None)axis=0,按照行累加。axis=1,按照列累加。axis不给定具体值,就把numpy数组当成一个一维数组。现在看一看例子a = np.arange(6).reshape((2, 3))a = [[0, 1, 2],[3, 4, 5]]要是直接numpy.cumsum(a),得到[ ...
2018-11-04 13:44:42 3851
转载 numpy.random
Numpy.randomrandom模块用于生成随机数,下面看看模块中一些常用函数的用法:转载于https://blog.csdn.net/kancy110/article/details/69665164/,这只是给我自己的学习做下点记录,以后找东西也方便。numpy.random.rand(d0, d1, …, dn):生成一个[0,1)之间的随机浮点数或N维浮点数组。#numpy...
2018-11-03 23:11:05 305
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人