By Sunny Jovita, Solution Architect Intern
Are you tired of endlessly scrolling through pages of search results, trying to find that similar or identical images within your database? Have you ever wished for a more efficient way to discover visually similar pictures? Look no further than Alibaba Cloud Image Search, a cutting-edge platform that harnesses the power of deep learning and computer vision to revolutionize your image search experience!
Alibaba Cloud Image Search is not your ordinary search engine. It goes beyond simple keyword queries and brings you a whole new level of search precision. With Image Search, you can build your own personalized image search engine. It’s like having your own curated gallery of visually similar images at your fingertips. But how does Image Search work? By leveraging the advanced deep learning algorithms, Image Search analyzes the unique features of your uploaded image and swiftly scours to the database to retrieve the most relevant matches. No more sifting through countless irrelevant results, Alibaba Cloud Image Search takes you straight to the heart of what you are looking for.
What sets Alibaba Cloud Image Search apart from other image search platform is its adaptability. It can be seamlessly integrated into a wide range of scenarios: such as API integration, utilizing SDK with various programming languages available, upload data using batch operation, etc. This makes it an indispensable tool for various applications. Are you an avid online shopper? Imagine using Image Search for snap shopping, where you can find the exact product you desire by just uploading an image. Looking for a product recommendations? Image Search can effortlessly provide suggestions based on visually similar images. And when it comes to copyright protection, Alibaba Cloud Image Search helps safeguard your valuable assets by identifying potential infringements.
One of the most interesting benefits of Image Search, it can be used for copyright protection by enabling users to track and identify potential infringements of their copyright images. Here’s how it works:
Now, let’s delve into an exciting application of Image Search: identifying jewelry for SKU checks. In this blog, we will guide you through a step-by-step tutorial on harnessing the power of Alibaba Cloud Image Search to effortlessly search and match the jewelry items.
Before we dive into the utilization of Alibaba Cloud Image Search for jewelry SKU checks, let’s take a moment to familiarize ourselves with the data collection process and the jewelry samples we will be working with.
Within this exploration, we provide such amount of jewelry samples as we can see in the pictures above. The images provided showcase different patterns and designs of jewelries. To ensure accurate and reliable search results, we have collected the following jewelry sample:
- Pendants: we have chosen 20 pendant samples, consisting of 10 gold pendants and 10 silver pendants. Each pendant possesses its own unique pattern that make it a perfect candidate for our image search.
- Rings: our collection includes 12 gold rings.
- Necklaces: we have handpicked 20 necklaces (gold and silver) to add to our dataset. Each necklace exhibits its own distinct style, ranging from chains which offers a diverse array of options to explore.
With this raw dataset in hand, our next crucial step was to preprocess the data, ensuring optimal search performance. We cleaned each image by removing distracting backgrounds and adjusting the light conditions to create a clear and standardized dataset. This process allows for more accurate image analysis and comparison, enhancing the effectiveness of Alibaba Cloud Image Search.
Now that we have refined out data, we are ready to leverage Alibaba Cloud Image Search to unlock the full potential of identifying the jewelry collection.
Let’s start to explore how’s the implementation of Image Search in real world case. It begins with a user searches an image in the web server. It will send an api request into Alibaba cloud image search engine. The image search the similar / identical products by using image index. After that it will give the product id list into the web server, the original images folder and database will be retrieved to the web server also. Then it will give back the similar or identical list of products to the user.
Let’s start to explore how’s the implementation process of Image Search in a real-world scenario.
By seamlessly integrating Alibaba Cloud Image Search, businesses, whether it’s e-commerce platforms, product recommendations, or copyright protection can provide their users with an intuitive and visually driven search experience, enhancing engagement, satisfaction, and ultimately driving conversions.
Before we begin utilizing Alibaba Cloud Image Search, let’s create an instance for it. To activate Image Search, please follow the instructions provided at https://www.alibabacloud.com/help/en/image-search/latest/activate-image-search. By following those steps, you will successfully create an instance for Alibaba Cloud Image Search. With your instance up and running, you can proceed to explore the features and functionalities of Image Search, such as uploading and indexing your image database.
After activating the instance, we can proceed to upload images into the database. There are multiple ways to add images:
For this tutorial, we will be using batch operations. We have already uploaded the clean data into OSS. Now, we can start inputting the test image to find similar or identical results.
After completing the image instance upload process, we can navigate to the instance details page to input the image.
If the image input is successful, it will return a JSON response similar to the following:
However, if there is an error during the process, an error output will be returned, indicating the need to reconfigure the length or width of the image. An example of an error response is as follows:
This responses provide valuable information about the status of the image input operation, allowing you to troubleshoot and make necessary adjustments if needed.
After uploading all the testing images to the Alibaba Cloud Image Search platform, we obtained the following results:
[Less Accurate] Results
However, there were some less accurate results during the testing:
Rings and pendants were detected well, however, difficulties arose when detecting necklaces due to their similar chain or necklace patterns. To address this, we implemented a new approach to enhance necklace detection.
Among these various necklaces, we modified the method by focusing solely on the necklace patterns to optimize the dataset.
Despite our efforts, accurately detecting necklaces proved challenging due to their wide shape, lower resolution images, and small pattern details. However, Image Search still identified the product as a necklace jewelry, distinguishing it from rings or pendants.
Our exploration didn’t stop there. To achieve optimal results, we expanded our sample size and continued optimizing the identification of jewelries.
Regarding the second dataset, we have a sample dataset called “foto_dataset”. Within this dataset, there are a total of 305 items, each featuring different angles and lightning conditions. For this dataset, the background was not removed, and it serves as the reference dataset for our analysis.
Approach 1: All the images were put in the database as bulk image (not organized the image based on their product name).
In this first approach, we try to put all the images into 1 dataset without using any additional folder within it. In other words, within the OSS bucket, it will have 1 folder called jewelry_demo, and all the images will be stored within it without organizing it according to their name.
After using the same procedure (batch operation) to store the jewelries images, we start to use ‘test_dataset’ for the input images. The ‘test_dataset’ looks like this with 119 items in total with different distance and lighting:
[Accurate] Results:
Although the results already return accurate and identical values, we decided to implement a new approach to optimize the usage of Image Search.
We applied augmentation techniques such as flip, rotate, brightness adjustment, and blurring to increase the similarity scores.
As a result, utilizing augmentation significantly improved accuracy and average confidence levels in terms of similarity scores.
Conclusions:
After conducting these explorations, we conclude that implementing a standard procedure for input images is crucial to obtain desired outputs. Additionally, having a clean dataset serves as a necessary requirement for establishing a reliable reference dataset.
Leverage your CI/CD pipeline by Autoscaling Jenkins Agent with Alibaba Cloud
96 posts | 13 followers
FollowAlibaba Cloud Community - June 9, 2023
Alibaba Clouder - February 14, 2019
Rupal_Click2Cloud - December 15, 2023
Alibaba Clouder - November 27, 2018
ITDSN - May 11, 2020
Alibaba Cloud MaxCompute - September 7, 2022
96 posts | 13 followers
FollowAn intelligent image search service with product search and generic search features to help users resolve image search requests.
Learn MoreOpenSearch helps develop intelligent search services.
Learn MoreHelp media companies build a discovery service for their customers to find the most appropriate content.
Learn MoreThis technology can assist realizing quantitative analysis, speeding up CT image analytics, avoiding errors caused by fatigue and adjusting treatment plans in time.
Learn MoreMore Posts by Alibaba Cloud Indonesia