Deepstream 4.0) make -C nvdsinfer_custom_impl_Yolo failed

[b]So, I’m carefully reading the README and trying to setup my custom Yolov3.

I believe I followed the instructions correctly, but I somehow cannot execute the ‘make’ command.[/b]

whasukgo@Go:/opt/nvidia/deepstream/deepstream-4.0/sources/objectDetector_Yolo$ export CUDA_VER=10.0
whasukgo@Go:/opt/nvidia/deepstream/deepstream-4.0/sources/objectDetector_Yolo$ make -C nvdsinfer_custom_impl_Yolo
make: Entering directory ‘/opt/nvidia/deepstream/deepstream-4.0/sources/objectDetector_Yolo/nvdsinfer_custom_impl_Yolo’
g++ -c -o nvdsparsebbox_Yolo.o -Wall -std=c++11 -shared -fPIC -I…/…/includes -I/usr/local/cuda-10.0/include nvdsparsebbox_Yolo.cpp
nvdsparsebbox_Yolo.cpp: In function ‘bool NvDsInferParseCustomYoloV3Tiny(const std::vector&, const NvDsInferNetworkInfo&, const NvDsInferParseDetectionParams&, std::vector&)’:
nvdsparsebbox_Yolo.cpp:54:1: warning: no return statement in function returning non-void [-Wreturn-type]
};
^
nvdsparsebbox_Yolo.cpp: In function ‘bool NvDsInferParseCustomYoloV3Tiny(const std::vector&, const NvDsInferNetworkInfo&, const NvDsInferParseDetectionParams&, std::vector&)’:
nvdsparsebbox_Yolo.cpp:376:17: error: redefinition of ‘bool NvDsInferParseCustomYoloV3Tiny(const std::vector&, const NvDsInferNetworkInfo&, const NvDsInferParseDetectionParams&, std::vector&)’
extern “C” bool NvDsInferParseCustomYoloV3Tiny(
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvdsparsebbox_Yolo.cpp:40:17: note: ‘bool NvDsInferParseCustomYoloV3Tiny(const std::vector&, const NvDsInferNetworkInfo&, const NvDsInferParseDetectionParams&, std::vector&)’ previously defined here
extern “C” bool NvDsInferParseCustomYoloV3Tiny(
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Makefile:51: recipe for target ‘nvdsparsebbox_Yolo.o’ failed
make: *** [nvdsparsebbox_Yolo.o] Error 1
make: Leaving directory ‘/opt/nvidia/deepstream/deepstream-4.0/sources/objectDetector_Yolo/nvdsinfer_custom_impl_Yolo’

Here is my current nvdsparsebbox_Yolo.cpp.

extern “C” bool NvDsInferParseCustomYoloV3Tiny(
std::vector const& outputLayersInfo,
NvDsInferNetworkInfo const& networkInfo,
NvDsInferParseDetectionParams const& detectionParams,
std::vector& objectList){

const std::vector 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};

static const std::vector<std::vector> kMASKS = {
{3, 4, 5},
{0, 1, 2}};

};

Below is my tiny.cfg file

[net]

Testing

batch=24
subdivisions=8

Training

batch=64

subdivisions=2

width=416
height=416
channels=3
momentum=0.9
decay=0.0005
angle=0
saturation = 1.5
exposure = 1.5
hue=.1

learning_rate=0.001
burn_in=1000
max_batches = 500200
policy=steps
steps=400000,450000
scales=.1,.1

[convolutional]
batch_normalize=1
filters=16
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=2

[convolutional]
batch_normalize=1
filters=32
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=2

[convolutional]
batch_normalize=1
filters=64
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=2

[convolutional]
batch_normalize=1
filters=128
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=2

[convolutional]
batch_normalize=1
filters=256
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=2

[convolutional]
batch_normalize=1
filters=512
size=3
stride=1
pad=1
activation=leaky

[maxpool]
size=2
stride=1

[convolutional]
batch_normalize=1
filters=1024
size=3
stride=1
pad=1
activation=leaky

###########

[convolutional]
batch_normalize=1
filters=256
size=1
stride=1
pad=1
activation=leaky

[convolutional]
batch_normalize=1
filters=512
size=3
stride=1
pad=1
activation=leaky

[convolutional]
size=1
stride=1
pad=1
filters=18
activation=linear

[yolo]
mask = 3,4,5
anchors = 10,14, 23,27, 37,58, 81,82, 135,169, 344,319
classes=1
num=6
jitter=.3
ignore_thresh = .7
truth_thresh = 1
random=1

[route]
layers = -4

[convolutional]
batch_normalize=1
filters=128
size=1
stride=1
pad=1
activation=leaky

[upsample]
stride=2

[route]
layers = -1, 8

[convolutional]
batch_normalize=1
filters=256
size=3
stride=1
pad=1
activation=leaky

[convolutional]
size=1
stride=1
pad=1
filters=18
activation=linear

[yolo]
mask = 0,1,2
anchors = 10,14, 23,27, 37,58, 81,82, 135,169, 344,319
classes=1
num=6
jitter=.3
ignore_thresh = .7
truth_thresh = 1
random=1

Can you specify which platform/OS you are using ? Also, did you modify any of the sources ?

Hi leeju213,

Have you managed to get issue resolved? Any result can be shared?