Comments (10)
to get all detection + the people tracking, you can just change this line in darkflow to something like this :
if self.FLAGS.trackObj != mess :
cv2.rectangle(imgcv,
(left, top), (right, bot),
colors[max_indx], thick)
cv2.putText(imgcv, mess, (left, top - 12),
0, 1e-3 * h, colors[max_indx],thick//3)
continue
it will draw the other objects in the image as well.
from tracking-with-darkflow.
@Bendidi Awesome, thanks. Also, is there a way to output in real time (via txt or csv file) the last ID number detected?
from tracking-with-darkflow.
here is the line where it writes to a csv each new box ID+ frame number + box coordinate in pixels
and as I've said here in one of my answers :
you can set the csv FLAG to true it will write at run time the ID number and the corresponding box in a csv file as mentioned in ReadMe :
csv : save csv file of detections in the format (frame_id,object_id,x,y,w,h)
from tracking-with-darkflow.
@Bendidi Thanks again for your prompt reply. I tested this solution, but the csv table is only populated after the program has been stopped. I meant to output real time data, like a stream of values or a csv file that is constantly being populated by the new IDs.
from tracking-with-darkflow.
it should be fixed with the last commit π
from tracking-with-darkflow.
@Bendidi For some reason after your update I am getting a 404 error on the github repo (the darkflow folder to be specific), and it is not updating. Once again thank you very much!
from tracking-with-darkflow.
I just double checked and the folder is up again. Now there is another error that is being generated:
Traceback (most recent call last):
File "run.py", line 3, in
from darkflow.darkflow.net.build import TFNet
File "/Users/pedareva1/Tracking-with-darkflow/darkflow/darkflow/net/build.py", line 7, in
from .framework import create_framework
File "/Users/pedareva1/Tracking-with-darkflow/darkflow/darkflow/net/framework.py", line 2, in
from . import yolov2
File "/Users/pedareva1/Tracking-with-darkflow/darkflow/darkflow/net/yolov2/init.py", line 2, in
from . import predict
File "/Users/pedareva1/Tracking-with-darkflow/darkflow/darkflow/net/yolov2/predict.py", line 134
csv_file.flush()
^
TabError: inconsistent use of tabs and spaces in indentation
(Sorry for asking too many questions).
from tracking-with-darkflow.
I just checked and could solve the error by converting indentation to spaces. Now another error pops up:
Traceback (most recent call last):
File "run.py", line 27, in
tfnet.camera()
File "/home/pedareva1/Tracking-with-darkflow/darkflow/darkflow/net/help.py", line 107, in camera
writer.writerow(['frame_id', 'track_id' , 'x', 'y', 'w', 'h'])
TypeError: a bytes-like object is required, not 'str'
I would really appreciate your help with this.
from tracking-with-darkflow.
in line 106 of darkflow/darkflow/net/help.py , just change the 'wb' to 'w' , I'll make the change in the repo later
It's a problem that happens when using python 3 , when I tested last time it was with python 2 ^^
from tracking-with-darkflow.
@Bendidi Awesome, thanks a lot!
from tracking-with-darkflow.
Related Issues (20)
- How can I get direction of Individual ID's?
- ModuleNotFound Error : No module named 'darkflow.cython_utils' while setting up on Google Colab
- Video is not getting saved
- When I run the code "python run.py" οΌthere is an error . how can I solve it? HOT 1
- the deep_sort weights provided by nwojke is cancelled HOT 8
- ssertionError: Cannot capture source HOT 1
- Not detecting people HOT 1
- darkflow
- Why is the target size different from that trained by Darknet after using this code?
- Hello, I use yolov2 trained by darknet and mark the head and shoulders of the person, but when I use the trained model in this code, I can only detect the head, not the head and shoulders. That is why ah! Does anyone have the same problem with me?
- doesn't save the video HOT 1
- Hello, I used darkflow training to generate four files, but how do I use it in the code?
- I trained yolov2 under darknet. The effect is not good when using this code. Why is this?
- Excuse me? Can this code use pb files? HOT 2
- OOM error
- The name 'net/images:0' refers to a Tensor which does not exist
- AVAssetWriter status: Cannot create file HOT 3
- Using Mask-RCNN for detection HOT 1
- What would be the guideline for multi camera tracking ?
- GPU memory usage 9G
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tracking-with-darkflow.