Before we dive into CNNs, let's look at the major problem that's faced when using traditional deep neural networks.
Let's reconsider the model we built on the Fashion-MNIST dataset in Chapter 3, Building a Deep Neural Network with PyTorch. We will fetch a random image and predict the class that corresponds to that image, as follows:
The code for this section is available as Issues_with_image_translation.ipynb in the Chapter04 folder of this book's GitHub repository - https://tinyurl.com/mcvp-packt . Note that the entire code is available in GitHub and that only the additional code corresponding to the issue of image translation will be discussed here for brevity. We strongly encourage you to refer to the notebooks in this book's GitHub repository while executing the code.
- Fetch a random image from the available training images:
# Note that you should run the code in
# Batch size of 32 section in Chapter 3
# before...