An important issue today is being able to create value from the data that you have. As you might know, IBM has been a pioneer in the field of artificial intelligence and machine learning. And, as part of IBM Cloud, IBM provides a set of Watson APIs that are available for anyone to use. These APIs include Watson Assistant (a chatbot building platform), natural language processing engines, and more. This article discusses one Watson API in particular, Watson Visual Recognition.

The Watson Visual Recognition API lets you use visual data to gain information about the data in the image. A few of its models are:

  • General model: A trained model that lets you use an active and large data set to gain insights from your own pictures.
  • Food model: Similar to the general model, but this model uses a specific food data set. You can use the model to find any type of food, and one of the main applications is in the catering and restaurant industry, especially if you want to create a specific menu.
  • Face model: Allows you to analyze a face in the model, get the gender and the age of the person in the picture, and if it’s someone famous, give you that person’s name. With this model, you can analyze your data and create special features for your product.
  • Explicit model: Allows you to analyze whether an image contains inappropriate content.
  • Text model: Allows you to extract text from a picture and have a textual metadata. This option is currently in private beta, but you can sign up for it.
  • Custom model: Lets you create a custom model with your own pictures and train it to get better results.

Using Watson Visual Recognition

Each instance of the Visual Recognition service comes with an API key that lets you call the API by creating and using a connection. The API supports many different coding languages such as Java™, Node.js, and Python. The tool would be similar to the following image.

flow

You can see all the models that I mentioned.

In the Overview section, you can see the credentials of the service, including the API key.

flow

When you click Test on one of the models, the front page of that model opens. There you can find all of the information about the model such as how many data sets of pictures you have and how many pictures you uploaded.

When you click Implementation, you get code to help you implement this API into your code.

flow

After setting up your instance, what’s next? Basically, you start training your custom model or use the general model. The minimum number of pictures that you need to train a custom model is two data sets of 10 pictures, but I recommend that you upload more pictures to get a better result.

A few things that you should know before starting:

  • It’s inexpensive. You get more for your money, and you get really nice results.
  • To make your data make more sense, don’t be tight on the pictures. Upload a few data sets of pictures with more than 50 pictures each. It refines your results even more.
  • Don’t be afraid to try new things with this service. For example, this service also gives you the option of identifying colors, which can help you use it for even more implementations.

Conclusion

The Watson Visual Recognition service lets you quickly and accurately tag, classify, and train visual content by using machine learning. The API provides general models as well as models that you can customize, and it’s inexpensive and easy to use. Give it a try.