GithubHelp home page GithubHelp logo

xhappy / selective-search Goto Github PK

View Code? Open in Web Editor NEW

This project forked from saisrivatsan/selective-search

0.0 2.0 0.0 3.81 MB

selective-search for object recognition

Python 2.63% Jupyter Notebook 97.37%

selective-search's Introduction

Object Recognition using Selective Search (Python Implementation) + R-CNNs

Created by Sai Srivatsa Ravindranath

Introduction

Selective Search is an object proposal algorithm which combines the strength of both exhaustive search and segmentation. We provide a python implementation of selective search. We also integrate it with fast-rcnn, which uses these proposals for object detection.

Contents

  1. Installation
  2. Demo

Installation

  1. Python Packages : numpy, scikit-image, scipy, scikit-learn, matplotlib

    pip install <package-name>
  2. Clone the selective search repository

git clone https://github.com/saisrivatsan/selective-search.git
  1. Install fast-rcnn. (see: fast-rcnn installation instructions) and download pre-computed Fast R-CNN detectors.

Demo

Open ipython and run the following commands

# Demo: Object Recognition with Selective Search and RCNN
# Append fast-rcnn directories to python path
import sys
sys.path.append('fast-rcnn/tools/')
import recognition
image_name = '000846'
# Select custom parameters for the demo
# Select colorspaces
color_space_list = ['HSV','LAB']
# Select thresholds for segmentation
ks = [50,100]
# Use default similarity features i.e C+T+S+F ans T+S+F 
# Default cpu_mode = True, Disable it if you have GPUs
# Default Net = 'vgg16'. Refer fast-rcnn module for other model
# Display selected image
import matplotlib.pyplot as plt
%matplotlib inline
plt.imshow(plt.imread('Data/img/' + image_name + '.jpg'))

png

# Call demo, Run with only image_name as parameter for fast mode ssearch
recognition.demo(image_name,color_space_list=color_space_list,ks=ks)
. . . . . . . . 
Computed 1445 proposals


Loaded network /home/sai/Documents/Projects/selective_search/fast-rcnn/data/fast_rcnn_models/vgg16_fast_rcnn_iter_40000.caffemodel
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Demo for 000846.jpg
Detection took 33.032s for 1445 object proposals
All aeroplane detections with p(aeroplane | box) >= 0.8
All bicycle detections with p(bicycle | box) >= 0.8
All bird detections with p(bird | box) >= 0.8
All boat detections with p(boat | box) >= 0.8
All bottle detections with p(bottle | box) >= 0.8
All bus detections with p(bus | box) >= 0.8
All car detections with p(car | box) >= 0.8
All cat detections with p(cat | box) >= 0.8
All chair detections with p(chair | box) >= 0.8
All cow detections with p(cow | box) >= 0.8
All diningtable detections with p(diningtable | box) >= 0.8
All dog detections with p(dog | box) >= 0.8
All horse detections with p(horse | box) >= 0.8
All motorbike detections with p(motorbike | box) >= 0.8
All person detections with p(person | box) >= 0.8
All pottedplant detections with p(pottedplant | box) >= 0.8
All sheep detections with p(sheep | box) >= 0.8
All sofa detections with p(sofa | box) >= 0.8
All train detections with p(train | box) >= 0.8
All tvmonitor detections with p(tvmonitor | box) >= 0.8

png

selective-search's People

Contributors

saisrivatsan avatar

Watchers

James Cloos avatar xhappy avatar

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.