機器學習的貓狗識別代碼時,發生的錯誤
plt.figure(figsize=(15, 10)) # 圖形的寬為15高為10
for images, labels in train_ds.take(1):
for i in range(8):
ax = plt.subplot(5, 8, i + 1) plt.imshow(images[i]) plt.title(class_names[labels[i]]) plt.axis("off")plt.figure(figsize=(15, 10)) # 圖形的寬為15高為10
InvalidArgumentError: Number of channels inherent in the image must be 1, 3 or 4, was 2
[[{ {node decode_image/DecodeImage}}]] [Op:IteratorGetNext]
<Figure size 1080x720 with 0 Axe