diff --git a/README.md b/README.md index 0c9d8f2..0e9135c 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,123 @@ openalpr ======== -Automated License Plate Recognition library +OpenALPR is an open source *Automated License Plate Recognition* library written in C++. The library analyzes images and identifies license plates. The output is the text representation of any license plate characters found in the image. + +Check out a live online demo here: http://www.openalpr.com/demo.html + +User Guide +----------- + +OpenALPR includes a command line utility. Simply typing "alpr [image file path]" is enough to get started recognizing license plate images. + +``` +user@linux:~/openalpr$ alpr --help + +USAGE: + + alpr [-t ] [-r ] [-n ] + [--seek ] [-c ] + [--clock] [-d] [-j] [--] [--version] [-h] + + + +Where: + + -t , --template_region + Attempt to match the plate number against a region template (e.g., md + for Maryland, ca for California) + + -r , --runtime_dir + Path to the OpenAlpr runtime data directory + + -n , --topn + Max number of possible plate numbers to return. Default=10 + + --seek + Seek to the specied millisecond in a video file. Default=0 + + -c , --country + Country code to identify (either us for USA or eu for Europe). + Default=us + + --clock + Measure/print the total time to process image and all plates. + Default=off + + -d, --detect_region + Attempt to detect the region of the plate image. Default=off + + -j, --json + Output recognition results in JSON format. Default=off + + --, --ignore_rest + Ignores the rest of the labeled arguments following this flag. + + --version + Displays version information and exits. + + -h, --help + Displays usage information and exits. + + + (required) Image containing license plates + + + OpenAlpr Command Line Utility +``` + +For example, the following output is created by analyzing the plate image at this URL: http://www.openalpr.com/images/demoscreenshots/plate3.png + +The library is told that this is a Missouri (MO) license plate which validates the plate letters against a regional template. + +``` +user@linux:~/openalpr$ alpr ./samplecar.png -t mo -r ~/openalpr/runtime_dir/ + +plate0: top 10 results -- Processing Time = 58.1879ms. + - PE3R2X confidence: 88.9371 template_match: 1 + - PE32X confidence: 78.1385 template_match: 0 + - PE3R2 confidence: 77.5444 template_match: 0 + - PE3R2Y confidence: 76.1448 template_match: 1 + - P63R2X confidence: 72.9016 template_match: 0 + - FE3R2X confidence: 72.1147 template_match: 1 + - PE32 confidence: 66.7458 template_match: 0 + - PE32Y confidence: 65.3462 template_match: 0 + - P632X confidence: 62.1031 template_match: 0 + - P63R2 confidence: 61.5089 template_match: 0 + +``` + +Compiling +----------- + +OpenALPR has been compiled successfully on Linux, however other operating systems should also work. + +OpenALPR requires the following additional libraries: + + - Tesseract OCR v3.x (https://code.google.com/p/tesseract-ocr/) + - OpenCV v2.4.x (http://opencv.org/) + +After cloning this GitHub repository, you should download and extract Tesseract and OpenCV source code into their own directories. Compile both libraries. + +Update the src/CMakeLists.txt file in the OpenALPR project. Update the following lines to match the directories of your libraries on your system: + - SET(OpenCV_DIR "../libraries/opencv/") + - SET(Tesseract_DIR "/home/mhill/projects/alpr/libraries/tesseract-ocr") + +Finally, in the src directory, execute the following commands: + - cmake ./ + - make + +If all went well, there should be an executable named *alpr* along with *libopenalpr.a* that can be linked into your project. + + +Questions +--------- +Please post questions or comments to the Google group list: https://groups.google.com/forum/#!forum/openalpr + +License +------- + +Affero GPLv3 +http://www.gnu.org/licenses/agpl-3.0.html + +