Skip to content

Instantly share code, notes, and snippets.

@lockdef
Created April 10, 2019 02:24
Show Gist options
  • Save lockdef/95ef4e10c1ad453864da81da042fbfb1 to your computer and use it in GitHub Desktop.
Save lockdef/95ef4e10c1ad453864da81da042fbfb1 to your computer and use it in GitHub Desktop.
MNISTをプロットする
from sklearn.datasets import load_digits
import matplotlib.pyplot as plt
data = load_digits()
for num, image, label in zip(range(10), data.images[:10], data.target[:10]):
plt.subplot(2, 5, num+1)
plt.imshow(image)
plt.title(label)
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment