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

Fix/interpreter/user defined value condition #1338

Merged
merged 9 commits into from
Aug 23, 2024

Conversation

yamacir-kit
Copy link
Collaborator

@yamacir-kit yamacir-kit commented Aug 5, 2024

Description

Abstract

The following two issues have been addressed:

  • The simulator became extremely slow when a large number of UserDefinedValueConditions were written in a scenario.
  • A related issue, when the simulator was running too slow, some topics published by Autoware were not subscribed to by the simulator and were dropped.

Background

The above issues were observed in a scenario where a large number of UserDefinedValueCondition were used.

Details

The causes of each problem were as follows:

The first problem was caused by the implementation of UserDefinedValueCondition, which had one thread and two ROS nodes per instance. Therefore, we changed the implementation to use one common thread and node for this condition, regardless of the number of UserDefinedValueCondition instances.

The second problem was caused by the simulator's ROS 2 topic subscriber dropping messages that were published before the standby when the standby of the simulator's ROS 2 topic subscriber was later than Autoware's publishers could publish the topic. In this case, a large number of UserDefinedValueCondition overloaded the simulator and delayed the standby of the Subscriber. In addition, the dropped message was one of the most important topics for the simulator to set up Autoware, and it was a message that would only be published once. Fortunately, the topic was provided with a publisher set to transient local in quality of service, so we took care of it by upgrading the subscriber's quality of service to transient local.

References

Destructive Changes

None.

Known Limitations

None.

Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
@yamacir-kit yamacir-kit added bug Something isn't working bump patch If this pull request merged, bump patch version of the scenario_simulator_v2 labels Aug 5, 2024
@yamacir-kit yamacir-kit self-assigned this Aug 5, 2024
Copy link

github-actions bot commented Aug 5, 2024

Checklist for reviewers ☑️

All references to "You" in the following text refer to the code reviewer.

  • Is this pull request written in a way that is easy to read from a third-party perspective?
  • Is there sufficient information (background, purpose, specification, algorithm description, list of disruptive changes, and migration guide) in the description of this pull request?
  • If this pull request contains a destructive change, does this pull request contain the migration guide?
  • Labels of this pull request are valid?
  • All unit tests/integration tests are included in this pull request? If you think adding test cases is unnecessary, please describe why and cross out this line.
  • The documentation for this pull request is enough? If you think adding documents for this pull request is unnecessary, please describe why and cross out this line.

…ocal

Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
Signed-off-by: yamacir-kit <httperror@404-notfound.jp>
@yamacir-kit yamacir-kit marked this pull request as ready for review August 22, 2024 08:18
@yamacir-kit yamacir-kit merged commit 87224cf into master Aug 23, 2024
13 checks passed
@github-actions github-actions bot deleted the fix/interpreter/user-defined-value-condition branch August 23, 2024 03:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working bump patch If this pull request merged, bump patch version of the scenario_simulator_v2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants