Git Product home page Git Product logo

mergevec's Introduction

mergevec

Update (20/05/15): This approach worked for my purposes, but a few people have raised concerns that using artificial data is not the best way to train a classifier [1]. As such, I would recommend approaching this method with a fair amount of skepticism.

Mergevec.py is used to merge .vec files for use in training a cascade classifier with openCV's opencv_traincascade. This code was made as replacement for mergevec.cpp (created by Naotoshi Seo. See: http://note.sonots.com/SciSoftware/haartraining/mergevec.cpp.html) in order to avoid recompiling opencv with mergevec.cpp.

#To use mergevec.py:

(1) Place all .vec files to be merged in a single directory ("vec_directory").
(2) Download mergevec.py
(3) Navigate to mergevec.py in your CLI (terminal or cmd) and enter "python mergevec.py -v your_vec_directory -o your_output_filename.vec".

#To test the output of mergevec.py:

(1) Install openCV.
(2) Navigate to the output file in your CLI (terminal or cmd).
(3) Type "opencv_createsamples -w img_width -h img_height -vec your_output_filename.vec". This should show the .vec files in sequence.

The aggregate .vec output from mergevec.py has successfully been used to train a cascade. See the below for resources on training cascade classifiers. #opencv_traincascade Resources

[1] Counterargument: http://answers.opencv.org/question/55879/opencv-mergevec-haartraining-issues/

[2] OpenCV: http://docs.opencv.org/doc/user_guide/ug_traincascade.html

[3] Naotoshi Seo: http://note.sonots.com/SciSoftware/haartraining.html

[4] Coding Robin: http://coding-robin.de/2013/07/22/train-your-own-opencv-haar-classifier.html

[5] StackOverflow: http://stackoverflow.com/questions/16058080/how-to-train-cascade-properly

mergevec's People

Contributors

wulfebw avatar

Watchers

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