By: Zeineb Ghrib
In this tutorial, you will learn how to use the Prevision.io UI interface to build a powerful image classifier without an advanced technical background. The machine Pipeline process is fully automated thanks to the Prevision.io platform.
The dataset used for this example is composed of images of different components of a train:
Each image is associated with a label from 4 classes:
Image classification is a supervised learning problem: each image is labelled with its corresponding name, and then the classifier is trained to recognize them using the labeled pictures.
In order to launch a Prevision AutoML experiment to the an image dataset, you need to follow these steps:
Visit www.prevision.io > Click Free Trial
In order to launch a new experiment, create a project or select an existing one so that you can gather experiments by type or by shared users.
To create a new project click on “New Project” on the corner right of the interface:
Then you add the name of the project and optionally a description as shown below then click on “Create” button:
An “Image Folder” is a ZIP containing images that will be used to train models. To upload the folder, all you have to do is to select “Image folders” tab on the head of the dataset section, then drag and drop into the image box (see figure below)
In order to launch the experiment, you also need to provide a csv that would carry out the mapping between the images (available in the image folder) and their corresponding labels. It should contain, at least:
the filename: relative path to images within the image folder
the target : the corresponding label
Since Prevision.io also supports exogenous features for images experiments, this tabular dataset may also contain features that can be used as predictors to the models (temperature, nebulosity, time stamp of the picture, camera brand…)
To upload the dataset, you pick the “Datasets” tab, click on “Import dataset” button, then pick the “Import file” option:
As we deal with a multi-labelled dataset, it is a multi-classification training type: to launch the experiment go to:
Click blue button ‘New experiment’
Select the ‘AutoML’ mode
Data type: ‘Images’
Training type: ‘Multi-Classification’
Choose a name to the experiment
Then launch the experiment by clicking on “Create Experiment”. Before launching the experiment, some settings are required:
Select the pre-imported dataset and the Image folder
2. Then chose the training options:
The metric that will be used to train the models
The training profile (Quick, Normal or Advanced)
3. Then configure the target and the images path columns by choosing the corresponding features:
4. To configure the other experiment’s parameters (models, feature engineering ops…), you can browse the other tabs:
Note that this step is optional: the platform provides reasonable default settings for all the training types, making it easy to quickly create baseline experiments.
Once the experiment is launched, the platform performs several computations on the image dataset to extract images “embeddings” that will be used as input instead of the initial images. These embeddings are numerical vectors that carry efficient representation of the initial image input.
The image embedding operation is performed for two reasons:
Transform the images into numerical vectors that are more ‘appreciated’ by the models: in fact numeric input is less sophisticated than images pixels
Reduce the dimensionality of the data input
Once the experiment process finished, you can visualize the new generated embedding-features (even if it’s hard to find a nice name for them 🙃):
To make a Prediction on new images: you have to:
1. Upload the ZIP of images you want to predict creating a new Prevision.io image folder (step 2)
2. Upload the corresponding csv ( as explained on step 3)
3. Go to the prediction tab, choose your model and launch the predictions:
In step 4 (see figure above) after launching the prediction, a line will appear within the ‘User Generated Predictions’ tab’. Once the status is done you can download the prediction file (step 5).
In this post you learned how to use Prevision.io, to create an image classification experiment, in a future post I will show you how to use the platform to create an ‘object-detection’ experiment. If you have any issues or need help, please contact me here.
Prevision.io brings powerful AI management capabilities to data science users so more AI projects make it into production and stay in production. Our purpose-built AI Management platform was designed by data scientists for data scientists and citizen data scientists to scale their value, domain expertise, and impact. The platform manages the hidden complexities and burdensome tasks that get in the way of realizing the tremendous productivity and performance gains AI can deliver across your business