Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build(detection_by_tracker): move utils.hpp file to the detection_by_tracker folder and namespace to avoid conflicts #5837

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#define DETECTION_BY_TRACKER__DETECTION_BY_TRACKER_CORE_HPP_

#include "detection_by_tracker/debugger.hpp"
#include "detection_by_tracker/utils.hpp"

#include <euclidean_cluster/euclidean_cluster.hpp>
#include <euclidean_cluster/utils.hpp>
Expand All @@ -39,8 +40,6 @@
#include <tf2_geometry_msgs/tf2_geometry_msgs.hpp>
#endif

#include "utils/utils.hpp"

#include <tf2_ros/buffer.h>
#include <tf2_ros/transform_listener.h>

Expand Down Expand Up @@ -82,7 +81,7 @@ class DetectionByTracker : public rclcpp::Node
std::map<uint8_t, int> max_search_distance_for_merger_;
std::map<uint8_t, int> max_search_distance_for_divider_;

utils::TrackerIgnoreLabel tracker_ignore_;
detection_by_tracker::utils::TrackerIgnoreLabel tracker_ignore_;

void setMaxSearchRange();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#ifndef UTILS__UTILS_HPP_
#define UTILS__UTILS_HPP_
#ifndef DETECTION_BY_TRACKER__UTILS_HPP_
#define DETECTION_BY_TRACKER__UTILS_HPP_

#include <cstdint>

namespace detection_by_tracker
{
namespace utils
{
struct TrackerIgnoreLabel
Expand All @@ -32,5 +34,6 @@ struct TrackerIgnoreLabel
bool isIgnore(const uint8_t label) const;
}; // struct TrackerIgnoreLabel
} // namespace utils
} // namespace detection_by_tracker

#endif // UTILS__UTILS_HPP_
#endif // DETECTION_BY_TRACKER__UTILS_HPP_
5 changes: 4 additions & 1 deletion perception/detection_by_tracker/src/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#include "utils/utils.hpp"
#include "detection_by_tracker/utils.hpp"

#include <autoware_auto_perception_msgs/msg/object_classification.hpp>

namespace detection_by_tracker
{
namespace utils
{
using Label = autoware_auto_perception_msgs::msg::ObjectClassification;
Expand All @@ -28,3 +30,4 @@ bool TrackerIgnoreLabel::isIgnore(const uint8_t label) const
(label == Label::BICYCLE && BICYCLE) || (label == Label::PEDESTRIAN && PEDESTRIAN);
}
} // namespace utils
} // namespace detection_by_tracker
Loading