简介:
用法:
numpy.einsum(subscripts, *operands, out=None, dtype=None, order='K', casting='safe', optimize=False)
- 函数作用:
将向量插入某一行或列
- 参数说明:
subscripts:str
指定求和的下标
operands : list of array_like
out : {ndarray, None}, optional
dtype : {data-type, None}, optional
order : {‘C’, ‘F’, ‘A’, ‘K’}, optional
casting : {‘no’, ‘equiv’, ‘safe’, ‘same_kind’, ‘unsafe’}, optional
optimize : {False, True, ‘greedy’, ‘optimal’}, optional
- 返回值:output : ndarray
具体的参数说明见:https://docs.scipy.org/doc/numpy/reference/generated/numpy.einsum.html#numpy.einsum
- 例子: