Skip to content

Commit

Permalink
Merge branch 'main' into refactor/occupancy_grid_map_outlier_filter
Browse files Browse the repository at this point in the history
  • Loading branch information
YoshiRi authored May 17, 2024
2 parents af4df4b + 7da5afd commit 1bee188
Show file tree
Hide file tree
Showing 726 changed files with 112,923 additions and 11,211 deletions.
7 changes: 5 additions & 2 deletions .cspell.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
{
"ignorePaths": ["perception/bytetrack/lib/**"],
"ignorePaths": [
"perception/bytetrack/lib/**",
"planning/behavior_velocity_intersection_module/scripts/**"
],
"ignoreRegExpList": [],
"words": ["dltype", "tvmgen"]
"words": ["dltype", "tvmgen", "fromarray"]
}
47 changes: 27 additions & 20 deletions .github/CODEOWNERS

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/small-change.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ Not applicable.

Not applicable.

## Interface changes

<!-- Describe any changed interfaces, such as topics, services, or parameters, including debugging interfaces -->

## Pre-review checklist for the PR author

The PR author **must** check the checkboxes below when creating the PR.
Expand Down
13 changes: 13 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/standard-change.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,19 @@

<!-- Describe any changed interfaces, such as topics, services, or parameters. -->

### ROS Topic Changes

<!-- | Topic Name | Type | Direction | Update Description | -->
<!-- | ---------------- | ------------------- | --------- | ------------------------------------------------------------- | -->
<!-- | `/example_topic` | `std_msgs/String` | Subscribe | Description of what the topic is used for in the system | -->
<!-- | `/another_topic` | `sensor_msgs/Image` | Publish | Also explain if it is added / modified / deleted with the PR | -->

### ROS Parameter Changes

<!-- | Parameter Name | Default Value | Update Description | -->
<!-- | -------------------- | ------------- | --------------------------------------------------- | -->
<!-- | `example_parameters` | `1.0` | Describe the parameter and also explain the updates | -->

## Effects on system behavior

<!-- Describe how this PR affects the system behavior. -->
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-and-test-arm64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Show disk space before the tasks
run: df -h
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-and-test-differential-arm64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-and-test-differential.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand Down Expand Up @@ -80,7 +80,7 @@ jobs:
container: ghcr.io/autowarefoundation/autoware-openadk:latest-prebuilt-cuda
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Show disk space before the tasks
run: df -h
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-build-depends.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
build-depends-repos: build_depends.repos
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Remove exec_depend
uses: autowarefoundation/autoware-github-actions/remove-exec-depend@v1
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/clang-tidy-pr-comments-manually.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Download analysis results
run: |
Expand All @@ -36,7 +36,7 @@ jobs:
- name: Check out PR head
if: ${{ steps.check-fixes-yaml-existence.outputs.exists == 'true' }}
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ${{ steps.set-variables.outputs.pr-head-repo }}
ref: ${{ steps.set-variables.outputs.pr-head-ref }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/clang-tidy-pr-comments.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Download analysis results
run: |
Expand All @@ -37,7 +37,7 @@ jobs:
- name: Check out PR head
if: ${{ steps.check-fixes-yaml-existence.outputs.exists == 'true' }}
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ${{ steps.set-variables.outputs.pr-head-repo }}
ref: ${{ steps.set-variables.outputs.pr-head-ref }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/delete-closed-pr-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ github.event.pull_request.head.sha }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/json-schema-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
outputs:
run-check: ${{ steps.paths_filter.outputs.json_or_yaml }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v3
id: paths_filter
with:
Expand All @@ -25,7 +25,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Run json-schema-check
uses: autowarefoundation/autoware-github-actions/json-schema-check@v1
Expand Down
7 changes: 3 additions & 4 deletions build_depends.repos
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@ repositories:
type: git
url: https://github.com/MORAI-Autonomous/MORAI-ROS2_morai_msgs.git
version: main
#vehicle
vehicle/sample_vehicle_launch:
universe/external/glog: # TODO: to use isGoogleInitialized() API in v0.6.0. Remove when the rosdep glog version is updated to v0.6.0 (already updated in Ubuntu 24.04)
type: git
url: https://github.com/autowarefoundation/sample_vehicle_launch.git
version: main
url: https://github.com/tier4/glog.git
version: v0.6.0_t4-ros
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ namespace types
// We don't currently require code to comply to MISRA, but we should try to where it is
// easily possible.
using bool8_t = bool;
#if __cplusplus < 201811L || !__cpp_char8_t
using char8_t = char;
#endif
using uchar8_t = unsigned char;
// If we ever compile on a platform where this is not true, float32_t and float64_t definitions
// need to be adjusted.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ struct ObjectPropertyValues
float alpha{0.999F};
};

// Control object marker visualization
enum class ObjectFillType { Skeleton, Fill };

// Map defining colors according to value of label field in ObjectClassification msg
const std::map<
autoware_auto_perception_msgs::msg::ObjectClassification::_label_type, ObjectPropertyValues>
Expand Down Expand Up @@ -87,7 +90,8 @@ get_shape_marker_ptr(
const autoware_auto_perception_msgs::msg::Shape & shape_msg,
const geometry_msgs::msg::Point & centroid, const geometry_msgs::msg::Quaternion & orientation,
const std_msgs::msg::ColorRGBA & color_rgba, const double & line_width,
const bool & is_orientation_available = true);
const bool & is_orientation_available = true,
const ObjectFillType fill_type = ObjectFillType::Skeleton);

AUTOWARE_AUTO_PERCEPTION_RVIZ_PLUGIN_PUBLIC visualization_msgs::msg::Marker::SharedPtr
get_2d_shape_marker_ptr(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,12 @@ class AUTOWARE_AUTO_PERCEPTION_RVIZ_PLUGIN_PUBLIC ObjectPolygonDisplayBase
m_confidence_interval_property->addOption("95%", 2);
m_confidence_interval_property->addOption("99%", 3);

m_object_fill_type_property = new rviz_common::properties::EnumProperty(
"Object Fill Type", "skeleton", "Change object fill type in visualization", this);
m_object_fill_type_property->addOption(
"skeleton", static_cast<int>(detail::ObjectFillType::Skeleton));
m_object_fill_type_property->addOption("Fill", static_cast<int>(detail::ObjectFillType::Fill));

// iterate over default values to create and initialize the properties.
for (const auto & map_property_it : detail::kDefaultObjectPropertyValues) {
const auto & class_property_values = map_property_it.second;
Expand Down Expand Up @@ -189,9 +195,13 @@ class AUTOWARE_AUTO_PERCEPTION_RVIZ_PLUGIN_PUBLIC ObjectPolygonDisplayBase
const bool & is_orientation_available) const
{
const std_msgs::msg::ColorRGBA color_rgba = get_color_rgba(labels);
const auto fill_type =
static_cast<detail::ObjectFillType>(m_object_fill_type_property->getOptionInt());

if (m_display_type_property->getOptionInt() == 0) {
return detail::get_shape_marker_ptr(
shape_msg, centroid, orientation, color_rgba, line_width, is_orientation_available);
shape_msg, centroid, orientation, color_rgba, line_width, is_orientation_available,
fill_type);
} else if (m_display_type_property->getOptionInt() == 1) {
return detail::get_2d_shape_marker_ptr(
shape_msg, centroid, orientation, color_rgba, line_width, is_orientation_available);
Expand Down Expand Up @@ -526,6 +536,8 @@ class AUTOWARE_AUTO_PERCEPTION_RVIZ_PLUGIN_PUBLIC ObjectPolygonDisplayBase
rviz_common::properties::EnumProperty * m_simple_visualize_mode_property;
// Property to set confidence interval of state estimations
rviz_common::properties::EnumProperty * m_confidence_interval_property;
// Property to set visualization type
rviz_common::properties::EnumProperty * m_object_fill_type_property;
// Property to enable/disable label visualization
rviz_common::properties::BoolProperty m_display_label_property;
// Property to enable/disable uuid visualization
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -495,23 +495,37 @@ visualization_msgs::msg::Marker::SharedPtr get_shape_marker_ptr(
const autoware_auto_perception_msgs::msg::Shape & shape_msg,
const geometry_msgs::msg::Point & centroid, const geometry_msgs::msg::Quaternion & orientation,
const std_msgs::msg::ColorRGBA & color_rgba, const double & line_width,
const bool & is_orientation_available)
const bool & is_orientation_available, const ObjectFillType fill_type)
{
auto marker_ptr = std::make_shared<Marker>();
marker_ptr->ns = std::string("shape");
marker_ptr->color = color_rgba;
marker_ptr->scale.x = line_width;

using autoware_auto_perception_msgs::msg::Shape;
if (shape_msg.type == Shape::BOUNDING_BOX) {
marker_ptr->type = visualization_msgs::msg::Marker::LINE_LIST;
calc_bounding_box_line_list(shape_msg, marker_ptr->points);
if (fill_type == ObjectFillType::Skeleton) {
marker_ptr->type = visualization_msgs::msg::Marker::LINE_LIST;
calc_bounding_box_line_list(shape_msg, marker_ptr->points);
} else if (fill_type == ObjectFillType::Fill) {
marker_ptr->type = visualization_msgs::msg::Marker::CUBE;
marker_ptr->scale = shape_msg.dimensions;
marker_ptr->color.a = 0.75f;
}
if (is_orientation_available) {
calc_bounding_box_direction_line_list(shape_msg, marker_ptr->points);
} else {
calc_bounding_box_orientation_line_list(shape_msg, marker_ptr->points);
}
} else if (shape_msg.type == Shape::CYLINDER) {
marker_ptr->type = visualization_msgs::msg::Marker::LINE_LIST;
calc_cylinder_line_list(shape_msg, marker_ptr->points);
if (fill_type == ObjectFillType::Skeleton) {
marker_ptr->type = visualization_msgs::msg::Marker::LINE_LIST;
calc_cylinder_line_list(shape_msg, marker_ptr->points);
} else if (fill_type == ObjectFillType::Fill) {
marker_ptr->type = visualization_msgs::msg::Marker::CYLINDER;
marker_ptr->scale = shape_msg.dimensions;
marker_ptr->color.a = 0.75f;
}
} else if (shape_msg.type == Shape::POLYGON) {
marker_ptr->type = visualization_msgs::msg::Marker::LINE_LIST;
calc_polygon_line_list(shape_msg, marker_ptr->points);
Expand All @@ -523,8 +537,6 @@ visualization_msgs::msg::Marker::SharedPtr get_shape_marker_ptr(
marker_ptr->action = visualization_msgs::msg::Marker::MODIFY;
marker_ptr->pose = to_pose(centroid, orientation);
marker_ptr->lifetime = rclcpp::Duration::from_seconds(0.15);
marker_ptr->scale.x = line_width;
marker_ptr->color = color_rgba;

return marker_ptr;
}
Expand Down
Loading

0 comments on commit 1bee188

Please sign in to comment.