Creating a simple image classifier with AutoKeras
Image classification must be the de facto application of neural networks for computer vision. However, as we know, depending on the complexity of the dataset, the availability of information, and countless other factors, the process of creating a proper image classifier can be quite cumbersome at times.
In this recipe, we'll implement an image classifier effortlessly thanks to the magic of AutoML. Don't believe me? Let's begin and see for ourselves!
How to do it…
By the end of this recipe, you'll have implemented an image classifier in a dozen lines of code or less! Let's get started:
- Import all the required modules:
from autokeras import ImageClassifier from tensorflow.keras.datasets import fashion_mnist as fm
For the sake of simplicity, we'll use the well-known
Fashion-MNIST
dataset, a more challenging version of the famousMNIST
. - Load the train and test data:
(X_train, y_train...