Support fixed length TRT prediction

This commit is contained in:
root
2021-01-08 09:34:29 +00:00
parent 1f99a63524
commit 24f8dfb7e1
6 changed files with 47 additions and 19 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ cv::Mat Classifier::Run(cv::Mat &img) {
int index = 0;
float wh_ratio = float(img.cols) / float(img.rows);
this->resize_op_.Run(img, resize_img, cls_image_shape);
this->resize_op_.Run(img, resize_img, this->use_tensorrt_, cls_image_shape);
this->normalize_op_.Run(&resize_img, this->mean_, this->scale_,
this->is_scale_);