对于一个图像:
import matplotlib.image as mi
if __name__ == '__main__':
img = mi.imread('fl.jpg')
print(img.shape)
print(img.shape[0])
print(img.shape[1])
print(img.shape[2])
对于一个图像:
import matplotlib.image as mi
if __name__ == '__main__':
img = mi.imread('fl.jpg')
print(img.shape)
print(img.shape[0])
print(img.shape[1])
print(img.shape[2])