Skip to content

Commit 6ba26e5

Browse files
authored
perf(yabloc): fix performance warning of iterateByValue (#6929)
Signed-off-by: Ryuta Kambe <ryuta.kambe@tier4.jp>
1 parent 6d00269 commit 6ba26e5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

localization/yabloc/yabloc_pose_initializer/src/camera/projector_module.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ cv::Mat ProjectorModule::project_image(const cv::Mat & mask_image)
5050
cv::findContours(masks[i], contours, cv::RETR_LIST, cv::CHAIN_APPROX_NONE);
5151

5252
std::vector<std::vector<cv::Point> > projected_contours;
53-
for (auto contour : contours) {
53+
for (const auto & contour : contours) {
5454
std::vector<cv::Point> projected;
55-
for (auto c : contour) {
55+
for (const auto & c : contour) {
5656
auto opt = project_func_(c);
5757
if (!opt.has_value()) continue;
5858

0 commit comments

Comments
 (0)