@@ -201,8 +201,8 @@ void YoloTensorRTDetector::Detect(const cv::UMat& colorFrame)
201201 std::vector<cv::Rect> crops = GetCrops (m_maxCropRatio, m_detector->GetInputSize (), colorMat.size ());
202202 // std::cout << "Image on " << crops.size() << " crops with size " << crops.front().size() << ", input size " << m_detector->GetInputSize() << ", batch " << m_batchSize << ", frame " << colorMat.size() << std::endl;
203203 regions_t tmpRegions;
204- std::vector<cv::Mat> batch;
205- batch.reserve (m_batchSize);
204+ std::vector<cv::Mat> batch;
205+ batch.reserve (m_batchSize);
206206 for (size_t i = 0 ; i < crops.size (); i += m_batchSize)
207207 {
208208 size_t batchSize = std::min (static_cast <size_t >(m_batchSize), crops.size () - i);
@@ -212,7 +212,7 @@ void YoloTensorRTDetector::Detect(const cv::UMat& colorFrame)
212212 batch.emplace_back (colorMat, crops[i + j]);
213213 }
214214 std::vector<tensor_rt::BatchResult> detects;
215- m_detector->Detect (batch, detects);
215+ m_detector->Detect (batch, detects);
216216
217217 for (size_t j = 0 ; j < batchSize; ++j)
218218 {
@@ -229,11 +229,11 @@ void YoloTensorRTDetector::Detect(const cv::UMat& colorFrame)
229229
230230 if (crops.size () > 1 )
231231 {
232- nms3<CRegion>(tmpRegions, m_regions, 0 . 4f ,
232+ nms3<CRegion>(tmpRegions, m_regions, static_cast < track_t >( 0.4 ) ,
233233 [](const CRegion& reg) { return reg.m_brect ; },
234234 [](const CRegion& reg) { return reg.m_confidence ; },
235235 [](const CRegion& reg) { return reg.m_type ; },
236- 0 , 0 . f );
236+ 0 , static_cast < track_t >( 0 ) );
237237 // std::cout << "nms for " << tmpRegions.size() << " objects - result " << m_regions.size() << std::endl;
238238 }
239239 }
0 commit comments