Closed calderonsin closed 3 years ago
I'm on Ubuntu 18.04.3 LTS, it is a docker container of a darknet images (https://hub.docker.com/r/inqdocker/darknet) and got no GUI. Can u lend me a nad?
For working without GUI it need to build with option: _cmake . -DSILENTWORK=ON
P.S. I never try this project in docker.
Hello, thank u for u reply it worked, it ran the tracking but the .csv is empty and the video itself doesn't have any information about tracking
I used this command: ./MultitargetTracker /home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4 -e=5 -a=0 -o=/home/juccalderondo/videos/Acevedo_6-18am_6-38am_detection_2.avi -r=/home/juccalderondo/videos/Acevedo_6-18am_6-38am.csv -g=0 -sl=1 -s=/home/juccalderondo/Multitarget-tracker/data/settings.ini
What it write in console?
these are the first line:
Examples of the Multitarget tracking algorithm
Usage:
./MultitargetTracker
Press: 'm' key for change mode: play|pause. When video is paused you can press any key for get next frame.
Press Esc to exit from video
Usage: MultitargetTracker [params] 1
-a, --async (value:0)
Use 2 theads for processing pipeline
--batch_size, --bs (value:1)
Batch size - frames count for processing
-c, --config
For CarsCounting: Config file of neural network: yolov4.cfg
-e, --example (value:5)
number of example 0 - MouseTracking, 1 - MotionDetector, 2 - FaceDetector, 3 - PedestrianDetector, 4 - OpenCV dnn objects detector, 5 - YOLO Darknet detector, 6 - YOLO TensorRT Detector, 7 - Cars counting
--ed, --end_delay (value:0)
Delay in milliseconds after video ending
--ef, --end_frame (value:0)
Play a video to this position (if 0 then played to the end of file)
-g, --gpu (value:0)
Use OpenCL acceleration
--heat_map, --hm (value:0)
For CarsCounting: Draw heat map
--inf, --inference (value:darknet)
For CarsCounting: Type of inference framework: darknet, ocvdnn
-n, --names
For CarsCounting: File with classes names: coco.names
-o, --out (value:/home/juccalderondo/videos/Acevedo_6-18am_6-38am_detection_2.avi)
Name of result video file
-r, --res (value:/home/juccalderondo/videos/Acevedo_6-18am_6-38am.csv)
Path to the csv file with tracking result
-s, --settings (value:/home/juccalderondo/MT2/data/settings.ini)
Path to the init file with tracking settings
--sf, --start_frame (value:0)
Start a video from this position
--show_logs, --sl (value:1)
Show Trackers logs
-w, --weights
For CarsCounting: Weights of neural network: yolov4.weights
--wf, --write_n_frame (value:1)
Write logs on each N frame: 1 for writing each frame
1 (value:/home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4)
movie file
OpenCL not used ParseTrackerSettings: /home/juccalderondo/MT2/data/settings.ini ... ParseTrackerSettings - readed ParseTrackerSettings: 1 Video /home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4 was started from 0 frame with 29.97 fps Used GPU 0 0 : compute_capability = 610, cudnn_half = 0, GPU: NVIDIA TITAN Xp net.optimized_memory = 0 mini_batch = 1, batch = 8, time_steps = 1, train = 0 layer filters size/strd(dil) input output 0 Create CUDA-stream - 0 Create cudnn-handle 0 conv 32 3 x 3/ 1 416 x 416 x 3 -> 416 x 416 x 32 0.299 BF 1 max 2x 2/ 2 416 x 416 x 32 -> 208 x 208 x 32 0.006 BF 2 conv 64 3 x 3/ 1 208 x 208 x 32 -> 208 x 208 x 64 1.595 BF 3 max 2x 2/ 2 208 x 208 x 64 -> 104 x 104 x 64 0.003 BF 4 conv 128 3 x 3/ 1 104 x 104 x 64 -> 104 x 104 x 128 1.595 BF 5 conv 64 1 x 1/ 1 104 x 104 x 128 -> 104 x 104 x 64 0.177 BF 6 conv 128 3 x 3/ 1 104 x 104 x 64 -> 104 x 104 x 128 1.595 BF 7 max 2x 2/ 2 104 x 104 x 128 -> 52 x 52 x 128 0.001 BF 8 conv 256 3 x 3/ 1 52 x 52 x 128 -> 52 x 52 x 256 1.595 BF 9 conv 128 1 x 1/ 1 52 x 52 x 256 -> 52 x 52 x 128 0.177 BF 10 conv 256 3 x 3/ 1 52 x 52 x 128 -> 52 x 52 x 256 1.595 BF 11 max 2x 2/ 2 52 x 52 x 256 -> 26 x 26 x 256 0.001 BF 12 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 13 conv 256 1 x 1/ 1 26 x 26 x 512 -> 26 x 26 x 256 0.177 BF 14 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 15 conv 256 1 x 1/ 1 26 x 26 x 512 -> 26 x 26 x 256 0.177 BF 16 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 17 max 2x 2/ 2 26 x 26 x 512 -> 13 x 13 x 512 0.000 BF 18 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 19 conv 512 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 512 0.177 BF 20 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 21 conv 512 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 512 0.177 BF 22 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 23 conv 1024 3 x 3/ 1 13 x 13 x1024 -> 13 x 13 x1024 3.190 BF 24 conv 1024 3 x 3/ 1 13 x 13 x1024 -> 13 x 13 x1024 3.190 BF 25 route 16 -> 26 x 26 x 512 26 reorg_old reorg_old / 2 26 x 26 x 512 -> 13 x 13 x2048 27 route 26 24 -> 13 x 13 x3072 28 conv 1024 3 x 3/ 1 13 x 13 x3072 -> 13 x 13 x1024 9.569 BF 29 conv 40 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 40 0.014 BF 30 detection mask_scale: Using default '1.000000' Total BFLOPS 34.879 avg_outputs = 645209 Allocate additional workspace_size = 314.58 MB Loading weights from /home/juccalderondo/backup/yolo-obj_40000.weights... seen 64, trained: 2560 K-images (40 Kilo-batches_64) Done! Loaded 31 layers from weights-file
try to allocate additional workspace_size = 314.58 MB CUDA allocate done!
these are the last: Frame 34174: tracks = 0, time = 23 Frame 34175: tracks = 0, time = 19 Frame 34176: tracks = 0, time = 15 Frame 34177: tracks = 0, time = 20 Frame 34178: tracks = 0, time = 14 Frame 34179: tracks = 0, time = 25 Frame 34180: tracks = 0, time = 14 Frame 34181: tracks = 0, time = 12 Frame 34182: tracks = 0, time = 12 Frame 34183: tracks = 0, time = 13 Frame 34184: tracks = 0, time = 12 Frame 34185: tracks = 0, time = 12 algorithms time = 657.614, work time = 1294.54
Ok. Do you work in docker now? This project has a piece of code for visual debugging tracking part: https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Tracker/Ctracker.cpp#L156
Set and rebuild:
#define DRAW_DBG_ASSIGNMENT 1
But if don't has a GUI then uncomment all lines: https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Detector/YoloDarknetDetector.cpp#L189 https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Detector/YoloDarknetDetector.cpp#L218 etc
I'm working on docker without GUI. should I uncomment all lines starting by "//std::cout"? thanks four u reply!
Yes
okey, I made the changes and built again, i'm going to try the tracking again and tell u what happen Thank u!
it seems that it's detecting objects but the csv is still empty . these are the first lines: 1 (value:/home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4) movie file OpenCL not used ParseTrackerSettings: /home/juccalderondo/MT2/data/settings.ini ... ParseTrackerSettings - readed ParseTrackerSettings: 1 Video /home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4 was started from 0 frame with 29.97 fps Used GPU 0 0 : compute_capability = 610, cudnn_half = 0, GPU: NVIDIA TITAN Xp net.optimized_memory = 0 mini_batch = 1, batch = 8, time_steps = 1, train = 0 layer filters size/strd(dil) input output 0 Create CUDA-stream - 0 Create cudnn-handle 0 conv 32 3 x 3/ 1 416 x 416 x 3 -> 416 x 416 x 32 0.299 BF 1 max 2x 2/ 2 416 x 416 x 32 -> 208 x 208 x 32 0.006 BF 2 conv 64 3 x 3/ 1 208 x 208 x 32 -> 208 x 208 x 64 1.595 BF 3 max 2x 2/ 2 208 x 208 x 64 -> 104 x 104 x 64 0.003 BF 4 conv 128 3 x 3/ 1 104 x 104 x 64 -> 104 x 104 x 128 1.595 BF 5 conv 64 1 x 1/ 1 104 x 104 x 128 -> 104 x 104 x 64 0.177 BF 6 conv 128 3 x 3/ 1 104 x 104 x 64 -> 104 x 104 x 128 1.595 BF 7 max 2x 2/ 2 104 x 104 x 128 -> 52 x 52 x 128 0.001 BF 8 conv 256 3 x 3/ 1 52 x 52 x 128 -> 52 x 52 x 256 1.595 BF 9 conv 128 1 x 1/ 1 52 x 52 x 256 -> 52 x 52 x 128 0.177 BF 10 conv 256 3 x 3/ 1 52 x 52 x 128 -> 52 x 52 x 256 1.595 BF 11 max 2x 2/ 2 52 x 52 x 256 -> 26 x 26 x 256 0.001 BF 12 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 13 conv 256 1 x 1/ 1 26 x 26 x 512 -> 26 x 26 x 256 0.177 BF 14 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 15 conv 256 1 x 1/ 1 26 x 26 x 512 -> 26 x 26 x 256 0.177 BF 16 conv 512 3 x 3/ 1 26 x 26 x 256 -> 26 x 26 x 512 1.595 BF 17 max 2x 2/ 2 26 x 26 x 512 -> 13 x 13 x 512 0.000 BF 18 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 19 conv 512 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 512 0.177 BF 20 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 21 conv 512 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 512 0.177 BF 22 conv 1024 3 x 3/ 1 13 x 13 x 512 -> 13 x 13 x1024 1.595 BF 23 conv 1024 3 x 3/ 1 13 x 13 x1024 -> 13 x 13 x1024 3.190 BF 24 conv 1024 3 x 3/ 1 13 x 13 x1024 -> 13 x 13 x1024 3.190 BF 25 route 16 -> 26 x 26 x 512 26 reorg_old reorg_old / 2 26 x 26 x 512 -> 13 x 13 x2048 27 route 26 24 -> 13 x 13 x3072 28 conv 1024 3 x 3/ 1 13 x 13 x3072 -> 13 x 13 x1024 9.569 BF 29 conv 40 1 x 1/ 1 13 x 13 x1024 -> 13 x 13 x 40 0.014 BF 30 detection mask_scale: Using default '1.000000' Total BFLOPS 34.879 avg_outputs = 645209 Allocate additional workspace_size = 314.58 MB Loading weights from /home/juccalderondo/backup/yolo-obj_40000.weights... seen 64, trained: 2560 K-images (40 Kilo-batches_64) Done! Loaded 31 layers from weights-file
try to allocate additional workspace_size = 314.58 MB CUDA allocate done!
these are the last lines: Frame 34179: tracks = 0, time = 12 Detected 6 objects Finally 0 objects, 1, 2 Frame 34180: tracks = 0, time = 12 Detected 5 objects Finally 0 objects, 1, 2 Frame 34181: tracks = 0, time = 12 Detected 6 objects Finally 0 objects, 1, 2 Frame 34182: tracks = 0, time = 12 Detected 9 objects Finally 0 objects, 1, 2 Frame 34183: tracks = 0, time = 12 Detected 6 objects Finally 0 objects, 1, 2 Frame 34184: tracks = 0, time = 12 Detected 7 objects Finally 0 objects, 1, 2 Frame 34185: tracks = 0, time = 12
I think that problem in this line: https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Detector/YoloDarknetDetector.cpp#L184
Try to comment all lines with white_list here: https://github.com/Smorodov/Multitarget-tracker/blob/master/example/examples.h#L657
If the problem still persists then comment this line: https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Detector/YoloDarknetDetector.cpp#L184
Hello, i tried both solutions and the csv is still empty and the video doesn't show tracking at all :( I suppose is because the non GUI envyroment
thanks!
I think that here another problem. I see in your log:
Detected 6 objects
Finally 0 objects, 1, 2
Detector works but objects was absent. Comment also line 215: https://github.com/Smorodov/Multitarget-tracker/blob/master/src/Detector/YoloDarknetDetector.cpp#L215
Hello! The tracking is working now. I have a question, where can I read about the .csv? I wish to know what is the format of the output.
Thank u for your help!
Here: https://github.com/Smorodov/Multitarget-tracker/blob/master/example/FileLogger.h#L119 First value - Frame id and other - detection parameters on this frame
Hello! I'm trying to use the multitracker, I'm trying to use the YOLO detector with Darknet backend and nothing happened:
./MultitargetTracker /home/juccalderondo/videos/Acevedo_6-18am_6-38am.MP4 -e=5 -a=1 -o=/home/juccalderondo/videos/Acevedo_6-18am_6-38am_detection_2.avi -r=/home/juccalderondo/videos/Acevedo_6-18am_6-38am.csv -g=0 -sl=1 -s=/home/juccalderondo/Multitarget-tracker/data/settings.ini
the output is: Press: 'm' key for change mode: play|pause. When video is paused you can press any key for get next frame.
Press Esc to exit from video
Usage: MultitargetTracker [params] 1
OpenCL not used ParseTrackerSettings: /home/juccalderondo/Multitarget-tracker/data/settings.ini ... ParseTrackerSettings - readed ParseTrackerSettings: 1