The purpose of this PR is to allow pedestrians with a medium aggressiveness level to increase their walking speed while crossing crosswalks to allow them to cross before the red light. This speed increase must be below a maximum speed increase, otherwise, they will not cross.
Summary of changes:
In the can_cross_before_red() function in ManeuverUtils, check if the pedestrian needs to increase their speed to sufficiently cross the crosswalk and update the current desired walking speed as necessary
Fix a logic error in the crosswalk selection process for medium aggressiveness pedestrians. The changes make the pedestrian prefer a crosswalk with a red light over a crosswalk with a yellow that they cannot cross since the red light will be green next.
To test, run python3.8 GSServer.py -s scenarios/pedestrian_scenarios/gs_intersection_xwalk_signal.osm and observe pedestrian_2. They must increase their walking speed in order to cross their first crosswalk.
The purpose of this PR is to allow pedestrians with a medium aggressiveness level to increase their walking speed while crossing crosswalks to allow them to cross before the red light. This speed increase must be below a maximum speed increase, otherwise, they will not cross.
Summary of changes:
can_cross_before_red()
function inManeuverUtils
, check if the pedestrian needs to increase their speed to sufficiently cross the crosswalk and update the current desired walking speed as necessaryTo test, run
python3.8 GSServer.py -s scenarios/pedestrian_scenarios/gs_intersection_xwalk_signal.osm
and observepedestrian_2
. They must increase their walking speed in order to cross their first crosswalk.