Brand Detection in the Images

Learn to perform brand detection in images using Azure Computer Vision service.

We'll cover the following

Introduction

In this lesson, we’re going to build a script that will detect the brand logos in the images. Brand detection uses hundreds of thousands of logos available in a global database. The Computer Vision API identifies the brands in the images or videos and then return the brand name, the confidence score and the bounding-boxthe co-ordinates where the brand logo is present in the image as a JSON response.

Implementation

We’ll again be using the analyze_image() function from the ComputerVisionClient class. We’ll pass the URL of an image and in this lesson, we’ll only pass brands as the feature to be extracted as we want to identify the brand logos present in the image.

Similarly, we can also use the analyze_image_in_stream() function if we’re reading the image from the local machine and then pass the image in bytes format to this function as a parameter.

Let’s move on to the implementation of this functionality.

Get hands-on with 1400+ tech skills courses.