We often need to work within the image directly and not as an array vector. This section will guide us through converting our arrays to .png images.
Pain Point #3: Exporting MNIST images as files
Getting ready
Exporting the vectors to images requires importing the following library:
- import image from matplotlib
How to do it...
This section walks through the steps to convert a sample of MNIST arrays to files in a local folder.
- Create a subfolder to save our images to our main folder of MNIST/ using the following script:
if not os.path.exists('MNIST/images...