Dedicated License Plate Cam project

i was just using lpbcpu before, this should work with intel gfx.. in theory.
 
well, as I mentioned, i'm pretty sure i can get BI to provide an mjpeg stream somehow.
i mean that's pretty much how it's web UI works (for non-IE browsers), so i it should be do-able.
my huisun should be here this week, so i'll try to get set up to test that out...

Were you ever able to feed openalpr an mpeg stream from Blue Iris for the Huisun PTZ?
 
got OpenCL (Nvidia CUDA) working with ALPRD, and its way fucking fast..


Did you have to recompile OpenALPR?

Also does the VM move across to the GPU as well or do you still need the VM to hand the data off the the GPU for processing?
 
Last edited by a moderator:
I think I've been testing with the commercial version of alprd. To use the open source version must I compile it myself from github?
 
Last edited by a moderator:
yeah I had to rebuild everything, specifically I had to install Nvidia's Binary Installer and Cuda toolkit, then build the latest version of OpenCL w/Cuda enabled, then rebuild openalpr again from scratch.. I am running on bare metal now, this sucked pretty hard even on a really good vm server.

full color in the daytime, still doing realtime 20fps @ 4MP w/Mask
Code:
Thu May 19 15:04:04 2016       
+------------------------------------------------------+                       
| NVIDIA-SMI 352.39     Driver Version: 352.39         |                       
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 950     Off  | 0000:01:00.0     Off |                  N/A |
| 38%   45C    P0    30W / 141W |     54MiB /  2047MiB |     26%      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID  Type  Process name                               Usage      |
|=============================================================================|
|    0     23612    C   alprd                                           43MiB |
+-----------------------------------------------------------------------------+
 
Last edited by a moderator:
yeah I had to rebuild everything, specifically I had to install Nvidia's Binary Installer and Cuda toolkit, then build the latest version of OpenCL w/Cuda enabled, then rebuild openalpr again from scratch.

Ok thanks. I'll try building it then.
 

Now that I have alprd working and understanding how it all works, I am getting around to looking at your nodejs code. So if I have this correct, you are replacing beanstalkd with nodejs. And you plan to have nodejs update the OSD and to place the data into a database?

I am currently using a Hikvision for testing and to update OSD it requires a POST, which works fine. I'm not yet sure what camera I'll settle on for this though; like you have, I'll have to do some testing and likely get an IR filter for testing also.

I'm looking at 210ft for a camera from my house to the road unless I conceal one near my mailbox along the road.

Capture.PNG
 
right now that just takes the beanstalk output and saves it to a .json file, while doing a http get request to update the OSD.. for hik it looks like you'd need to post some xml to: /ISAPI/System/Video/inputs/channels/1/overlays/text for the OSD, if you get the code for that worked out sumbit a pull request and I'll see if I can integrate both brands.

When i find the time I intend on adding a database backend, and web ui.. as well as storing the results in the images exif metadata.. but Ive been swamped, I changed teams at work a few months back. I'm in the middle of a transition period and everyone is dumping an excessive amount of work on me in hopes to get me up to speed sooner than later.. I am eagerly waiting for a respite, dunno how much longer I can keep a work load like this up without burning out entirely.
 
right now that just takes the beanstalk output and saves it to a .json file, while doing a http get request to update the OSD.. for hik it looks like you'd need to post some xml to: /ISAPI/System/Video/inputs/channels/1/overlays/text for the OSD, if you get the code for that worked out sumbit a pull request and I'll see if I can integrate both brands.

When i find the time I intend on adding a database backend, and web ui.. as well as storing the results in the images exif metadata.. but Ive been swamped, I changed teams at work a few months back. I'm in the middle of a transition period and everyone is dumping an excessive amount of work on me in hopes to get me up to speed sooner than later.. I am eagerly waiting for a respite, dunno how much longer I can keep a work load like this up without burning out entirely.

I hear you on work.. same here.. ours is a big AWS migration push.

Great idea for using exif.

You are still using beanstalkd? I thought you are having alprd send directly to nodejs on port 9000.
 
the beanstalk queue is only used to cache em before sending it to my nodejs app, if the nodejs app is not started/crashes or whatever they will sit in beanstalk queue until it comes back.. then it'll post them all at once and clear the queue.. alprd does all that. its a nice buffer if you want to run these on separate networks, ie cloud frontend.

I am going to try to implement the exif injection in alprd as the file is saved the first time.. should be nice and fast in cpp, then you can use any decent album software for searching/sorting/organizing.. I have a ticket open for this, already scoped it out: https://github.com/openalpr/openalpr/issues/344

Today I had to back down my settings on the camera, see the horrible attached timeline from my NVR.. With ALPRD now running at realtime speed and me having MJPEG cranked @ 100% maximum proved to be too much for the camera.. the BLC setting was causing it to hang anytime the scene changed and the watchdog would reset the camera.. I knocked it down to 15FPS @ Full Quality and shut down all the features I am not using and it went back to being stable/normal.. I suspect the bandwidth (37Mbit) was just too much for the camera and internal bus speeds were saturated, knocking the bitrate down a little (2Mbit) freed up enough its not choking anymore.. frankly I was surprised I was able to run it at full MJPEG bitrate and resolution, now I know that alprd was throttling the actual output.
 

Attachments

  • Screen Shot 2016-05-19 at 5.50.25 PM.png
    Screen Shot 2016-05-19 at 5.50.25 PM.png
    18.3 KB · Views: 41
here's my current night-time settings and sample captures, in full 4MP glory.. today in the dusk period when I would miss cars all the time because of greyscale I had no problems and the hardware gfx acceleration just steamed right on through it and got every car, no matter how fast they were going.

also I have a screen cap of my PoE output w/IR on.. I am pushing it but just barely got it all to fit.
 

Attachments

  • galileo-cam1-1463711849007.jpg
    galileo-cam1-1463711849007.jpg
    162.3 KB · Views: 72
  • galileo-cam1-1463711306715.jpg
    galileo-cam1-1463711306715.jpg
    135.3 KB · Views: 62
  • galileo-cam1-1463711298767.jpg
    galileo-cam1-1463711298767.jpg
    121.8 KB · Views: 99
  • galileo-cam1-1463712049949.jpg
    galileo-cam1-1463712049949.jpg
    206.9 KB · Views: 218
  • Screen Shot 2016-05-19 at 8.40.35 PM.png
    Screen Shot 2016-05-19 at 8.40.35 PM.png
    14.6 KB · Views: 96
  • Screen Shot 2016-05-19 at 8.40.20 PM.png
    Screen Shot 2016-05-19 at 8.40.20 PM.png
    28.9 KB · Views: 89
  • Screen Shot 2016-05-19 at 8.40.11 PM.png
    Screen Shot 2016-05-19 at 8.40.11 PM.png
    28.3 KB · Views: 90
  • Screen Shot 2016-05-19 at 8.47.20 PM.png
    Screen Shot 2016-05-19 at 8.47.20 PM.png
    49 KB · Views: 91
Last edited by a moderator:
So I need to zoom at 200ft. Might someone have a recommendation on a 4MP IP camera with a CS mount?
 
for 200ft I'd say get a 5-100mm lens or something around that, i am at 60mm zoom and at ~180ft plates are just barely 100px tall @ 4MP.. those are the oncoming plates.

my rear plate reads average ~160ft, plates are ~ 130px tall.. I get great results night or day for rear plate reads.. but oncoming plates can be a struggle and I would need more zoom to capture oncoming plates if I tried for even a few more feet distance
 
  • Like
Reactions: m00st and Sabot
5MP is going to be 4:3 and not 16:9 AR FYI..

I get adequate reads @ 720p, with your optics and camera pixels wont all that important.. at least not enough to pay +$100 for a measly extra MP.. save that money for IR or CUDA HW.

that angle looks doable, nice thats a culdesac so you get em both ways with a single camera.. I think your going to want to use pre-warping to get accurate reads.

is anybody going to park infront of your camera? thats the biggest issue I see, non-stop parking on the curb.