灰度图片维度与彩色图片维度-python-scikit-image包
发布日期:2021-05-06 21:48:22 浏览次数:19 分类:技术文章

本文共 394 字,大约阅读时间需要 1 分钟。

from skimage import io,data,colorimport matplotlib.pyplot as pltimg=data.chelsea()print(img.shape)#img = color.rgb2gray(img)#print(type(img))#print(img.shape)io.imshow(img)plt.show()

输出结果,如图所示:

from skimage import io,data,colorimport matplotlib.pyplot as pltimg=data.chelsea()print(img.shape)img = color.rgb2gray(img)print(type(img))print(img.shape)io.imshow(img)plt.show()

 

 

灰色的维度就是一维的,彩色的维度是三维的 

上一篇:numpy+cnn
下一篇:vim 有用命令-20190217

发表评论

最新留言

表示我来过!
[***.240.166.169]2025年04月05日 06时45分07秒