Giter Club home page Giter Club logo

cbir-engine's Introduction

Content-based Image Retrieval Engine

In this job, I collaborated with Chayma Bouzaidi

Table of contents

  1. Overview
  2. Requirements
  3. Setting up MongoDB/GridFS
  4. Start the App

In this project, we built a content-based image retrieval engine that allows users to send a request image in order to display similar images from 1M images database stored in GridFs (MongoDB).🧐

To build this app, we followed this main steps:
       • Building feature vectors using Principal Component Analysis
       • Storing feature vectors and thumbnail images in MongoDB
       • Building a VP-Tree to optimize searching time
       • Setting an interactive web app using Flask

NB : You can get 1M thumbnail images database and corresponding edge histogram descriptors from here

       • MongoDB (version 4.2.1).
       • Python (version 2.7.15+).
       • Create a MongoDB database called CBIR.
       • Specify your MongoDB connection URL in the script app/app.py.
       • Go to app/ directory and install the requirements via pip :
             • pip install flask numpy scipy matplotlib scikit-image gunicorn.
             • pip freeze > requirements.txt.

       • Go to scripts/ directory and run toGridFs.py script in order to dump the Thumbnails, the Principal Components and the VP-Tree into GridFs :
             • python toGridFs.py -td <YOUR_THUMBNAILS_DIRECTORY> -id <YOUR_PC_VPTREE_DIRECTORY>.
NB : You can get the Principal Components and the VP-Tree files from here and here

       • Run python app/app.py to start the App.
NB : The list of query images is static. You can change it by hosting the thumbnails on a Free server and specifying the image URL in img tag in app/templates/index.html.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.