Open ou525 opened 4 years ago
@ou525
-letter_box
at the end of detection commandHow do you convert a darknet model to TensorRT??
@AlexeyAB @isra60 i use the nvidia demo, https://github.com/NVIDIA-AI-IOT/deepstream_reference_apps/tree/restructure/yolo/apps/trt-yolo
i add the flag -letter_box, but I don't find any difference
but I found that it has more false detections than tests based on darknet.
Can you show screenshot of detections?
./darknet detector test ... -letter_box
@AlexeyAB these two pictures are the most obvious place for this scene.
-letter_box
?@AlexeyAB sorry, I retested the add and without flag -letter_box, it does appear similar to the false detection under trt, but it does not always appear on the same picture. At the same time, I checked the content of letter_box. Is it caused by the different input of trt's blobFromImage () and darknet's letterbox_image ()?
i only use the yoov3-spp.cfg, trained without -letter_box.
I extracted the feature values of layer81 of the yolov3-spp network, which seems to be very different from those under trt. darknet.txt trt.txt
@AlexeyAB sorry, I retested the add and without flag -letter_box, it does appear similar to the false detection under trt, but it does not always appear on the same picture.
Do you mean that each run of the same command with the same image gives a different result? ./darknet detector test ... test.jpg -letter_box
The test results are unique. The first results may be obtained by other model tests.
I replaced trt's letter_box with direct resize, and now the result seems to be normal.
You should
[net] letter_box=1
in cfg-file (so you can use letterbox in trt)Thanks for your suggestions, I will try to do it.
@ou525 How did you convert trained .weights and .cfg to tensorRT? Been struggling with this for a while, why guidance would be greatly appreciated.
I trained a yolov3-spp model based on darkent, and at the same time I converted it to a tensorrt model, but I found that it has more false detections than tests based on darknet. precision:float32, no int8