Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to continue counter / how is state stored? #267

Closed
GeorgePearse opened this issue Jun 20, 2023 · 3 comments
Closed

How to continue counter / how is state stored? #267

GeorgePearse opened this issue Jun 20, 2023 · 3 comments
Labels
help wanted Extra attention is needed

Comments

@GeorgePearse
Copy link

Describe the situation you are working on

Object counting on a conveyor belt.

Describe what is it that you need help with
The data we'd display to clients is a count of unique objects. I'm trying to workout how we'd manage deployment in terms of continuing to increase the counter. Do people tend to reset on an hourly / X-time basis or something like that? Or run it over segments of video Y minutes long?

Alternatively is it possible to simply always generate unique IDs (e.g. long hashes) instead of the count IDs. So that our database call could just be the number of those unique IDs?

@GeorgePearse GeorgePearse added the help wanted Extra attention is needed label Jun 20, 2023
@javiber
Copy link
Collaborator

javiber commented Jun 21, 2023

Hi @GeorgePearse

We don't have an easy way to reset the counter, but that's handled by a TrackedObjectFactory which you can access through tracker._obj_factory. In there you can find the count and the global_count which is only useful if you have multiple Tracker instances.

Regarding random IDs we don't have a way to support that, you could achieve it by forking this repo and modifying the ids returned here

Sorry that I can't help you more, resetting the counter sounds like a new feature we should include in a future version

@GeorgePearse
Copy link
Author

I think forking and using UUIDs instead is the approach my team are going to take.

@javiber
Copy link
Collaborator

javiber commented Jun 26, 2023

Sounds Good! I'm going to close the issue but feel free to reach out if needed

@javiber javiber closed this as completed Jun 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants