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

Adding NDT reinitalization statement and reinitialization while moving #1375

Open
3 tasks done
ataparlar opened this issue Jul 19, 2022 · 25 comments
Open
3 tasks done
Labels
component:localization Vehicle's position determination in its environment. (auto-assigned) status:stale Inactive or outdated issues. (auto-assigned)

Comments

@ataparlar
Copy link
Contributor

Checklist

  • I've read the contribution guidelines.
  • I've searched other issues and no duplicate issues were found.
  • I've agreed with the maintainers that I can plan this task.

Description

NDT is initializes the position once in the beginning while vehicle is motionless. While moving if a topic used by autoware_launch stops streaming and starts streaming again, NDT reinitialization never starts. Eventually, vehicle starts to fly or starts turning around.
There is no reinitialization statement of NDT in the code. There must be a recovery mechanism for localization.

Here is a video of the issue.
https://youtu.be/MffXnseMeg0

Purpose

Making reinitalization of NDT correctly while moving.

Possible approaches

Writing a reinitialization statement to NDT node.

Definition of done

This is done when NDT reinitializes itself correctly without flying or turning.

@meliketanrikulu meliketanrikulu added the component:localization Vehicle's position determination in its environment. (auto-assigned) label Jul 19, 2022
@YamatoAndo
Copy link
Contributor

YamatoAndo commented Jul 20, 2022

I think the reinitalization is necessary.
However, I think it would be more versatile to put this function in a pose_initilizer node, etc., rather than in an NDT node, because it can be used even when the NDT node is not used.

I think that this feature will be one of the most important features for Autoware, so we need to discuss the architecture in detail. @mitsudome-r @yukkysaito

@cyn-liu
Copy link
Contributor

cyn-liu commented Jul 20, 2022

I have encountered a similar problem of how to reinitialize the NDT when it failed to match and localization failed, the vehicle starts turning around.
The following figure is a screenshot of the simulation of the localization module when the car passes the intersection and the point cloud matching fails, the blue line in the figure is the trajectory of the car.
图片

We believe that a reasonable solution in this case would be to first bring the vehicle to a slow stop, and then reinitialize the NDT.
However, we have the following questions:

  1. what flags are used to monitor localization failure. (my idea is to determine whether the localization fails based on whether score of the NDT match is greater than the threshold value of 2.3 )
  2. How to make the car stop slowly when the localization fails.(the current localization error monitoring module does not notify other modules to take emergency action after the localization failure.)

@isamu-takagi
Copy link
Contributor

How to make the car stop slowly when the localization fails.(the current localization error monitoring module does not notify other modules to take emergency action after the localization failure.)

We are now designing a mechanism to stop the vehicle in an emergency. Related information can be found here (note that this link will be invalid once the PR is merged). In this mechanism, a module that manages emergencies (fail-safe module in the figure on the above link) monitors the score from localization and activates MRM when an abnormality is detected.

@YamatoAndo
Copy link
Contributor

what flags are used to monitor localization failure. (my idea is to determine whether the localization fails based on whether score of the NDT match is greater than the threshold value of 2.3 )

We have the localization_error_monitor node to detect locazation failure using the variance estimated by EKF.
How about using this node?

@cyn-liu
Copy link
Contributor

cyn-liu commented Jul 20, 2022

what flags are used to monitor localization failure. (my idea is to determine whether the localization fails based on whether score of the NDT match is greater than the threshold value of 2.3 )

We have the localization_error_monitor node to detect locazation failure using the variance estimated by EKF. How about using this node?

We believe that it is not accurate to use the pose_with_covariance estimated by the EKF in the localization_error_monitor node to monitor whether the localization fails, because this variable lacks timeliness.
When the NDT score is below 2.3, we consider that the localization has failed at this point, while the ekf covariance is still small (close to 0), and the pose_with_covariance will only change significantly when the car is far from the correct position.
The following figure is a screenshot of the simulation of the localization module when the point cloud matching fails, and the blue line in the figure is the running track of the car.
图片
We recorded two sets of data during the simulation (NDT matching score and pose_with_covariance estimated by EKF ) and plot the curve to observe the trend of the datas (the red horizontal dashed line in the figure is y=2.3).
图片
The covariance of x-x and y-y does not change when the matching score starts below 2.3, and these two variables suddenly increase sharply when the car is far from the location. So we believe that using the current EKF estimated variance (pose_with_covariance) is not effective in monitoring the localization failure. The current localization_error_monitor node needs to be modified.

@autowarefoundation autowarefoundation deleted a comment from cyn-liu Jul 21, 2022
@YamatoAndo
Copy link
Contributor

@cyn-liu
I think you didn't use the odometry in your test.
I think if you put the odometry in the EKF, the estimated variance would be more reliable.

@cyn-liu
Copy link
Contributor

cyn-liu commented Jul 25, 2022

@cyn-liu I think you didn't use the odometry in your test. I think if you put the odometry in the EKF, the estimated variance would be more reliable.

Thanks for your replay, we will add odometer information for testing to verify that the variable estimated by the EKF are reliable.

@cyn-liu
Copy link
Contributor

cyn-liu commented Aug 1, 2022

@cyn-liu I think you didn't use the odometry in your test. I think if you put the odometry in the EKF, the estimated variance would be more reliable.

We added odometer information (wheel speed + IMU) to re-run the experiment and found that although the EKF output pose_with_covariance changes smoothly with a small fluctuation range, it does not solve the real-time problem. (Perhaps this is a characteristic of the algorithm itself, and the calculation of EKF covariance depends on the results of NDT
We did several experiments to plot the graphs using the output results of NDT score and EKF covariance during localization (the red vertical line in the figure below is the time when the NDT score is <2.3 for the first time, and the blue vertical line in the graph is the time when x-x covariance or y-y covariance of EKF is >0.1 for the first time). Assuming that x-x covariance or y-y covariance is greater than 0.1 (the localization error is 0.3m), we consider the localization failure.
图片
图片
As in Figure 1, the two vertical lines are about 3s apart, indicating that the EKF found the localization failure problem 3s later than the NDT.
As in Figure 2, the two vertical lines are about 4s apart, indicating that the EKF found the localization failure problem 4s later than the NDT.
The EKF covariance finds localization failure later than NDT score, and several experiments have found that it generally does not exceed 5s. Although using the EKF output result as the flag for localization failure cannot be very timely in detecting lost localization, if the delay is considered acceptable, the variable can correctly reflect whether the localization has failed.
It should be more timely to use the NDT matching score for determining whether the localization is failure or not.

@cyn-liu
Copy link
Contributor

cyn-liu commented Aug 1, 2022

How to make the car stop slowly when the localization fails.(the current localization error monitoring module does not notify other modules to take emergency action after the localization failure.)

We are now designing a mechanism to stop the vehicle in an emergency. Related information can be found here (note that this link will be invalid once the PR is merged). In this mechanism, a module that manages emergencies (fail-safe module in the figure on the above link) monitors the score from localization and activates MRM when an abnormality is detected.

Thanks for your job and I would like to ask about the progress of this PR so that I can make improvements to the localization module based on this work.
Looking forward to your reply!

@cyn-liu cyn-liu removed their assignment Aug 12, 2022
kminoda pushed a commit to kminoda/autoware.universe that referenced this issue Aug 17, 2022
* release v0.4.0

* Fix typo (#700)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix detection area (#701)

* Replace calcDistance with calcSignedDistance

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add STOP state

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* intersection: change detection area length parameter from 100m to 200m (#702)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection: fix stuck vehicle behavior (#695)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Feature/intersection use spline interpolation library (#710)

* Use spline_interpolation module

* Remove debug messages

* Feature/stop reason (#712)

* add stop reason msg

* add mock of stop resaon publisher

* change namespace of stop reason

* update stop reason msg

* add toRosPoint

* implement stop reason publisher of blind stop

* implement stop reason publisher of crosswalk

* implement stop reason publisher of intersection

* implement stop reason publisher of stop line

* implement stop reason publisher of trafficlight

* implement stop reason publisher of detection area

* fix bug

* remove unnecessary process

* add remained stop factor

* clean code

* fix bug

* not punlish stop reason if array size is 0

* add stop reason to stuck object in intersection

* add stop factor of obstacle stop planner

* add stop reason of surround_obstacle checker

* Apply review

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* fix message type

* delete unused message from cmake

* remove stopReasonStamped

* change topic name of stop reasons

Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix/stop reason (#724)

* input stop reason of traffic light

* add comment

* add empty traffic light handling

* change calculation method of traffic light position

* avoid 0 position output

* Fix/spline interpolation in intersection module (#726)

* Remove duplicating sample points

* Change isValidInput

* Apply clang-format

* Fix convergence check in PCG

* fix clac signed distance bug (#733)

* intersection: ignore stop plane when path[0] is in detection area (#739)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Publish tl states stamped (#744)

* Add TrafficLightStateStamped.msg

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use msg instead of struct

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Publish traffic light state

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Check if lamp state is empty

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Apply clang-format

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Cosmetic change

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* update visualization marker (#759)

* fix stack area (#758)

* dont check pointcloud (#765)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* fix stop factor of merge_from_private_area (#749)

* Revert "Publish tl states stamped (#744)" (#771)

This reverts commit 35a7e29e987afb29d9348b5f64866a584a65f753.

* fix intersection bug (#773)

* fix bug

* fix bug

* change uid of marker (#775)

* Fix/publish tl state stamped (#772)

* Publish tl states stamped (#744)

* Add TrafficLightStateStamped.msg

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use msg instead of struct

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Publish traffic light state

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Check if lamp state is empty

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Apply clang-format

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Cosmetic change

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Use dynamic pointer cast

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Fix blind spot areas and logic for creating a stop line (#732)

* Fix blind spot areas

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Change logic for creating a stop line

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Do not add marker when marker is empty

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Cosmetic change

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Return boost optional for first conflict point

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Return boost optional for intersection start point

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Apply clang

Signed-off-by: Daisuke Nishimatsu <border_goldenmarket@yahoo.co.jp>

* Fix/intersection stuck detect area (#764)

* fix stuck-vehicle detection area in intersection module

* separate vehicle param

* change the way ouf start idx count

* change param

* avoid to input -1 index (#777)

* add dead line and pass through when over dead line (#784)

* Add arg for input tl topic name (#783)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* change margin to 1.0m (#790)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* fix insert target point bug (#798)

* fix typo stop_liine to stop_line (#799)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* traffic light scene module : fix bug and change param (#800)

* fix bug (passs judge line)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* bug fix

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* change param

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* Intersection add debug comment (#803)

* blind spot : modify debug comment

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* merge from private road : modify debug comment

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection : modify debug comment

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection util: modify generateStopLine() for debug

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add comment

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Fix intersection preceeding lane query (#807)

* modified interseciton module to add lanelets in intersection to objective lanelets due to change in getPreceedingLaneletSequences()

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* update comment

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Fix blind spot area (#806)

* Fix blind spot area

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use range based for

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use std::unique to remove adjacent duplicates

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use generateFineCenterline

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix detection area start point

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Revert "Use generateFineCenterline"

This reverts commit 9d4f46bf65d7296b9286b30dfeed217a566a815c.

* Fix centerline of half lanelet

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix area start point

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Revert "fix insert target point bug (#798)" (#815)

This reverts commit 12eac2023538531e28a85a8914305cb534499f29.

* Fix/traffic light state (#801)

* fix bug (passs judge line)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* bug fix

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* change param

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* bug fix : remove stop state

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* add lower limit

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* change param (#821)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* stopline: parametrize check distance (#825)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Check if lanelets are sequential (#823)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* fix uninitialized variables (#816)

* Parameterization for calculating judge line distance (#831)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* remove ROS1 packages temporarily

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Revert "remove ROS1 packages temporarily"

This reverts commit 96b63e981899f79f2f5c6a6377e9600cc278e233.

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* add COLCON_IGNORE to ros1 packages

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Rename launch files to launch.xml (#28)

* Port behavior_velocity_planner to ROS2 (#80)

* Revert "Add geometry2 to repos (#76)"

This reverts commit 6d2270476aaafdf1a8098d700d52a508525ea04b.

* Automatic parts of the package port

* Interesting part

* Fix typo in package.xml

* Review comments

* Child logger names

* Document logging duration

Co-authored-by: Ryohsuke Mitsudome <43976834+mitsudome-r@users.noreply.github.com>

* [ROS2] Fix behavior velocity planner (#110)

* install launch and config folders

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* port launch file

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* fix config files

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* improve vehicle_info_utils to enable multiple declaration of VehicleInfo objects

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* fix sementation fault

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Convert calls of Duration to Duration::from_seconds where appropriate (#131)

* Rename h files to hpp (#142)

* Change includes

* Rename files

* Adjustments to make things compile

* Other packages

* Adjust copyright notice on 532 out of 699 source files (#143)

* Use quotes for includes where appropriate (#144)

* Use quotes for includes where appropriate

* Fix lint tests

* Make tests pass hopefully

* Run uncrustify on the entire Pilot.Auto codebase (#151)

* Run uncrustify on the entire Pilot.Auto codebase

* Exclude open PRs

* fixing trasient_local in ROS2 packages (#160)

* Enable cppcheck lints in behavior_velocity_planner (#159)

* Enable lints in behavior_velocity_planner

* Fix package.xml

* Make launch files load vehicle model params dependent on argument (#228)

* Make vehicle_model configurable in behavior_velocity_planner

* Make vehicle_model configurable in vehicle_cmd_gate

* change from vehicle_model to vehicle_param_file (#242)

Signed-off-by: kosuke murakami <kosuke.murakami@tier4.jp>

* Ros2 v0.8 fix typo of "preceding" (#323)

* Fix typo of getPrecedingLaneletSequences

* Fix comment

* Ros2 v0.8.0 behavior velocity planner (#332)

* restore behavior velocity planner files for v0.8.0 update

* Fix detection area (#808)

* Remove PASS state

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Keep stopping after going over dead-line in STOP state

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Clear state after obstacle disappears

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Parameterize and change conditions

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Refactor

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* add elapsed time checker

* Refactor

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Ignore inserting point if points are too close

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Rename NORMAL to GO

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Revert "Ignore inserting point if points are too close"

This reverts commit 91c8d620ea11e703611945cb9a50877d175f4ff6.

* Fix small bug

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: taichiH <azumade.30@gmail.com>

* fix timing of publish stop reason of stop_line (#845)

* fix timing of publish stop reason of stop_line

* Fix formatting

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix task registration of detection area module (#856)

* Fix task registration of detection area module

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix id of factor_text marker

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Do not interpolate if path size is 1 (#865)

* Revert "restore behavior velocity planner files for v0.8.0 update"

This reverts commit ce07d3c2bfae562d56fec46c4f81d5351fd936a1.

* fix some implement miss

* restore behavior velocity planner files for v0.8.0 update

* change intersection param (#861)

* Fix/intersection stop line (#841)

* add trimmed path function

* fix typo

* avoid to insert stop line outside intersection

* Add pass judge flag (#872)

* Add pass judge flag

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix wrong format

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix flag order in judge condition

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* add ignore width with blind spot (#864)

* add ignore width with blind spot

* remove unused function

* fix typo

* fix margin

* remove bicycle from intersection stuck vehicle (#896)

* Revert "restore behavior velocity planner files for v0.8.0 update"

This reverts commit ff61ee56f2ce4728e53eb698836db60d68bf64b9.

* fix implement miss

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Add external traffic light input (#912)

* Add external traffic light input

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Update topic namespace

* Fix typos in planning modules (#866)

* fix typos in planning

* fix corresponding typos in planning

* revert fixed typos temporarily due to its impact on launchers

* add exception handling to intersection module (#920)

* add exception handling

* output input path

* prevent passthrough chattering (#901)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* cosnider current_velocity to calculate intersection passing time (#880)

* cosnider current_velocity to calculate intersection passing time

* add fabs to current velocity

* Improve stuck vehicle detect (#824)

* intersection: modify stuck vehicle detect logic to consider the object shape

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection: consider ego-vehicle length when calculate stuck vehicle detection area

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection: change param stuck_vehicle_ignore_dist: 5.0 -> 7.0

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* intersection: use vehicle_info/vehicle_length

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix implement miss

* fix target pedestrian (#927)

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* fix insert backward point (#953)

* fix insert backward point

* add comment

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* remove unnecessary if

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* Add stop line referred from road marking (#968)

* Add stop line referred from road marking

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add stop line for walkway

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Feature/external input (#982)

* add external input msg

* impl external input(crosswalk, intersection)

* :put_litter_in_its_place:

* change to ++14

* fix bug

* fix bug

* cosmetic change

* Revert "restore behavior velocity planner files for v0.8.0 update"

This reverts commit ff61ee56f2ce4728e53eb698836db60d68bf64b9.

* Fix typo (#1013)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix/blind spot insert point (#1027)

* Copy insert point from previous point

* Reset path unless state is stop

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* change slow down speed (#1030)

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Fix/walkway stop judge range (#1028)

* Fix walkway stop judge

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Make refer id same

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* fix getObjectivePolygons() so that intersecting lanelet is added to objective lanelets even when there is no preceeding lanelets (#1010)

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Revert "restore behavior velocity planner files for v0.8.0 update (fixed)"

This reverts commit 39231f23eb17e39a418f28f5ccfe1df55b3fb45c.

* fix implement miss for marker

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Fix/blind spot polygon (#1056)

* Fix detection area for blind spot

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Apply clang format

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Shrink conflicting area

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* chane slowdown judgement (#1066)

* chane slowdown judgement

* cosmetic change

* Revert "restore behavior velocity planner files for v0.8.0 update (fixed)"

This reverts commit 39231f23eb17e39a418f28f5ccfe1df55b3fb45c.

* fixed for ros2 style

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Remove unused headers in behavior_velocity_planner (#1072)

* publish walkway stop reason (#1073)

* Revert "restore behavior velocity planner files for v0.8.0 update (fixed)"

This reverts commit 39231f23eb17e39a418f28f5ccfe1df55b3fb45c.

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Add correspondence marker of detection_area and stop_line (#1081)

* Fix comment

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add const

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add correspondence marker of detection_area and stop_line

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add obstacle marker

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fixup

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add id marker

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Clear state when time rollback found

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix typo

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* change stop to polygon line

* apply clang format

* fix code

* fix bug

Co-authored-by: taichiH <azumade.30@gmail.com>

* Fix pass judge idx (#1090)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* fix bug (#1087)

* Revert "restore behavior velocity planner files for v0.8.0 update (fixed)"

This reverts commit 39231f23eb17e39a418f28f5ccfe1df55b3fb45c.

* fix for ros2 style

* restore behavior velocity planner files for v0.8.0 update (fixed)

* Fix/remove duplicated point (#1107)

* Split PoseDeviaiton functions

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Remove unnecessary pose

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Don't insert point if duplicated point exists

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix condition of duplicated points

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* seperate stop distance param (#1137)

* seperate stop distance param

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* apply param for automotically generated stop line

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* shift slow down line

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* add param in yaml file

Signed-off-by: Kosuke Murakami <kosuke.murakami@tier4.jp>

* fix prediction_time_margin bug (#1148)

* Revert "restore behavior velocity planner files for v0.8.0 update (fixed)"

This reverts commit 39231f23eb17e39a418f28f5ccfe1df55b3fb45c.

* fix ros2 style

* remove deprecated

* reformat

* add test temporary launch

* cpp_lint_namespace_what_you_use

* lint_comment_line_length

* pass ament cpplint

* fixe commit

* fix code

* remove unneccesary

* fix param structure

* fix missng params

* fix throttle time

Co-authored-by: tomoya.kimura <tomoya.kimura@tier4.jp>
Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>
Co-authored-by: taichiH <azumade.30@gmail.com>
Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>
Co-authored-by: Fumiya Watanabe <rej55.g@gmail.com>
Co-authored-by: Daisuke Nishimatsu <42202095+wep21@users.noreply.github.com>
Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>
Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>
Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>
Co-authored-by: Kosuke Murakami <kosuke.murakami@tier4.jp>
Co-authored-by: Ryohsuke Mitsudome <43976834+mitsudome-r@users.noreply.github.com>

* Rename ROS-related .yaml to .param.yaml (#352)

* Rename ROS-related .yaml to .param.yaml

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Remove prefix 'default_' of yaml files

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Rename vehicle_info.yaml to vehicle_info.param.yaml

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Rename diagnostic_aggregator's param files

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix overlooked parameters

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* [behavior_velocity_planner]: Fix missing ros2 porting (#392)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix error handling of tf lookupTransform (#405)

Co-authored-by: autoware <autoware@example.com>

* rm_std_msgs (#402)

* Sensor data qos (#407)

* Use sensor data qos for pointcloud preprocessor

Signed-off-by: Autoware <autoware@tier4.jp>

* Use sensor data qos for pointcloud

Signed-off-by: Autoware <autoware@tier4.jp>

* Fix lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use sensor data qos for livox tag filter and vector map filter

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Autoware <autoware@tier4.jp>

* Ros2 fix topic name part1 (#408)

* Fix topic name of lane_departure_checker debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of mpc_follower debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of velocity_controller debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of motion_velocity_optimizer debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of lane_change_planner debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of behavior_velocity_planner debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of obstacle_avoidance_planner debug

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of behavior_velocity_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of motion_velocity_optimizer

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of lane_departure_checker

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of mpc_follower

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of behavior_velocity_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of velocity_controller

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of lane_change_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of obstacle_avoidance_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of obstacle_stop_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of costmap_generator

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of freespace_planner

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of surround_obstacle_checker

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of costmap_generator

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of emergency_handler

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint errors

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix typo

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix typo in planning module (#432)

* Fix typo in planning module

* Fix remaining errors

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Apply cpplint and uncrustify.

Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* fix traffic light module (#458)

* change log type (#459)

* add use_sim-time option (#454)

* Fix rolling build errors (#1225)

* Add missing include files

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Replace rclcpp::Duration

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Use reference for exceptions

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Use from_seconds

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Sync public repo (#1228)

* [simple_planning_simulator] add readme (#424)

* add readme of simple_planning_simulator

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Update simulator/simple_planning_simulator/README.md

* set transit_margin_time to intersect. planner (#460)

* Fix pose2twist (#462)

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Ros2 vehicle info param server (#447)

* add vehicle_info_param_server

* update vehicle info

* apply format

* fix bug

* skip unnecessary search

* delete vehicle param file

* fix bug

* Ros2 fix topic name part2 (#425)

* Fix topic name of traffic_light_classifier

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of traffic_light_visualization

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of traffic_light_ssd_fine_detector

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name of traffic_light_map_based_detector

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint traffic_light_recognition

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint traffic_light_ssd_fine_detector

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint traffic_light_classifier

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint traffic_light_classifier

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix lint traffic_light_ssd_fine_detector

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix issues in hdd_reader (#466)

* Fix some issues detected by Coverity Scan and Clang-Tidy

* Update launch command

* Add more `close(new_sock)`

* Simplify the definitions of struct

* fix: re-construct laneletMapLayer for reindex RTree (#463)

* Rviz overlay render fix (#461)

* Moved painiting in SteeringAngle plugin to update()

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* super class now back to MFD

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* uncrustified

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* acquire data in mutex

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* back to RTD as superclass

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* Rviz overlay render in update (#465)

* Moved painiting in SteeringAngle plugin to update()

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* super class now back to MFD

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* uncrustified

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* acquire data in mutex

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* removed unnecessary includes and some dead code

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* Adepted remaining vehicle plugin classes to render-in-update concept. Returned to MFD superclass

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

* restored RTD superclass

Signed-off-by: Adam Dabrowski <adam.dabrowski@robotec.ai>

Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Takagi, Isamu <43976882+isamu-takagi@users.noreply.github.com>
Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>
Co-authored-by: Makoto Tokunaga <vios-fish@users.noreply.github.com>
Co-authored-by: Adam Dąbrowski <adam.dabrowski@robotec.ai>

* Unify Apache-2.0 license name (#1242)

* Make planning modules components (#1263)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Remove use_sim_time for set_parameter (#1260)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Refactor vehicle info util (#1305)

* Update license

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Refactor vehicle_info_util

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Rename and split files

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix interfaces

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix bug and add error handling

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add "// namespace"

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add missing include

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* fix slow/stop marker color & stop reason (#1347) (#1354)

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>
Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* fix intersection stop line (#1272) (#1349)

* fix intersection stop line (#1272)

* fix intersection stop line

* fix comment

* Fix typo

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Avoid passing empty lanelets to getPolygonFromArcLength (#1371)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add perception traffic light state output (#1302)

* Add perception traffic light state output

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Modify message type

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Apply message type to relay

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Feature/consider jerk limit in passjudge (#1339) (#1351)

* Feature/consider jerk limit in passjudge (#1339)

* make new branch for behavior velocity planner

* update implementation for considering accel & jerk limit

* refactoring

* change default params

* change default params

* change minimum velocity which decides to conduct pass judge

* remove ROS_DEBUG_COND()

* remove unnecessary variables

* fix lowpass filter implementation

* calc acceleration in planner_data_

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* Fix typo

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* Feature/refactor stop line module (#1343) (#1359)

* Refactor stop_line planner module

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add document

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix English

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>

* Feature/add stop duration ros2 (#1380)

* Feature/add stop duration (#1367)

* Add stop_duration to behavior_velocity_planner

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* parameterize stop duration sec

* Use stop_duration in Stop Line module

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Hiroki OTA <hiroki.ota@tier4.jp>
Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Change default value

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>
Co-authored-by: Hiroki OTA <hiroki.ota@tier4.jp>
Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix topic name of external traffic light input (#1412)

* publish perception and external tl_state for mlops (#1350) (#1375)

* publish perception and external tl_state for mlops

* fix tl_state time stamp

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* Fix/traffic light planning module (#1424) (#1487)

* Fix/traffic light planning module (#1424)

* bug fix

* refactor

* refactor

* cosmetic change

* fix typo

* cosmetic change

* refactor

* remove unused func

* enable restart

* cosmetic change

* fix typo

* refactor

* bug fix

* cosmetic change

* modify debug_data

* Apply lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Remove unnecesarry comment

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix bug

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

* change msg type looking traffic light state (#1494)

* change msg type looking traffic light state (#1455)

* change msg type looking traffic light state

* fix msg name

* using namespace

* change function name

* fix typo

* add readme

* Update awapi/awapi_awiv_adapter/Readme.md

fix typo

Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

* Remove deprecated message include

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

* Add namespace to behavior_velocity_planner (#1542)

* Add namespace to behavior_velocity_planner

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix typo

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Avoid passing uninitialized index (#1609)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* suppress warnings  for behavior_velocity_planner (#1733)

* add Werror

* suppress warnings for stopline module

* fix for crosswalk

* fix for traffic light

* fix for detection area

* fix style

* use {}

* use auto

* Fix -Wunused-parameter (#1836)

* Fix -Wunused-parameter

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix mistake

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* fix spell

* Fix lint issues

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Ignore flake8 warnings

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Hiroki OTA <hiroki.ota@tier4.jp>

* Fix compiler warnings (#1837)

* Fix -Wunused-private-field

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wunused-variable

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wformat-security

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Winvalid-constexpr

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wdelete-non-abstract-non-virtual-dtor

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wdelete-abstract-non-virtual-dtor

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Winconsistent-missing-override

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wrange-loop-construct

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix "invalid application of 'sizeof' to an incomplete type"

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Ignore -Wgnu-anonymous-struct and -Wnested-anon-types

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix lint

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Ignore -Wno-deprecated-declarations in CUDA-related packages

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix mistake

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix -Wunused-parameter

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add autoware api (#1979)

* Feature/add virtual traffic light planner (#1588)

* add sort-package-xml hook in pre-commit (#1881)

* add sort xml hook in pre-commit

* change retval to exit_status

* rename

* add prettier plugin-xml

* use early return

* add license note

* add tier4 license

* restore prettier

* change license order

* move local hooks to public repo

* move prettier-xml to pre-commit-hooks-ros

* update version for bug-fix

* apply pre-commit

* remove spline_interpolation, and create interpolation package that ha… (#2114)

* remove spline_interpolation and add interpolation package

* fix bugs and add simple test

* modify application for interpolation package

* add some tests and fix ci test

* add some tests

* add -Werror

* move functions to anonymous

* fix reviews

* fix typo

* fix review and lint

* add tests

* resolve TODOs

* add README.md

* Update common/math/interpolation/test/src/test_interpolation_utils.cpp

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>

* Update common/math/interpolation/test/src/test_interpolation_utils.cpp

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>

* Update common/math/interpolation/test/src/test_interpolation_utils.cpp

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>

* fix README.md

* dealt with reviews

* update README.md

* update README.md

* Update common/math/interpolation/README.md

* fix some bugs

* fix typo

* update README.md

* Update common/math/interpolation/README.md

Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

* fix test

* Update common/math/interpolation/README.md

Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

* fix cdots

* fix README.md

* Update common/math/interpolation/README.md

Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>
Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

* Sync develop/fix interpolation and speed up calculation (#2290)

* debug slope calculation in behavior (#1566) (#1727)

* debug slope calculation in behavior (#1566)

* update

* update

* revert change of autoware_utils

* define getPose in behavior_path_planner

* update

* update

* update

* update

* interpolate z in obstacle_avoidance_planner

* update velocity controller

* fix detection area and scene

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/src/utilities.cpp

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* update comment in velocity controller

* remove debug print

* update

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix typo

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix variable names

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix uncrustify

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix mistake

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Co-authored-by: Takayuki Murooka <takayuki5168@gmail.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* add underscore to marker namespace (#1785)

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* [obstacle_avoidance_planner] remove useless get nearest idx (#1851)

* modify velocity insertion in obstacle_avoidance_planner

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* [obstacle_avoidance_planner] reduce calculation cost in relative/absolute transformation (#1844)

* implement relative/absolute transformation without yaw but directly sin/cos of yaw

* rename: relative_p to absolute_p

* assigin point.z to rel/abs_z

* fix cpp-lint error

Co-authored-by: Daisuke Nishimatsu <42202095+wep21@users.noreply.github.com>
Co-authored-by: Takayuki Murooka <takayuki5168@gmail.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>
Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>
Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix argument order (#1502) (#1622)

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* Change param (#1559) (#1677)

Co-authored-by: Fumiya Watanabe <rej55.g@gmail.com>

* Feature/use spline module in behavior velocity planner (#1457) (#1495)

* Feature/use spline module in behavior velocity planner (#1457)

* Use spline_interpolation module

* Remove unused function

* Remove unused include

* Use autoware_utils

* Remove unused function

* Remove cubic_spline.hpp

* Fix error handling

* Fix interpolation of velocity

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* change warning threshold (#1539)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Apply lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Fumiya Watanabe <rej55.g@gmail.com>
Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Feature/porting behavior path planner (#1645)

* Add behavior path planner pkg with Lane Change (#1525)

* add lanelet extension funcs

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add planning msgs for FOA

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add behavior_path_planner pkg

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* apply clang format

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add error handling for config load failure

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* replace word: foa with remote control

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add readme

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* use pointer for return value of path

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix hz

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove debug print

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove shide-shift & avoidance related files

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Clip path by goal

* add build depend for behavior tree cpp

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* temporally disable lint test in lanelet2_extension

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

Co-authored-by: rej55 <rej55.g@gmail.com>

* Add avoidance module in behavior_path_planner (#1528)

* Revert "remove shide-shift & avoidance related files"

This reverts commit d819ea0291fca251012e4b9ffd16de3896830aa2.

* refactor findNewShiftPoint func

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove duplicated decleration

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix barkward length issue
 - add clipPathLenght func in avoidance

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* refactor:
 - translate english
 - minor modification for traffic distance

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* support debug marker in behavior_path_planner

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* clean up side shift module

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* change topic name

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove japanese

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/include/behavior_path_planner/scene_module/side_shift/side_shift_module.hpp

Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

* fix typo

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove unused var

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* adress reviewer comments:
 - add const for variables
 - add comment
 - fix typo

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix typo

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>

* Replace behavior_path utilities with autoware_utils (#1532)

* replace calcDistance

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* replace arange

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* replave convertToEigenPt with autoware_utils::fromMsg

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* replace normalizeRadian

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* cosmetic change

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* import #1526 into behavior path planner (#1531)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Fix/behavior path empty path output guard (#1536)

* add guard

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/src/behavior_path_planner.cpp

* fix lateral jerk calculation (#1549)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix: error handling on exception in behavior_path_planner (#1551)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Fix ignore too steep avoidance path (#1550)

* ignore too steep path

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/src/scene_module/avoidance/avoidance_module.cpp

* parametrize lateral jerk limit

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/include/behavior_path_planner/scene_module/avoidance/avoidance_module.hpp

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* use offsetNoThrow and add error log (#1615)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Ignore object ahead goal for avoidance (#1618)

* Ignore object ahead goal for avoidance

* Add flag

* Fix position of definition of goal_pose

* Fix arclength calculation

* Fix position of definition of goal_pose

* fix intersection stop line (#1636)

* fix intersection stop line

* fix typo

* add document (#1635)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Port behavior path planner to ros2

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Apply lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix typo

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix map qos

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* debug slope calculation in behavior (#1566)

* update

* update

* revert change of autoware_utils

* define getPose in behavior_path_planner

* update

* update

* update

* update

* interpolate z in obstacle_avoidance_planner

* update velocity controller

* fix detection area and scene

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/src/utilities.cpp

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* update comment in velocity controller

* remove debug print

* update

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Address review: Fix config file name

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* pre-commit fixes

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix redeclaring parameters

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add missing tf2 geometry function

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Apply lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix rclcpp Time initialization

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use now() instead of msg stamp

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Use throttle output in getExpandedLanelet

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add missing const

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>
Co-authored-by: rej55 <rej55.g@gmail.com>
Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Takayuki Murooka <takayuki5168@gmail.com>

* Fix/generate intersection stop (#1590) (#1679)

* Fix/generate intersection stop (#1590)

* fix bug of conflicting polygons

* clean code

* Fix lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Fix/stop margin time ros2 (#1683)

* Add stop margin time in walkway and merge_from_private_area (#1613)

* Add stop margin time in walkway, merge_from_private_area

* Fix param name

* Fix bug

* Apply lint

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Fumiya Watanabe <rej55.g@gmail.com>

* Feature/change stop lines handling to support parking car avoidance p… (#1676)

* Feature/change stop lines handling to support parking car avoidance path (#1464)

* support parking car avoidance

* change log level

* apply clang-format

* add extendLine function

* clean up & apply clang-format

* change implementation getStopPoseFromMap()

* remove unuse comment line

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* fix argument order (#1580)

Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

Co-authored-by: Satoshi OTA <44889564+satoshi-ota@users.noreply.github.com>
Co-authored-by: satoshi-ota <satoshi.ota@gmail.com>

* Feature/porting occlusion spot (#1740)

* Feature/occlusion_spot safety planner public road (#1594)

* add blind spot safety planner public road

* remove duplicated procesing

* remove unused private param

* renaming fix typo add comments

* fix spell check

* velocity -> relative velocity

* calc2d, To param, simplify search, To original

* add the num possible collision gurd

* computational cost reduction

* Cosmetic change for PossibleCollisionInfo

* add interpolation to possible collision value

* refactor codes

* fix details

* invalid point gurd

* To Param

* refacotor to occlusion spot util

* cosmetic change

* clean up blindspot

* To Occlusion Spot

* revise readme

* refactor drawing

* for better explanation

* fix velocity profile

* clean up details

* cosmetic change for debug marker

* use max velocity in obstacle info instead

* add gtest for Too Many Possible Collision case

* change case

* refactor readme

* minor fix

* add more occlusion spot explanation

* replace svg

* add gtest build path lanelet

* hotfix lateral distance and searching method

* update g test for lateral distance

* use faster search

* set more realistic param

* add lanelet subtype highway

* cosmetic change of reviews

* add occlusion spot module in private area (#1640)

* add occlusion spot in private

* For debugging change

* add spline interpolation to path

* add review changes

* adding minor change

* cosmetic change

* Vector to retval

* Blindspot To OcclusionSpot1

* To Occlusion Spot 2

* To Occlusions spot3

* update gtest with unified anchor

* remove anchor

* add test slice

* simplify interpolation

* Too Occlusion spot4

* add test buffer

* To Occlusion spot

* namespace gurd

* correct slice and add interpolation first

* handle self crossing with check for invation

* to ros debug stream

* removed unused interpolation

* add readme to plant uml

* cosmetic change

* minor change

* update readme

* review change

* change occlusion spot text color

* To Offset no Throw

* better debug marker

* catch only inversion error

* skip return in case of inversion

* for better grid

* simplify path lanelet at first

* remove std::cout

* for better path

* limit ego path inside target lanelet location

* remove last points

* cosmetic change for markers

* apply module for limited scene

* fix interpolation gurd

* for better params

* do not includes path behind

* remove dummy perception publisher

* Revert "remove dummy perception publisher"

This reverts commit 4acad985fe31dd9befaa21a16631495de6c3a117.

* replace hard coded occupancy grid option in psim

* remove respawn

* add arg to params and remove redundunt launch

* fix spell check

* fix default value

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Feature/occlusion spot private slice size param (#1703)

* add min slice size

* for a bit narrow lateral distance

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/config/occlusion_spot_param.yaml

Co-authored-by: Maxime CLEMENT <78338830+maxime-clem@users.noreply.github.com>

Co-authored-by: Maxime CLEMENT <78338830+maxime-clem@users.noreply.github.com>

* Rename files

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Porting to ros2

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* pre-commit fixes

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix typo

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix launch namespace

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Fix parameter type

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/src/scene_module/occlusion_spot/scene_occlusion_spot_in_private_road.cpp

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: Maxime CLEMENT <78338830+maxime-clem@users.noreply.github.com>

* fix function name and condition for detection area (#1758)

* Fix build warning for occlusion spot (#1766)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix passing uninitialized index (#1792)

* Fix passing uninitialized index

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Apply uncrustify

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix return value

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix/intersection bug (#1787)

* fix insert point function

* apply format

* separate insertPoint and hasDuplicatedPoint

* clean code

* fix bug

* replace velocity if collision point is too close to original path point (#1799)

* replace velocity if collision point is too close to original path point

* fix comment

* Fix compile warnings (#1852)

Fix -Wunused-parameter

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Fix -Wunused-private-field

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Fix -Wunused-lambda-capture

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Fix -Wdelete-non-abstract-non-virtual-dtor

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Fix -Wrange-loop-construct

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

Ignore lint error

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Document / behavior velocity planner (#1767)

update document

Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

* fix occlusion spot insert velocity ros2 (#1821)

* Fix/occlusion spot offset (#1824)

* merge calcCollisionFunction

* ConsiderSignedOffset

* add extractRoadTargetAndSignedOffset

* apply signed offset and fix longitudinal distance

* fix unapplied param

* update gtest

* consider offset until target road

* refactor for proper variable name

* fix typo

* remove unused first index

* fix closest

* fix diff

* fix velocity and height

* tune distance thershold

* fix colcon test

* apply param at the experiment

* fix unused and param

* Fix/current acc initialize (#1899)

* use boost::optional

* null guard

* fix typo

* Feature/improve intersection detection area (#1958)

* exclude ego_lanes from detection_area

* add empty handling

* remove unused function

* Fix for uncrustify

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>

* [behavior_velocity_planner] remove unnecessary graph search to reduce computational cost (#1980)

* remote unnecessary graph search

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* add var for graph id

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* remove unused stopline search for computational cost reduction

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* restore lane_ids iteration as it was

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* sort sidewalk slice by arc length (#1967)

* sort sidewalk slice by arc length

* handle invalid index

* divide offset to ego to closest to and closest to target

* fix cartesian distance to arc lane distance

* consider ego to target to ignore length

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/src/scene_module/occlusion_spot/occlusion_spot_utils.cpp

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>

* Fix/merge from private area (#2005)

* fix insert pos. of merge from private area

* exclude entrance of private road from path

* extract exit of private road

* Feature/intersection module detect obstacle (#1990)

* change the way to detect target objects in detection area

* check the angle of deteced objects

* ignore predicted path with low confidence

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/include/scene_module/intersection/scene_intersection.hpp

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/include/scene_module/intersection/scene_intersection.hpp

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/README.md

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>

* Update planning/scenario_planning/lane_driving/behavior_planning/behavior_velocity_planner/include/scene_module/intersection/scene_intersection.hpp

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>

* fix format

* fix object position judge

* change function

* apply format

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>

* occlusion spot lower min ego velocity (#2140)

Co-authored-by: taikitanaka3 <taiki.tanaka@tier4.jp>

* add behavior velocity planner utils (#2113)

* add gtest utils

* add state machine as utils

* add arc lane utils

* remove empty file

* add gtest for offset segment

* use calcdist2d in autoware util

* apply get point

* fix uncrustify

* fix conflict getPoint in behavior path

* apply commit suggestion

* slower than ros1

* use interpolation::slerp (#2161)

* Update traffic light state if ref stop point is ahead of previous one (#2197) (#2240)

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Daisuke Nishimatsu <42202095+wep21@users.noreply.github.com>

* Change formatter to clang-format and black (#2332)

* Revert "Temporarily comment out pre-commit hooks"

This reverts commit 748e9cdb145ce12f8b520bcbd97f5ff899fc28a3.

* Replace ament_lint_common with autoware_lint_common

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Remove ament_cmake_uncrustify and ament_clang_format

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Apply Black

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Apply clang-format

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix build errors

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix for cpplint

* Fix include double quotes to angle brackets

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Apply clang-format

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix build errors

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add COLCON_IGNORE (#500)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* rename topic name twist -> odometry (#568)

Co-authored-by: Takayuki Murooka <takayuki.murooka@tier4.jp>

* Auto/behavior velocity (#605)

* port except for traffic light

* fix test

* update traffic light

* fix errors

* rename traffic message: final -> result

* fix package.xml

* twist -> odometry

* use confidence

* rename topic name of dynamic objects

* remove TODOs

* deal with probabilistic test failure

* deal with probabilistic test failure2

Co-authored-by: Takayuki Murooka <takayuki.murooka@tier4.jp>

* Sync .auto branch with the latest branch in internal repository (#691)

* add trajectory point offset in rviz plugin (#2270)

* sync rc rc/v0.23.0 (#2258)

* fix interpolation for insert point (#2228)

* fix interpolation for insert point

* to prev interpolation pkg

* Revert "to prev interpolation pkg"

This reverts commit 9eb145b5d36e297186015fb17c267ccd5b3c21ef.

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>
Co-authored-by: taikitanaka <ttatcoder@outlook.jp>

* fix topic name (#2266)

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Add namespace to diag for dual_return_filter (#2269)

* Add a function to make 'geometry_msgs::msg::TransformStamped' (#2250)

* Add a function to make 'geometry_msgs::msg::TransformStamped'
* Add 'child_frame_id' as an argument of 'pose2transform'

* Simplify marker scale initialization (#2286)

* Fix/crosswalk polygon (#2279)

* extend crosswalk polygon

* improve readability

* fix polygon shape

* Add warning when decel distance calculation fails (#2289)

Signed-off-by: Makoto Kurihara <mkuri8m@gmail.com>

* [motion_velocity_smoother] ignore debug print (#2292)

* cosmetic change

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* cahnge severity from WARN to DEBUG for debug info

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* use util for stop_watch

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* fix map based prediction (#2200)

* fix map based prediction

* fix format

* change map based prediction

* fix spells

* fix spells in comments

* fix for cpplint

* fix some problems

* fix format and code for clang-tidy

* fix space for cpplint

* Update Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

* fix vector access method

* fix readme format

* add parameter

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

Co-authored-by: Kazuki Miyahara <kmiya@outlook.com>

* Update perception/object_recognition/prediction/map_based_prediction/Readme.md

Co-authored-by: Kazuki Miyahara <kmiya@out…
@meliketanrikulu
Copy link
Contributor

How to make the car stop slowly when the localization fails.(the current localization error monitoring module does not notify other modules to take emergency action after the localization failure.)

We are now designing a mechanism to stop the vehicle in an emergency. Related information can be found here (note that this link will be invalid once the PR is merged). In this mechanism, a module that manages emergencies (fail-safe module in the figure on the above link) monitors the score from localization and activates MRM when an abnormality is detected.

Hello. Thanks for your job.I think this is your merged PR about documentation. Could you please share with us if there is any progress in the development phase regarding the situation where the localization fails.

I think we agree that the NDT score can be used to determine the break off the NDT. I want to start working to be able to reinitialize the score based on it. Do you have any other suggestions about this? Thanks for your suggestions.

@mitsudome-r mitsudome-r added the priority:high High urgency and importance. label Aug 23, 2022
@meliketanrikulu
Copy link
Contributor

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

@mitsudome-r mitsudome-r moved this to Todo in Bus ODD Project Aug 23, 2022
@mitsudome-r
Copy link
Member

mitsudome-r commented Aug 24, 2022

From yesterday's ASWG, we reviewed the scope of this issue. I have confirmed with LeoDrive that their current demand is to detect localization failure as quick as possible. We can discuss about automatic reinitialization as mid/long-term goal.

I'm currently asking localization team if they have any tools to help you find the best threshold or any idea that might help you
detect the localization failure.

@cyn-liu
Copy link
Contributor

cyn-liu commented Aug 24, 2022

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

To be honest, I dont think NDT match score is best choice to determine if the localization fails , I just compare the output of NDT match more reliably than the output of EKF to judge if the localization fails.

In the test video you shared, the NDT match score is still higher than the threshold for a while after the localization is lost. Did you check the variable of iteration_num when this happened, maybe it is already greater than the threshold of 32, usually the NDT score or iteration_num deviates from the threshold after the localization is lost.

@meliketanrikulu
Copy link
Contributor

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

To be honest, I dont think NDT match score is best choice to determine if the localization fails , I just compare the output of NDT match more reliably than the output of EKF to judge if the localization fails.

In the test video you shared, the NDT match score is still higher than the threshold for a while after the localization is lost. Did you check the variable of iteration_num when this happened, maybe it is already greater than the threshold of 32, usually the NDT score or iteration_num deviates from the threshold after the localization is lost.

Thanks for your reply. Yes our iteration_number is 50. Maybe it's the reason for our results and I will check that. But I think it reacts much, much longer than it should. I also honestly think that NDT score is not a reliable method to detect localization error.
What do you think about comparing the position from Gnss with the localization output? Maybe we can get a faster result.

@cyn-liu
Copy link
Contributor

cyn-liu commented Aug 25, 2022

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

To be honest, I dont think NDT match score is best choice to determine if the localization fails , I just compare the output of NDT match more reliably than the output of EKF to judge if the localization fails.
In the test video you shared, the NDT match score is still higher than the threshold for a while after the localization is lost. Did you check the variable of iteration_num when this happened, maybe it is already greater than the threshold of 32, usually the NDT score or iteration_num deviates from the threshold after the localization is lost.

Thanks for your reply. Yes our iteration_number is 50. Maybe it's the reason for our results and I will check that. But I think it reacts much, much longer than it should. I also honestly think that NDT score is not a reliable method to detect localization error. What do you think about comparing the position from Gnss with the localization output? Maybe we can get a faster result.

GNSS usually requires RTK correction to achieve centimeter-level accuracy, but due to occlusion (mountains, shrubs, tall buildings, tunnels, etc.) and poor 4G signal coverage, RTK is always in not-fixed status and the accuracy will drop to meter-level, so it is important to consider a good signal throughout the test road when using GNSS.

My test as below shows, using the integrated GNSS initialization position, the blue arrows in the figure indicate the position and direction of GNSS, I found that when NDT matching localization is successful, the position of GNSS may be inaccurate or even deviated from the distance greater than 5 m. Therefore, NDT matching localization is more reliable during vehicle operation at high speed (in scenarios with rich point cloud features).
One of the bag's test results video

@meliketanrikulu
Copy link
Contributor

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

To be honest, I dont think NDT match score is best choice to determine if the localization fails , I just compare the output of NDT match more reliably than the output of EKF to judge if the localization fails.
In the test video you shared, the NDT match score is still higher than the threshold for a while after the localization is lost. Did you check the variable of iteration_num when this happened, maybe it is already greater than the threshold of 32, usually the NDT score or iteration_num deviates from the threshold after the localization is lost.

Thanks for your reply. Yes our iteration_number is 50. Maybe it's the reason for our results and I will check that. But I think it reacts much, much longer than it should. I also honestly think that NDT score is not a reliable method to detect localization error. What do you think about comparing the position from Gnss with the localization output? Maybe we can get a faster result.

GNSS usually requires RTK correction to achieve centimeter-level accuracy, but due to occlusion (mountains, shrubs, tall buildings, tunnels, etc.) and poor 4G signal coverage, RTK is always in not-fixed status and the accuracy will drop to meter-level, so it is important to consider a good signal throughout the test road when using GNSS.

My test as below shows, using the integrated GNSS initialization position, the blue arrows in the figure indicate the position and direction of GNSS, I found that when NDT matching localization is successful, the position of GNSS may be inaccurate or even deviated from the distance greater than 5 m. Therefore, NDT matching localization is more reliable during vehicle operation at high speed (in scenarios with rich point cloud features). One of the bag's test results video

Hello @cyn-liu . You are not using RTK during this test, are you, or is your RTK connection dropping frequently? Your errors seem a little more than expected. Sometimes incorrect gnss-ins configurations can also cause this error. When we drive using RTK, our error values go up to a maximum of 40-50 cm (we work in an area with a lot of trees). During the general driving, our errors are 2 cm or less. Even when we tested it without using RTK, our error is around 1.5 m maximum. Therefore, we consider it a reliable source.

@cyn-liu
Copy link
Contributor

cyn-liu commented Aug 26, 2022

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

To be honest, I dont think NDT match score is best choice to determine if the localization fails , I just compare the output of NDT match more reliably than the output of EKF to judge if the localization fails.
In the test video you shared, the NDT match score is still higher than the threshold for a while after the localization is lost. Did you check the variable of iteration_num when this happened, maybe it is already greater than the threshold of 32, usually the NDT score or iteration_num deviates from the threshold after the localization is lost.

Thanks for your reply. Yes our iteration_number is 50. Maybe it's the reason for our results and I will check that. But I think it reacts much, much longer than it should. I also honestly think that NDT score is not a reliable method to detect localization error. What do you think about comparing the position from Gnss with the localization output? Maybe we can get a faster result.

GNSS usually requires RTK correction to achieve centimeter-level accuracy, but due to occlusion (mountains, shrubs, tall buildings, tunnels, etc.) and poor 4G signal coverage, RTK is always in not-fixed status and the accuracy will drop to meter-level, so it is important to consider a good signal throughout the test road when using GNSS.
My test as below shows, using the integrated GNSS initialization position, the blue arrows in the figure indicate the position and direction of GNSS, I found that when NDT matching localization is successful, the position of GNSS may be inaccurate or even deviated from the distance greater than 5 m. Therefore, NDT matching localization is more reliable during vehicle operation at high speed (in scenarios with rich point cloud features). One of the bag's test results video

Hello @cyn-liu . You are not using RTK during this test, are you, or is your RTK connection dropping frequently? Your errors seem a little more than expected. Sometimes incorrect gnss-ins configurations can also cause this error. When we drive using RTK, our error values go up to a maximum of 40-50 cm (we work in an area with a lot of trees). During the general driving, our errors are 2 cm or less. Even when we tested it without using RTK, our error is around 1.5 m maximum. Therefore, we consider it a reliable source.

We used RTK, the results of this bag test is only an extreme case, in general, the error is not large.

@mitsudome-r
Copy link
Member

@cyn-liu Are you still investigating this issue?

@cyn-liu
Copy link
Contributor

cyn-liu commented Sep 27, 2022

@cyn-liu Are you still investigating this issue?

I don't have a better way about which flag to use for faster and more accurate monitoring of whether the positioning is lost or not.
The current localization module can already initialize automatically when the vehicle is stopped, but if the vehicle loses its positioning while it is running, the automatic initialization is not possible because the current localization module does not notify other modules to stop the vehicle.

Now the remaining problem is to achieve automatic initialization of positioning during vehicle operation, and I think the following two things need to be done.

  1. Select a location loss flag.
  2. Notify other modules that positioning has been lost and need to make the vehicle stop.

For 1, my previous view was to use the NDT matching convergence flag (NDT matching score less than the threshold and NDT iterations greater than the threshold) as the flag for whether the locus is lost or not, because it detects locus loss faster than the pose_covariance of the EKF module, but after discussion, that flag is not the best choice either, so I don't have a better solution yet.
For 2, in order to make the vehicle stop smoothly, it needs to send the location loss information to the planning module or the control module, and this needs to be discussed and modified with other module developers, so I did not progress.

@xmfcx
Copy link
Contributor

xmfcx commented Oct 4, 2022

In the current state of the Autoware,

The localization nodes report performance,

Using https://github.com/autowarefoundation/autoware.universe/blob/main/system/system_error_monitor/config/diagnostic_aggregator/localization.param.yaml#L27 the system_error_monitor publishes HazardStatus

Then this message is fed to the emergency_handler to perform the emergency stop.

@wjxjmj
Copy link

wjxjmj commented Oct 11, 2022

When we test the ndt score, as you said, in general the score falls below 2.3 when ndt deteriorates. However, we noticed that it does not immediately fall below this threshold value every time. Here I shared an example video of this. Even if the NDT fails, you can see here that it does not fall below the NDT score for a long time. Therefore, we have doubts that this score can be used as a reliable source for localization degradation.

I encountered the same problem in my tests. Theoretically, the NDT score measures how well the point cloud matches the map, and that score should have a significant difference between successful and failed localization. But as the same as the previous disccusion, this was not reflected in the test.

It was observed that the NDT score remained at a certain level when localization failed, implying that most of the locations in the map could be partially matched with the point cloud information. This leads me to guess that the problem is due to the ground information.

Since both map building and vehicle positioning are done on the road, the shape of the vehicle vicinity is similar: they are both flat. If the ground information is removed during localization, it may be possible to increase the difference in NDT scores between successful and unsuccessful localization.

I having been working with @cyn-liu to verify the validity of the idea. Considering that the algorithm for removing the ground from the point cloud is already included in autoware, we give a detailed comparative study in this new issue.

@cyn-liu
Copy link
Contributor

cyn-liu commented Oct 11, 2022

In the current state of the Autoware,

The localization nodes report performance,

Using https://github.com/autowarefoundation/autoware.universe/blob/main/system/system_error_monitor/config/diagnostic_aggregator/localization.param.yaml#L27 the system_error_monitor publishes HazardStatus

Then this message is fed to the emergency_handler to perform the emergency stop.

Thanks for your answer, but I am not familiar with the Diagnostic Aggregators module and it will take me some time to understand and use it.

@mitsudome-r
Copy link
Member

Relevant issue: #2044

@stale
Copy link

stale bot commented Dec 31, 2022

This pull request has been automatically marked as stale because it has not had recent activity.

@stale stale bot added the status:stale Inactive or outdated issues. (auto-assigned) label Dec 31, 2022
@stale stale bot removed the status:stale Inactive or outdated issues. (auto-assigned) label Nov 3, 2023
Copy link

stale bot commented Jan 2, 2024

This pull request has been automatically marked as stale because it has not had recent activity.

@stale stale bot added the status:stale Inactive or outdated issues. (auto-assigned) label Jan 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:localization Vehicle's position determination in its environment. (auto-assigned) status:stale Inactive or outdated issues. (auto-assigned)
Projects
Status: In Progress
Development

No branches or pull requests

8 participants