Install GStreamer pre-requisites using:
$ sudo apt-get install libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev
Install Google flags using:
$ sudo apt-get install libgflags-dev
To use just the stand alone trt-yolo-app, Deepstream Installation can be skipped. Refer to the table below for information regarding installation dependencies. See Note for additional installation caveats.
Platform | Applications | Deepstream Version | Dependancies | Repo Release Tag |
---|---|---|---|---|
dGPU | All apps and plugins | DS 3.0 | DS 3.0, Cuda 10, TensorRT 5 | TOT |
dGPU | All apps and plugins | DS 2.0 | DS 2.0, Cuda 9.2, TensorRT 4 | DS2 Release |
dGPU | trt-yolo-app | Not required | Cuda 10, TensorRT 5 | TOT |
jetson-TX1/TX2 | nvgstiva-app, yoloplugin and trt-yolo-app | DS 1.5 | DS 1.5, Jetpack 3.3 (Cuda 9.0, TensorRT 4) | DS2 Release |
jetson-TX1/TX2 | trt-yolo-app | Not required | Jetpack 3.3 (Cuda 9.0, TensorRT 4) | DS2 Release |
jetson-Xavier | yoloplugin | DS 3.0 | Jetpack 4.1 (Cuda 10.0, TensorRT 5) | TOT |
jetson-Xavier | trt-yolo-app | DS 3.0 | Jetpack 4.1 (Cuda 10.0, TensorRT 5) | TOT |
Tegra users working with Deepstream 1.5 and Jetpack 3.3 will have to regenerate the .cache
files to use the standard caffe models available in the SDK. This can be done by deleting all the .cache
files in /home/nvidia/Model
directory and all its subdirectories and then running the nvgstiva-app using the default config file.
Update all the parameters in Makefile.config
file present in the root directory
-
Go to the
data/yolo
directory and add your yolo .cfg and .weights file.For yolo v2,
$ wget https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov2.cfg
$ wget https://pjreddie.com/media/files/yolov2.weights
For yolo v2 tiny,
$ wget https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov2-tiny.cfg
$ wget https://pjreddie.com/media/files/yolov2-tiny.weights
For yolo v3,
$ wget https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov3.cfg
$ wget https://pjreddie.com/media/files/yolov3.weights
For yolo v3 tiny,
$ wget https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov3-tiny.cfg
$ wget https://pjreddie.com/media/files/yolov3-tiny.weights
-
Add absolute paths of images to be used for calibration in the
calibration_images.txt
file within thedata/yolo
directory. -
For dGPU's,
$cd sources/plugins/gst-yoloplugin-tesla
make && sudo make install
-
For jetson,
$cd sources/plugins/gst-yoloplugin-tegra
make && sudo make install
There are multiple apps that can be used to perform object detection in deepstream.
The deepStream-yolo-app located at sources/apps/deepstream_yolo
is a sample app similar to the Test-1 & Test-2 apps available in the DeepStream SDK. Using the yolo app we build a sample gstreamer pipeline using various components like H264 parser, Decoder, Video Converter, OSD and Yolo plugin to run inference on an elementary h264 video stream.
$ cd sources/apps/deepstream-yolo
$ make && sudo make install
$ cd ../../../
$ deepstream-yolo-app <Platform-Telsa/Tegra> <H264 filename> <yolo-plugin config file>
Refer to sample config files yolov2.txt
, yolov2-tiny.txt
, yolov3.txt
and yolov3-tiny.txt
in config/
directory.
The trt-yolo-app located at sources/apps/trt-yolo
is a sample standalone app, which can be used to run inference on test images. This app does not have any deepstream dependencies and can be built independently.
$ cd sources/apps/trt-yolo
$ make && sudo make install
$ cd ../../../
$ trt-yolo-app --flagfile=/path/to/config-file.txt
Refer to sample config files yolov2.txt
, yolov2-tiny.txt
, yolov3.txt
and yolov3-tiny.txt
in config/
directory.
Additionally run $ trt-yolo-app --help
for a complete list of config parameters.
- If you want to use the
nvyolo
plugin with the deepstream-app, you will need to modify the deepstream-apps' source code to read nvyolo plugins' properties and add it to the pipeline. You can refer theds-example
plugin indeepstream_config_file_parser.c
and make equivalent changes required for thenvyolo
plugin. Specifically refer toparse_dsexample
function and its usage indeepstream_app_config_parser.c