Teachable Machine — Google’s No code Machine Learning Platform

Sagar Jiyani
Apr 16 · 4 min read

Overview:

Teachable Machine is Google’s AutoML platform which is a web-based tool that makes creating machine learning models fast, easy, and accessible to everyone. You can build models to classify images, audios, or even poses. After doing the same, you can download the trained model and use it for your applications.

In this article, I’m going to walk you through making a machine learning model to classify the Monkey Breeds. It is a basic image classification problem. So to get started, I’ll go to Teachable Machine and open up an image project.

Labeling the Data:

First of all, we need to collect the data to train the model. In this article, I have used a 10 Monkey Species dataset which is publically available on Kaggle. In TeachableMachine you can also create the dataset by clicking the pictures by using a webcam as well.

Dataset: 10 Monkey Species

To start training the machine learning model, we first have to create different categories, or classes, to teach it with. I’m going to create10 classes here for 10 species of monkey and also uploading the images to the respective class.

Now that I have all of my classes ready with the sample images, I can go further to train the model…

Train:

After collecting the data, we can train the model by just clicking a single button. With the help of TeachableMachine, there is no need to do any smoothing or pre-processing, Teachable Machine will train a model based on the examples you provided. All the training happens in our browser, so everything stays on our computer. Then instantly test it out to see whether it can classify new samples as per prior input used for training.

As shown in the above picture, in the advanced options, we can change the number of epochs to train, batch size, and learning rate as per our requirements. In this classification problem, I set the number of epochs to 100, batch size to 32, and learning rate as default.

Preview:

After successfully training the model, we can test the model from the preview pane. In the preview pane, there are two options to predict the image class like by using the file or a webcam. So in this example, we will choose as a file and try to make the predictions.

As we can see in the above figures model is performing very well on the test dataset.

Export:

We can also export our trained model for our projects: websites, Application, and more. We can download our trained model or host it online for free from this.

As shown in the above image there are main three options like Tensorflow.js, Tensorflow, and Tensorflow Lite. So we can export or download our model based on our requirements.

Working behind Teachable machine:

Teachable Machine uses Tensorflow.js, a library for machine learning in Javascript, to train and run the models you make in your web browser. Look at the Teachable Machine library built on top of Tensorflow.js on GitHub.

These models use a technique called transfer learning. There’s a pre-trained neural network, and when you create your own classes, you can sort of picture that your classes are becoming the last layer or step of the neural net. Specifically, both the image and pose models are learning off of pre-trained mobile net models, and the sound model is built on Speech Commands.

Advantages:

1. Easy to train and deploy.

2. Very little time taken to train the model.

3. open source so we can play with multiple classes.

4. Easy steps now such as ML knowledge require even if a child wants to make a model then he can and check it on new examples.

Disadvantages:

There are some situations where might your model isn’t working the way you want. Here are some examples:

1. Changing backgrounds/environments.

2. Framing your examples.

3. Changing microphones/spaces.

4. Capturing audio samples with high noise.

5. Understanding bias.

6. Confusing new examples.

Geek Culture

Proud to geek out. Follow to join our +1.5M monthly readers.