Skip to content

Releases: tier4/scenario_simulator_v2

6.1.1

29 Nov 02:24
Compare
Choose a tag to compare

Description

Abstract

  • Add + operator overloading to BT::PortList

Background

There were numerous warnings from sonar cloud around ports in behavior_tree_cpp_v3

Details

  • Add + operator overloading to BT::PortList
  • Simplify code of providedPorts() function.

References

https://sonarcloud.io/project/issues?open=AZJwAYwGlcZ2d3dSAT6K&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYvzlcZ2d3dSAT6E&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZINWTFejvEq9OQMnL98&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZINWTFejvEq9OQMnL99&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYwGlcZ2d3dSAT6J&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYv9lcZ2d3dSAT6G&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYuMlcZ2d3dSAT5t&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYt3lcZ2d3dSAT5k&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYudlcZ2d3dSAT5z&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYtulcZ2d3dSAT5h&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYuFlcZ2d3dSAT5q&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYt-lcZ2d3dSAT5n&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYuTlcZ2d3dSAT5w&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYuxlcZ2d3dSAT56&id=tier4_scenario_simulator_v2
https://sonarcloud.io/project/issues?open=AZJwAYunlcZ2d3dSAT53&id=tier4_scenario_simulator_v2

Destructive Changes

N/A

Known Limitations

N/A

Related Issues

6.1.0

29 Nov 01:40
Compare
Choose a tag to compare

Abstract

To set the road shoulder to the Entity's operating area, set VEHICLE_WITH_ROAD_SHOULDER routng graph added in #1456 as the default.

Background

Previously, road shoulder support in scenario_simulator_v2 consisted of various special measures and had some restrictions, such as not being able to change lanes onto the road shoulder.

Details

The added scenario allows you to see a vehicle entity change lanes onto the road shoulder.
Before the pull-request, this scenario would crash when the vehicle entity tried to change lanes.

simplescreenrecorder-2024-11-28_14.27.05.mp4

References

Regression Test: OK

Destructive Changes

The default routing graph has changed, so the behavior of entities in existing scenarios may change.

Normally, road shoulder lanelet are not set as following lanelet for normal road lanelets, so there is no need to worry even after the change unless the scenario creator explicitly causes entities to enter them.

Known Limitations

None

Related Issues

6.0.1

27 Nov 07:46
Compare
Choose a tag to compare

Description

Abstract

Add glog to simple_sensor_simulator.

Background

Sometimes, it's tough to find causes of issue since this node dies without hints. So, I integrate glog to this node so that it outputs stack trace when it dies.

Details

[simple_sensor_simulator_node-2] terminate called after throwing an instance of 'simple_sensor_simulator::SimulationRuntimeError'
[simple_sensor_simulator_node-2]   what():  failed to find ego vehicle
[simple_sensor_simulator_node-2] *** Aborted at 1731026500 (unix time) try "date -d @1731026500" if you are using GNU date ***
[simple_sensor_simulator_node-2] PC: @                0x0 (unknown)
[simple_sensor_simulator_node-2] *** SIGABRT (@0x3e8000397cf) received by PID 235471 (TID 0x7fd9dcff9640) from PID 235471; stack trace: ***
[simple_sensor_simulator_node-2]     @     0x7fd9ebe42520 (unknown)
[simple_sensor_simulator_node-2]     @     0x7fd9ebe969fc pthread_kill
[simple_sensor_simulator_node-2]     @     0x7fd9ebe42476 raise
[simple_sensor_simulator_node-2]     @     0x7fd9ebe287f3 abort
[simple_sensor_simulator_node-2]     @     0x7fd9ec2a2b9e (unknown)
[simple_sensor_simulator_node-2]     @     0x7fd9ec2ae20c (unknown)
[simple_sensor_simulator_node-2]     @     0x7fd9ec2ae277 std::terminate()
[simple_sensor_simulator_node-2]     @     0x7fd9ec2ae4d8 __cxa_throw
[simple_sensor_simulator_node-2]     @     0x7fd9ec55765c _ZN23simple_sensor_simulator11LidarSensorIN11sensor_msgs3msg12PointCloud2_ISaIvEEEE7raycastERKSt6vectorIN22traffic_simulator_msgs12EntityStatusESaIS9_EERKN6rclcpp4TimeE.cold
[simple_sensor_simulator_node-2]     @     0x7fd9ec5c37a0 simple_sensor_simulator::LidarSensor<>::update()
[simple_sensor_simulator_node-2]     @     0x7fd9ec59dbfd simple_sensor_simulator::SensorSimulation::updateSensorFrame()
[simple_sensor_simulator_node-2]     @     0x7fd9ec5a7695 simple_sensor_simulator::ScenarioSimulator::updateFrame()
[simple_sensor_simulator_node-2]     @     0x7fd9ec5a7a05 _ZNSt17_Function_handlerIFN21simulation_api_schema19UpdateFrameResponseERKNS0_18UpdateFrameRequestEEZN23simple_sensor_simulator17ScenarioSimulatorC4ERKN6rclcpp11NodeOptionsEEUlDpOT_E0_E9_M_invokeERKSt9_Any_dataS4_
[simple_sensor_simulator_node-2]     @     0x7fd9ebd8ce8b zeromq::MultiServer::poll()
[simple_sensor_simulator_node-2]     @     0x7fd9ebd8dc6f zeromq::MultiServer::start_poll()
[simple_sensor_simulator_node-2]     @     0x7fd9ec2dc253 (unknown)
[simple_sensor_simulator_node-2]     @     0x7fd9ebe94ac3 (unknown)
[simple_sensor_simulator_node-2]     @     0x7fd9ebf26850 (unknown)
[ERROR] [simple_sensor_simulator_node-2]: process has died [pid 235471, exit code -6, cmd '/home/satoshi/pilot-auto/install/simple_sensor_simulator/lib/simple_sensor_simulator/simple_sensor_simulator_node --ros-args -r __ns:=/simulation --params-file /tmp/launch_params_qflnald1 --params-file /tmp/launch_params_7rrjdjh9 --params-file /tmp/launch_params_zs1s1v38 --params-file /tmp/launch_params_9iwwr5j1 --params-file /tmp/launch_params_y7mdfpkx --params-file /tmp/launch_params_vg92wk24 --params-file /tmp/launch_params_tnnj17od --params-file /tmp/launch_params_2y5m5x_5 --params-file /tmp/launch_params_zjg9m3sq --params-file /tmp/launch_params_phqvrhq4 --params-file /tmp/launch_params_guqddos1 --params-file /tmp/launch_params_lvwzddgr --params-file /tmp/launch_params_qgh5hq3q --params-file /tmp/launch_params_zx6g6ox5 --params-file /tmp/launch_params_ehc9n5of --params-file /tmp/launch_params_apfu5bl0 --params-file /tmp/launch_params_eho8fdep --params-file /tmp/launch_params_hr57yv4_ --params-file /home/satoshi/pilot-auto/install/lexus_description/share/lexus_description/config/vehicle_info.param.yaml --params-file /home/satoshi/pilot-auto/install/lexus_description/share/lexus_description/config/simulator_model.param.yaml --params-file /home/satoshi/pilot-auto/install/cpp_scenario/share/cpp_scenario/scenarios/random002.yaml --params-file /home/satoshi/pilot-auto/install/cpp_scenario/share/cpp_scenario/record_trigger/diagnostics.yaml --params-file /tmp/launch_params_aqhf_1qe'].

References

N/A

Destructive Changes

N/A

Known Limitations

N/A

Related Issues

6.0.0

27 Nov 06:52
Compare
Choose a tag to compare

Abstract

This pull-request adds routing graph argument to the listed functions

Detail

HDMapUtils class

functions with routing graph type added as an argument

  • canChangeLane
  • getAlongLaneletPose
  • getConflictingLaneIds
  • getFollowingLanelets
  • getLaneChangeableLaneletId
  • getPreviousLanelets
  • getSpeedLimit
  • matchToLane
  • toLaneletPose
  • toLaneletPoses

functions with routing configuration added as an argument

The original argument allow_lane_change was combined with the added new routing graph type argument to create the
routing configuration argument.

struct RoutingConfiguration
{
  bool allow_lane_change = false;
  traffic_simulator::RoutingGraphType routing_graph_type =
    traffic_simulator::RoutingGraphType::VEHICLE;
};
  • countLaneChanges
  • getLateralDistance
  • getLongitudinalDistance
  • getRoute

traffic_simulator::distance namespace

The original argument allow_lane_change was combined with the added new routing graph type argument to create the
routing configuration argument.

  • countLaneChanges
  • lateralDistance
  • longitudinalDistance
  • boundingBoxLaneLateralDistance
  • boundingBoxLaneLongitudinalDistance

Note

changes to these functions are breaking interface

traffic_simulator::pose namespace

The original argument allow_lane_change was combined with the added new routing graph type argument to create the
routing configuration argument.

  • relativeLaneletPose
  • boundingBoxRelativeLaneletPose

Note

changes to these functions are breaking interface

traffic_simulator::lanelet_pose namespace

The original argument allow_lane_change was combined with the added new routing graph type argument to create the
routing configuration argument.

  • CanonicalizedLaneletPose::getAlternativeLaneletPoseBaseOnShortestRouteFrom

References

Regression Test: OK

Destructive Changes

The functions listed below are not backward compatible

  • traffic_simulator::distance::countLaneChanges
  • traffic_simulator::distance::lateralDistance
  • traffic_simulator::distance::longitudinalDistance
  • traffic_simulator::distance::boundingBoxLaneLateralDistance
  • traffic_simulator::distance::boundingBoxLaneLongitudinalDistance
  • traffic_simulator::pose::relativeLaneletPose
  • traffic_simulator::pose::boundingBoxRelativeLaneletPose

migration guide

The penultimate argument, allow_lane_change, has been changed to routing_configuration.
This is a destructive change because I can't use default arguments except for the last one.

allow_lane_change: false

before

const auto relative = traffic_simulator::pose::relativeLaneletPose(
    from, to, false, hdmap_utils);

after

const auto relative = traffic_simulator::pose::relativeLaneletPose(
    from, to, traffic_simulator::RoutingConfiguration(), hdmap_utils);

allow_lane_change: true

before

const auto relative = traffic_simulator::pose::relativeLaneletPose(
    from, to, true, hdmap_utils);

after

traffic_simulator::RoutingConfiguration lane_changeable_routing_configuration;
lane_changeable_routing_configuration.allow_lane_change = true;
const auto relative = traffic_simulator::pose::relativeLaneletPose(
    from, to, lane_changeable_routing_configuration, hdmap_utils);

Known Limitations

None

Related Issues

5.5.0

27 Nov 01:34
Compare
Choose a tag to compare

Description

Abstract

  • add new traffic rule germanRoadShoulderPassableVehicleRules
  • add new routing graph for VEHICLE_WITH_ROAD_SHOULDER
  • stop giving special treatment to shoulder_lanelet
    • delete HDMapUtils::getPreviousShoulderLaneletIds
    • delete HDMapUtils::getNextShoulderLaneletIds
  • add routing graph type argument
    • HDMapUtils::getPreviousLaneletIds
    • HDMapUtils::getNextLaneletIds
    • HDMapUtils::getRoute

Background

To get NPCs to work properly around the road shoulder, you need to create a routing graph that includes the road shoulder.

Details

routingWithRoadShoulder test

testing routing from 34693 to 34615 without lane changes.
(This case where you must go through road shoulder)

  • with default routing graph(VEHICLE): no route
  • with new routing graph(VEHICLE_WITH_ROAD_SHOULDER): has route

image

References

REgression Test: OK

Destructive Changes

Although there have been some additions to function arguments, all of this has been carefully implemented to ensure backward compatibility.

Known Limitations

Related Issues

5.4.0

26 Nov 01:27
Compare
Choose a tag to compare

Description

Abstract

  • add new traffic rule germanRoadShoulderPassableVehicleRules
  • add new routing graph for VEHICLE_WITH_ROAD_SHOULDER
  • stop giving special treatment to shoulder_lanelet
    • delete HDMapUtils::getPreviousShoulderLaneletIds
    • delete HDMapUtils::getNextShoulderLaneletIds
  • add routing graph type argument
    • HDMapUtils::getPreviousLaneletIds
    • HDMapUtils::getNextLaneletIds
    • HDMapUtils::getRoute

Background

To get NPCs to work properly around the road shoulder, you need to create a routing graph that includes the road shoulder.

Details

routingWithRoadShoulder test

testing routing from 34693 to 34615 without lane changes.
(This case where you must go through road shoulder)

  • with default routing graph(VEHICLE): no route
  • with new routing graph(VEHICLE_WITH_ROAD_SHOULDER): has route

image

References

REgression Test: OK

Destructive Changes

Although there have been some additions to function arguments, all of this has been carefully implemented to ensure backward compatibility.

Known Limitations

Related Issues

5.3.4

21 Nov 05:45
Compare
Choose a tag to compare

Description

Abstract

fix pitch and slope acceleration calculation for ego vehicle.
and refactor to test properly.

Background

When calculating the position on the lanelet used to calculate the slope, a point in a different coordinate system was used, so the slope calculation did not work properly.

Details

Added tests

do tests at 2 red points, which have different slope in same lanelet in the figure below.

image

8 test variation

  • 2 different slope
  • 2 consider_acceleration_by_road_slope flag state (true/false)
  • 2 ego direction (up / down against the slope)

References

Regression Test: OK

Destructive Changes

None

Known Limitations

None

Related Issues

5.3.3

21 Nov 05:22
Compare
Choose a tag to compare

Description

Abstract

This PR includes modifications based on the results of static analysis performed by SonarCloud. Please refer to the SonarCloud reference for details on the issue fixes.

Background

N/A

Details

N/A

References

Pass large object by reference to const.

Directly pass the arguments for object creation to this function.

Remove this redundant cast.

Replace "." with "::" for access

Destructive Changes

N/A

Known Limitations

N/A

Related Issues

5.3.2

18 Nov 09:57
Compare
Choose a tag to compare

Description

Abstract

Fixed an issue where AssignRouteAction could not be applied multiple times to a Vehicle entity controlled by Autoware.

Background

#1369 introduced a feature that allows AcquirePositionAction to be applied multiple times to Vehicle entities controlled by Autoware. At that time, an equivalent feature should have been introduced for AssignRouteAction as well as AcquirePositionAction, but this was overlooked. This pull request fixes that.

Details

Note that FollowTrajectoryAction belongs to RoutingAction, just like AcquirePositionAction and AssignRouteAction, but there is no need to introduce an equivalent feature. This is because FollowTrajectoryAction for Vehicle entities controlled by Autoware is a special operation that means overriding the control of the vehicle by a controller that is not Autoware (mainly a human).

References

None.

Destructive Changes

None.

Known Limitations

None.

Related Issues

5.3.1

18 Nov 09:35
Compare
Choose a tag to compare

Description

Abstract

  • add RoutingGraphType enum class to specity types of routing graph
  • add RoutingGraphs class to manage routing graph and paired traffic rule class
  • replace EntityType with RoutingGraphType to specify types of routing graph

Background

The current HDMapUtils class uses the vehicle routing graph by default (even for pedestrians).
As the first step to bettter management of routing graph, this pull-request adds RoutingGraphs class.

In addition, the handling of shoulder lanes varies depending on the function, and there is no consistency.
In the future, I plan to develop a unified handling of shoulder lanes by adding a routing graph that includes road shoulders to the better routing graph management added in this pull request.

Details

  • HDMapUtils::getNextLaneletIds
    • add type argument to switch routing graph(default: VEHICLE for backward compatibility)
    • two overload has not type argument yet, because it treats road shoulder lanelet.
  • HDMapUtils::getPriviousLaneletIds
    • add type argument to switch routing graph(default: VEHICLE for backward compatibility)
      • one overload has not type argument yet, because it treats road shoulder lanelet and has a bug.
  • HDMapUtils::getRightLaneletIds
    • replace EntityType with RoutingGraphType in argument
  • HDMapUtils::getLeftLaneletIds
    • replace EntityType with RoutingGraphType in argument
  • HDMapUtils::getRoute
    • move inplementation into HDMapUtils::RoutingGraphs::getRoute
    • add type argument to switch routing graph(default: VEHICLE for backward compatibility)

References

Regression Test(OK)

Destructive Changes

Although there have been some additions to function arguments, all of this has been carefully implemented to ensure backward compatibility.

Known Limitations

Related Issues