python學習筆記五:numpy

ndarray是一個多維數組的數據結構 1.彩色圖像是一個三維數組,通過matplotlib顯示圖像 #顯示圖像 import numpy as np import matplotlib.pyplot as plt fish = plt.imread('HappyFish.jpg') print(fish.shape) print(type(fish)) 運行結果: (194, 259, 3)
相關文章
相關標籤/搜索