Full ALPR Database System for Blue Iris!

This might help.

I am stuck at the first steps..

postgres@blizzard:~$ psql -d postgres -U postgres -f /docker-entrypoint-initdb.d/schema.sql
psql: error: /docker-entrypoint-initdb.d/schema.sql: No such file or directory


sorry i am somewhat stupid on debian 12
 
Howdy all. Just a quick one

CodeprojectAL installed rocking away fine with plates

Due sql database conflicts I used port 5423, this caused a refuses connection error.
I looked through to many files with my old eyes and going crosseyed LOL

Can I change the port in the ALPR to use port 5423, if yes where can I do it.?

Ubuntu_20.04, Docker Desktop, codeprojectai and alpr on same machine for now

Thank you :)
ALPR_error2.JPG
ALPR_error.JPG
 
Last edited:
Howdy all. Just a quick one

CodeprojectAL installed rocking away fine with plates

Due sql database conflicts I used port 5423, this caused a refuses connection error.
I looked through to many files with my old eyes and going crosseyed LOL

Can I change the port in the ALPR to use port 5423, if yes where can I do it.?

Ubuntu_20.04, Docker Desktop, codeprojectai and alpr on same machine for now

Thank you :)View attachment 224503View attachment 224488

Then run these commands in your docker (the db one, not the app one):
psql -d postgres -U postgres -f /docker-entrypoint-initdb.d/schema.sql
psql -d postgres -U postgres -f /docker-entrypoint-initdb.d/migrations.sql
which may then result in logs like these:
5/1/2025, 3:00:12 PM [ERROR] Error processing request: error: null value in column "plate_number" of relation "plate_reads" violates not-null constraint
 
  • Like
Reactions: SoCal
Is there a way to get a fuzzy search match over to home assistant? The use case would be that a plate is sent over from Blue Iris to ALPR-database and the OCR is slightly incorrect, but a fuzzy match will match it to a known plate. If so, I'd like to let home assistant know that it matches a known plate for automation purposes.
 
Is there a way to get a fuzzy search match over to home assistant? The use case would be that a plate is sent over from Blue Iris to ALPR-database and the OCR is slightly incorrect, but a fuzzy match will match it to a known plate. If so, I'd like to let home assistant know that it matches a known plate for automation purposes.
Currently there is not, but MQTT notifications for HA are on @algertc's roadmap. You might want to go into the roadmap and add a request for a fuzzy search option within a MQTT notification. A web hook notification may be another option you may want to add request for.

 
I made a number of updates:

  • Fixed session kickout to login screen
  • Camera filter added to dashboard
  • Password will autofill and save in your browser now
  • Impossible to hit the login page if you have an active session
  • Deleting a record in live feed fixed to only delete that record
  • Correction/add to known forms styling fixed with bigger input boxes
  • Plate image viewer window data state updates properly now
  • Shows current release version in log page
  • Confusing notification page UI fixed
  • Time distribution clickable bars hitbox made height of entire column in case of wide range
  • Some other small improvements and preparations for future features


DB setup issue not yet fixed.....
Are these updates already available for download? And what's the timing on the next big release?
 
  • Like
Reactions: PeteJ

Then run these commands in your docker (the db one, not the app one):
psql -d postgres -U postgres -f /docker-entrypoint-initdb.d/schema.sql
psql -d postgres -U postgres -f /docker-entrypoint-initdb.d/migrations.sql
which may then result in logs like these:
5/1/2025, 3:00:12 PM [ERROR] Error processing request: error: null value in column "plate_number" of relation "plate_reads" violates not-null constraint

Thank you so much!
Please excuse my ignorance:) I am green to docker I' an 65 year old unix guy with half a brain these days LOL. This is my first docker go.

scenero~
ubuntu nix

When I run it in command line it returns no database installed
It is running inside docker desktop, must be running it in the wrong place

This is a fresh install, Proxmox with ubuntu and dockerdesktop

I am getting the storage folder populated with images and thumbnails

running this

{ "ai_dump":&JSON, "Image":"&ALERT_JPEG", "camera":"&CAM", "ALERT_PATH": "&ALERT_PATH", "ALERT_CLIP": "&ALERT_CLIP", "timestamp":"&ALERT_TIME" }

Any help greatly appreciated :)

*edit new logs with fresh install added



7-20-error.JPG




OK I manages to ask ai how to do it LOL


This is the result of the first and second command
Looks like I am missing something somewhere. back to work after dinner :)



command2.JPG
 
Last edited:
Thank you so much!
Please excuse my ignorance:) I am green to docker I' an 65 year old unix guy with half a brain these days LOL. This is my first docker go.

scenero~
ubuntu nix

When I run it in command line it returns no database installed
It is running inside docker desktop, must be running it in the wrong place

This is a fresh install, Proxmox with ubuntu and dockerdesktop

I am getting the storage folder populated with images and thumbnails

running this

{ "ai_dump":&JSON, "Image":"&ALERT_JPEG", "camera":"&CAM", "ALERT_PATH": "&ALERT_PATH", "ALERT_CLIP": "&ALERT_CLIP", "timestamp":"&ALERT_TIME" }

Any help greatly appreciated :)

*edit new logs with fresh install added



View attachment 224911
Let's go back a step. Are you calling the ALPR module (CodeProject.AI) correctly? Are you getting plates detected and returning the plate value in Blue Iris?
 
Let's go back a step. Are you calling the ALPR module (CodeProject.AI) correctly? Are you getting plates detected and returning the plate value in Blue Iris?
Yes I was getting the plate numbers detected with codeproject in BI. That has been working perfectly the last 3 days or so

Running those commands did populate the database with a few plates however has *not updated with several cars that passed that BI did catch and produce a plate number.


data-reads.JPG
 
Thank you so much!
Please excuse my ignorance:) I am green to docker I' an 65 year old unix guy with half a brain these days LOL. This is my first docker go.

scenero~
ubuntu nix

When I run it in command line it returns no database installed
It is running inside docker desktop, must be running it in the wrong place

This is a fresh install, Proxmox with ubuntu and dockerdesktop

I am getting the storage folder populated with images and thumbnails

running this

{ "ai_dump":&JSON, "Image":"&ALERT_JPEG", "camera":"&CAM", "ALERT_PATH": "&ALERT_PATH", "ALERT_CLIP": "&ALERT_CLIP", "timestamp":"&ALERT_TIME" }

Any help greatly appreciated :)

*edit new logs with fresh install added



View attachment 224911



OK I manages to ask ai how to do it LOL


This is the result of the first and second command
Looks like I am missing something somewhere. back to work after dinner :)



View attachment 224912

try:

docker ps -a

this will list the container IDs, look for the one with the alpr1-db

then

docker exec -it CONTAINER_ID_FROM_PREVIOUS /bin/bash

that puts you into the shell of the container

then you can execute the psql commands and verify the migrations.sql file exists and is where you are expecting it.
 
try:

docker ps -a

this will list the container IDs, look for the one with the alpr1-db

then

docker exec -it CONTAINER_ID_FROM_PREVIOUS /bin/bash

that puts you into the shell of the container

then you can execute the psql commands and verify the migrations.sql file exists and is where you are expecting it.


Thank you Pete :)

I did edit my post with the command line and commands I used for others to follow

It seems to actually be working for "now" /Only took a week and banging my caveman head on the wall LOL

I'll post a full pic tutorial on what I did so others may follow as I want to try recreate it again. I did find quite a few uncompatables along the way

Much Appreciated :)

working.JPG
 
  • Like
Reactions: PeteJ