mgrid

numpy中的一个函数叫mgrid

例子

import numpy as np

[X, Y] = np.mgrid[0:1.1:1 / 7., 0:1.1:1 / 7.]

# print(X.shape)

#print(X)

print(Y.shape)

print(Y)

生成两个8*8的矩阵

numpy中mgrid与meshgrid的区别

https://blog.csdn.net/tymatlab/article/details/79027162

扫描二维码关注公众号,回复: 2386079 查看本文章

https://blog.csdn.net/u013534498/article/details/51399035

猜你喜欢

转载自blog.csdn.net/zhuimengshaonian66/article/details/81208786
今日推荐