YOLO Plugin Error

Hi There I am trying https://github.com/vat-nvidia/deepstream-plugins for YOLO v3 plugins. I am getting following error when trying to run make command from ~/yolo-plugin/deepstream-plugins/sources/plugins/gst-yoloplugin-tesla$

Error is Makefile:34: *** “CUDA_VER variable is not set in Makefile.config”. Stop.
please suggest

Please modify all the variables in Makefile.config under the plugin dir.
a clip for reference

CUDA_VER:= 9.2

#Set to TEGRA for jetson or TESLA for dGPU’s
PLATFORM:= TESLA

#For Tesla Plugins
OPENCV_INSTALL_DIR:= /home/tse/cuse/opencv3.4/opencv-3.4.0/install
TENSORRT_INSTALL_DIR:= /home/tse/cuse/trt4.0.1.6/usr
DEEPSTREAM_INSTALL_DIR:= /home/tse/work/deepstream/DeepStream_Release
#CUDNN_DIR := /home/tse/work/cpxavier/cudnn7.3.0.23/cuda

Thanks I have given path here CUDA_VER:= 9.2 instead of only version thanks a lot

Hi I am getting another error

File does not exist : data/yolov3-tiny.cfg
trt-yolo-app: yolo.cpp:135: void Yolo::createYOLOEngine(int, std::__cxx11::string, std::__cxx11::string, std::__cxx11::string, nvinfer1::DataType, Int8EntropyCalibrator*): Assertion `fileExists(yoloConfigPath)’ failed.
Aborted (core dumped)

Although I have yolov3-tiny.cfg inside data

in this file sources/lib/network_config.h, by default, it all comment out, please uncomment one which you are
using

// Uncomment the macro to choose a type of network
#define MODEL_V2 yoloV2
// #define MODEL_V2_TINY
// #define MODEL_V3
//#define MODEL_V3_TINY

Hi, I have already done that

Even after running sudo make reinstall it’s giving error

Changes done is below
Added path for video url in deepstream-app_yolo_config.txt

[source0]
enable=1
#Type - 1=CameraV4L2 2=URI 3=MultiURI
type=3
uri=file://home/nvidia/yolo-plugin/deepstream-plugins/sources/apps/deepstream-yolo/sample_720p.mp4

I am getting below error

nvidia@nvidia-HP-Z440-Workstation:~/yolo-plugin/deepstream-plugins/sources/apps/deepstream-yolo$ ./deepstream-yolo-app sample_720p.h264
Now playing: sample_720p.h264
File does not exist : sources/lib/models/yolov3-tiny-kFLOAT-batch1.engine
Unable to find cached TensorRT engine for network : yolov3-tiny precision : kFLOAT and batch size :1
Creating a new TensorRT Engine
File does not exist : data/yolov3-tiny.cfg
deepstream-yolo-app: yolo.cpp:135: void Yolo::createYOLOEngine(int, std::__cxx11::string, std::__cxx11::string, std::__cxx11::string, nvinfer1::DataType, Int8EntropyCalibrator*): Assertion `fileExists(yoloConfigPath)’ failed.
Aborted (core dumped)

Hi Deepshikha,

provide absolute paths in network-config.cpp. It will help.
Its pretty much messed up. all are working for us

const std::string kDS_LIB_PATH = "/path-to-yolo_plugin/deepstream-plugins/sources/lib/";
const std::string kMODELS_PATH = kDS_LIB_PATH+"models/";
const std::string kDETECTION_RESULTS_PATH ="/path-to-yolo_plugin/deepstream-plugins/data/detections/";
const std::string kCALIBRATION_SET = "/path-to-yolo_plugin/deepstream-plugins/data/calibration_images.txt";
const std::string kTEST_IMAGES = "/path-to-yolo_plugin/deepstream-plugins/data/test_images.txt";
.....................................................
#ifdef MODEL_V3_TINY
// Model V3 Tiny specific common global vars
const float kPROB_THRESH = 0.5f;
const float kNMS_THRESH = 0.5f;
const std::string kYOLO_CONFIG_PATH = "absolute_path_to/data/yolov3-tiny.cfg";
const std::string kTRAINED_WEIGHTS_PATH = "absolute_path_to/data/yolov3-tiny.weights";
const std::string kNETWORK_TYPE = "yolov3-tiny";
const std::string kCALIB_TABLE_PATH = "absolute_path_to/calibration/yolov3-tiny-calibration.table";
const uint kBBOXES = 3;
const std::vector<float> kANCHORS
    = {10.0, 14.0, 23.0, 27.0, 37.0, 58.0, 81.0, 82.0, 135.0, 169.0, 344.0, 319.0};
#endif

Update the paths of the .cfg and .weights file and other network params in net work_config.cpp file if required.

one example for config file, others also need modidy.

const std::string kYOLO_CONFIG_PATH = “…/…/…/data/yolov2.cfg”;

dont use sudo in that case. It should be working

Hello guys,

Do you know if the yolo-plugin works with GTX 1080?

Thanks!

Yes it should be. I am using 1080Ti and it is working fine. Apparently, the plugin doesnt has a hardware limitation.

Thank you!

While using the yolo plugin, I am using an rtsp stream as my source. However, I am getting this error regarding batchSize:

yoloplugin_lib.cpp:116: YoloPluginCtx* YoloPluginCtxInit(YoloPluginInitParams*, size_t): Assertion `ctx->batchSize > 0’ failed.
Aborted (core dumped)

Do you know what might be causing this?

Hi can you please share the plugin implementation , i am facing issues during implementation