Add Mobilenet2SSDLite test

The new test works both with TensorRT and cuDNN. Preprocessing and
Postprocessing are missing. Add ClippedReLU (for ReLU6), groups for
Conv2d, additional bias for convolution.

Other minors:
-move the timer in the detector to measure all the
processing time for a given frame (both centernet and yolo);
-add int8 flag.

Signed-off-by: Micaela Verucchi <micaelaverucchi@gmail.com>
Davide Sapienza <sapienza.dav@gmail.com>
This commit is contained in:
xavier
2020-02-21 10:45:46 +01:00
parent 97b88ef52d
commit 38a1b9dcb2
17 changed files with 649 additions and 56 deletions
+3 -2
View File
@@ -63,6 +63,7 @@ bool Yolo3Detection::init(std::string tensor_path) {
void Yolo3Detection::update(cv::Mat &imageORIG) {
TIMER_START
if(!imageORIG.data) {
std::cout<<"YOLO: NO IMAGE DATA\n";
return;
@@ -100,7 +101,6 @@ void Yolo3Detection::update(cv::Mat &imageORIG) {
stats.push_back(t_ns);
}
TIMER_START
// compute dets
ndets = 0;
for(int i=0; i<netRT->pluginFactory->n_yolos; i++) {
@@ -109,7 +109,6 @@ void Yolo3Detection::update(cv::Mat &imageORIG) {
yolo[i]->computeDetections(dets, ndets, netRT->input_dim.w, netRT->input_dim.h, thresh);
}
tk::dnn::Yolo::mergeDetections(dets, ndets, classes);
TIMER_STOP
// fill detected
detected.clear();
@@ -148,6 +147,8 @@ void Yolo3Detection::update(cv::Mat &imageORIG) {
detected.push_back(res);
}
}
TIMER_STOP
stats.push_back(t_ns);
}