Develop a Python AI app using YOLOv3 and deepstream

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU) Jetson AGX Xavier
• DeepStream Version 5.0

Hi all,

I am developing a python ai app using YOLOv3. I tested the demo of YOLOv3 and achieved 15 fps. Then I tested the demo of deepstream (deepstream-app -c deepstream_app_config_yoloV3.txt) and achieved 60 fps. I want to know where and how can I edit deepstream-app or using the sdk to achieve 60 fps in my own app. I am a novice in this field. Any help will be greatly appreciated. Thank you.

are you using INT8 inference as defined by “network-mode=1”?

$ cat config_infer_primary_yoloV3.txt
...
## 0=FP32, 1=INT8, 2=FP16 mode
network-mode=1
...

yes

what’s your batch size?

How can I get it?

can you share the two config files?

[property]
gpu-id=0
net-scale-factor=0.0039215697906911373
#0=RGB, 1=BGR
model-color-format=0
custom-network-config=yolov3.cfg
model-file=yolov3.weights
#model-engine-file=yolov3_b1_gpu0_int8.engine
labelfile-path=labels.txt
int8-calib-file=yolov3-calibration.table.trt7.0

0=FP32, 1=INT8, 2=FP16 mode

network-mode=1
num-detected-classes=80
gie-unique-id=1
network-type=0
is-classifier=0

0=Group Rectangles, 1=DBSCAN, 2=NMS, 3= DBSCAN+NMS Hybrid, 4 = None(No clustering)

cluster-mode=2
maintain-aspect-ratio=1
parse-bbox-func-name=NvDsInferParseCustomYoloV3
custom-lib-path=nvdsinfer_custom_impl_Yolo/libnvdsinfer_custom_impl_Yolo.so
engine-create-func-name=NvDsInferYoloCudaEngineGet
#scaling-filter=0
#scaling-compute-hw=0

[class-attrs-all]
nms-iou-threshold=0.3
threshold=0.7

which config file is this for?

I think you have two config files, one is for python YOLOv3, the other is for deepstream-app.
Is above config file for python Yolov3, and you are using the default YoloV3 config file for deepstream-app?

python Yolov3 is from https://pjreddie.com/darknet/yolo/.

I run the sample code ./darknet detector demo cfg/coco.data cfg/yolov3.cfg yolov3.weights and achieve 15 fps.

Then I use the default YoloV3 config file for deepstream-app and achieve 60 fps.

I want to know whether the use of deepstream create such a performance difference. If so, how can I integrate deepstream into my own python ai app.

Thank you.

DeepStream support python - https://docs.nvidia.com/metropolis/deepstream/dev-guide/index.html