Retrievimage - online image retriever
Nguyen, Tuan (2023)
Nguyen, Tuan
2023
All rights reserved. This publication is copyrighted. You may download, display and print it for Your own personal use. Commercial use is prohibited.
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:amk-202304145272
https://urn.fi/URN:NBN:fi:amk-202304145272
Tiivistelmä
The purpose of this project was to provide a solid foundation of knowledge on image retrieval systems, including necessary theoretical definitions, components of such applications, and basic concepts of image retrieval. More specifically, it aimed to create a schema, some instructions, and a starting point to quickly pick up for prototyping machine learning models. From that, the idea of an online platform that was able to match the target with its equivalent in the set, given a collection of images and a query image, was decided.
To achieve this, Python 3 was chosen as the main programming. The application was structured according to a pipeline that was particularly designed to integrate machine learning models into web applications, and further on, continuous delivery for machine learning. However, instead of training a model from end-to-end, Transfer Learning was introduced, and the idea of using a pre-trained model was considered better and saved time and resources. The pre-trained model put into use was from OpenVINO, an open-source toolkit boosting the performance of machine learning models significantly. The program was meant to be set up as an online service running on a server that could handle uploads of images from users, and exchange information with them via API endpoints. Every time the app was shut down, it automatically erased all the stored data, so there was no need to implement authentication functionality at the moment. The server was developed in Python with Flask as the web framework, and the Jinja2 template engine for rendering the user interface.
In the end, the web application was able to achieve the initial goals set for it. At the bare minimum, the expected counterpart of the target image was successfully found by the image retrieval model, with satisfactory accuracy, then presented on the website's front end. Literature in the field, journals, books, articles, and research papers were studied and referenced for conceptual sections of this thesis. On the other hand, on some occasions, the model failed to capture the expected result, as images were not uniformly pre-processed before being fed into the model. It was plain to see that larger image batches required more predicting and rendering time. Examples were described to demonstrate the work in the Appendix section. From this, remarks were given, and enhancements were suggested to improve the overall production of this online image retriever.
To achieve this, Python 3 was chosen as the main programming. The application was structured according to a pipeline that was particularly designed to integrate machine learning models into web applications, and further on, continuous delivery for machine learning. However, instead of training a model from end-to-end, Transfer Learning was introduced, and the idea of using a pre-trained model was considered better and saved time and resources. The pre-trained model put into use was from OpenVINO, an open-source toolkit boosting the performance of machine learning models significantly. The program was meant to be set up as an online service running on a server that could handle uploads of images from users, and exchange information with them via API endpoints. Every time the app was shut down, it automatically erased all the stored data, so there was no need to implement authentication functionality at the moment. The server was developed in Python with Flask as the web framework, and the Jinja2 template engine for rendering the user interface.
In the end, the web application was able to achieve the initial goals set for it. At the bare minimum, the expected counterpart of the target image was successfully found by the image retrieval model, with satisfactory accuracy, then presented on the website's front end. Literature in the field, journals, books, articles, and research papers were studied and referenced for conceptual sections of this thesis. On the other hand, on some occasions, the model failed to capture the expected result, as images were not uniformly pre-processed before being fed into the model. It was plain to see that larger image batches required more predicting and rendering time. Examples were described to demonstrate the work in the Appendix section. From this, remarks were given, and enhancements were suggested to improve the overall production of this online image retriever.