Skip to content

Commit a5d785b

Browse files
committed
fix(euclidean_cluster): fix max_cluster_size bug (autowarefoundation#7734)
Signed-off-by: badai-nguyen <dai.nguyen@tier4.jp>
1 parent f08a5ef commit a5d785b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

perception/euclidean_cluster/lib/voxel_grid_based_euclidean_cluster.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ bool VoxelGridBasedEuclideanCluster::cluster(
117117
voxel_grid_.getCentroidIndexAt(voxel_grid_.getGridCoordinates(point.x, point.y, point.z));
118118
if (map.find(index) != map.end()) {
119119
auto & cluster_data_size = clusters_data_size.at(map[index]);
120-
if (cluster_data_size + point_step > std::size_t(max_cluster_size_ * point_step)) {
120+
if (cluster_data_size > std::size_t(max_cluster_size_ * point_step)) {
121121
continue;
122122
}
123123
std::memcpy(

0 commit comments

Comments
 (0)