CodeProject AI Person Counting

Post Reply
TobyEpp
Posts: 5
Joined: Tue Aug 20, 2024 4:21 pm

CodeProject AI Person Counting

Post by TobyEpp »

Hello there everyone. We have a small retail store and I was wondering if there is an easy way to count how many customers come in and out using AI detection. We have 2 cameras set up in the store and are currently using CodeProject AI for object detection and facial recognition. Does CodeProject AI have a solution for person counting or is there another way this can be accomplished? Thanks.
User avatar
TimG
Posts: 2835
Joined: Tue Jun 18, 2019 10:45 am
Location: Nottinghamshire, UK.

Re: CodeProject AI Person Counting

Post by TimG »

I don't think it could do that. At best it will show groups of people as a singular "person". I think UK trains do it with a detector above a doorway, but I don't know what type of detector, and a camera in that position couldn't recognise a person.
I guess if it is a single doorway you could use the old ding dong door bell contact.
Forum Moderator.
Problem ? Ask and we will try to assist, but please check the Help file.
louyo
Posts: 189
Joined: Sat Apr 18, 2020 1:16 am

Re: CodeProject AI Person Counting

Post by louyo »

If you don't mind getting your hands a little dirty, it is easy with the Linux app for Windows.
1. Install the ubuntu LTS from the Microsoft store. You will have to enable it from Windows programs features. I think it is WSL.
2. Clone the camera.dn
3. In the clone: Set record to do a jpeg on either trigger or alert (and only that), set the storage location for the jpegs. I also keep the alerts in Aux1 to make it easy to show in BI.
4. My jpegs, for that camera are on my F drive, the folder is jpegs (F:\jpegs). You will need to substitute your names.
5. To do a count by any given day:
open the Ubuntu program (WSL), you will be at the command prompt.
to get to my F:\jpeg folder, I: cd /mnt/f/jpeg (note that there is no : after the f)
My command prompt now shows:root@BlueIris:/mnt/f/jpegs#
I type: ls -l | grep -c "Apr 22" (get count of files with date April 22
answer: 524
count.PNG
count.PNG (46.76 KiB) Viewed 1307 times
Waternut1313
Posts: 5
Joined: Mon Nov 09, 2020 5:21 am

Re: CodeProject AI Person Counting

Post by Waternut1313 »

If you’re already using CodeProject AI, you might be able to repurpose its object detection features to track customer movement. That said, for more precise person counting, you could also look into specialized solutions like OpenCV or TensorFlow.
Post Reply