Giter Club home page Giter Club logo

rosyapril / diagnosing-object-detectors Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wk910930/diagnosing-object-detectors

0.0 1.0 0.0 6.97 MB

This project shows how to analyze the influences of object characteristics on detection performance and the frequency and impact of different types of false positives.

Home Page: http://dhoiem.web.engr.illinois.edu/projects/detectionAnalysis/

License: MIT License

TeX 5.58% MATLAB 91.99% Objective-C 0.25% M 2.18%

diagnosing-object-detectors's Introduction

Diagnosing Object Detectors

Citation

This project is modified from here. Please cite it in your publications if it helps your research:

@article{hoiem2012diagnosing,
  title={Diagnosing error in object detectors},
  author={Hoiem, Derek and Chodpathumwan, Yodsawalai and Dai, Qieyun},
  journal={Computer Vision--ECCV 2012},
  pages={340--353},
  year={2012},
  publisher={Springer}
}

Derek Hoiem July 30, 2012 (updated July 31, 2014)

This project contains the source code and annotations for analyzing object detectors with the PASCAL VOC 2007 dataset. The annotations were created by Yodsawalai Chodpathumwan in Spring 2010 and Fall 2011 as an undergraduate RA. The associated published paper is:

D. Hoiem, Y. Chodpathumwan, and Q. Dai, Diagnosing Error in Object Detectors, ECCV 2012.

How to Run

CASE I: PASCAL VOC 2007, felzenszwalb or vedaldi detectors

  1. In detectionAnalysisScript.m, set all flags on top to 1 (true) (note: DO_SHOW_SURPRISING_MISSES is optional)
  2. Set the imdir path to a valid directory of VOC images
  3. Run detectionAnalysisScript.m in Matlab

CASE II: PASCAL VOC 2007, your own detectors

  1. Create a text file of detector outfits with rows of file_id conf x1 y1 x2 y2 (standard format, see readDetections.m). Put this file in a subdirectory within detections.
  2. Add a corresponding entry to setDetectorInfo.m and update detector variable in detectionAnalysisScript.m.
  3. Perform all steps of CASE I.

CASE III: later versions of VOC Annotations are not currently available for detailed analysis of true detections.

  1. Modify setDatasetParameters.m:
    • Set the imdir, VOCsourcepath, and VOCset to correspond to the dataset
    • Set objnames_extra = {}; change objnames_extra in DISPLAY_TP to objnames_selected.
  2. Run as in CASE I or II

Case IV: other datasets If detections are bounding boxes and evaluation criteria is similar, use 'voc_compatible' as detector type and update setDatasetParameters.m. Otherwise, more modification may be required; see details in Code_Explanation.txt.

Creat A Report

  1. The tex file for a report will be created for you in results/detname/tex.
  2. Automatically remove whitespace from the figures using an Adobe Acrobat batch process or this script for pdfcrop from Ross Girshick:
       #!/bin/sh
       find . -name "*.pdf" -print0 | xargs -P6 -0 -I file pdfcrop file file
    
  3. Use a latex compiler on detectionAnalysisAutoReportTemplate to make the pdf.

Description of Folders

annotations: Contains annotations for objects (excluding "difficult" objects, as defined by VOC annotations). The file Labels.txt helps to explain the format. Each file also contains whether the object was detected by the Felzenszwalb or the Vedaldi detector and the corresponding confidence, but this need not be used.

src: Contains code for reading the annotations and storing them in the PASCAL VOC record structure. Also contains code for computing normalized average precision and making comparisons between different subsets of the data.

results: For each detector, contains tables of normalized AP for various subsets of data and comparison plots.

detections: For each detector, contains a list of all detections above some threshold for each object.

Description of Script/Functions

detectionAnalysisScript.m

  • TP_ANALYSIS: correlates detections with ground truth, assigns attributes such as occlusion and aspect to each object, and computes performance measures for various subsets of objects
  • FP_ANALYSIS: computes fraction of top false positives due to localization error, confusion with similar objects, etc.; also computes the AP impact of false positives
  • TP_DISPLAY: creates plots showing performance of detector for different subsets of objects, a summary plot, a text summary of characteristics of missed objects, and images of objects that are less confidently detected than expected
  • FP_DISPLAY: displays statistics of the frequency and impact of false positives, including creation of a table in a text file
  • DO_TEX: creates tex files for compiling a report

Other useful functions

Further Help

Contact [email protected] if there is a problem with the annotations or code. If instructions are unclear or incomplete, please try to figure it out first and send me a corrected version of the instructions. If you can't figure it out, email me, and I will help as time allows.

diagnosing-object-detectors's People

Contributors

wk910930 avatar

Watchers

James Cloos 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.