ALPR Back From The Dead!

Discussions related to the 1.36.x series of ZoneMinder
Post Reply
Quantum
Posts: 124
Joined: Fri Mar 25, 2011 3:34 pm

ALPR Back From The Dead!

Post by Quantum »

I know you've tried, and lord knows I've tried, but the fact is they stopped working on ALPR eight years ago and there's nothing anyone can do about it. :P

First of all IANAC. ('I am not a Coder') But I have run Linux to the extremes since 1997, and I'm currently running Debian 12.9. I have managed to flange and patch up ALPR so you can again have the executable and daemon, with all the utilities! Local, just as (your) god(s) intended.

Here are my notes:
ALPR
https://github.com/openalpr/openalpr/wi ... untu-Linux

# cd /home/{user}/src
# git clone https://github.com/openalpr/openalpr.git
# apt install libopencv-dev libtesseract-dev tesseract-ocr-eng cmake build-essential libleptonica-dev liblog4cplus-dev beanstalkd
NOTE: libtesseract-dev is missing old thresholder.h and platform.h so put them in /usr/include/tesseract/

# git clone https://github.com/openalpr/openalpr.git
# cd openalpr/src && mkdir build && cd build

# cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr/local -DCMAKE_INSTALL_SYSCONFDIR:PATH=/etc ..

# make
# make install
# ldconfig
To test:
# US Plate
wget http://plates.openalpr.com/ea7the.jpg
alpr -c us ea7the.jpg

# EU Plate
wget http://plates.openalpr.com/h786poj.jpg
alpr -c eu h786poj.jpg

# GB Plate
wget https://images.cdn.circlesix.co/image/1 ... 9d0727.jpg
(Oops, this site is down)
alpr -c gb b22c2b504ab94949ea0df2a8789d0727.jpg
The Secret Sauce is two files, which are no longer part of libtesseract-dev. I've managed to find substitutes which work and they are attached hereto. You must put these in /usr/include/tesseract/ where I say to above.

Your executable (alpr), daemon (alprd), and utilities (openalpr-utils-*) will end up in /usr/local/bin/ as per Posix standards.

When I figure out how to wrangle all of this I'll make further posts here.

Props to burger for giving that bit of encouragement when needed.
Attachments
thresholder.h
(7.82 KiB) Downloaded 252 times
platform.h
(2.16 KiB) Downloaded 250 times
User avatar
iconnor
Posts: 3297
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: ALPR Back From The Dead!

Post by iconnor »

nice work
Post Reply