the vehicle didn't follow the given trajectory when executing lane change
Hello!I met a problem when the ego vehicle was executing lane change with the given trajectory, and the scenario is the three-lane highway. Trajectory planning was based on quintic polynomial curves.
1. My problem
the vehicle didn't quite follow the given trajectory when executing lane change. In the beginning, it could follow the speed quite well. However, as the planned speed increased, the actual speed of ego-vehicle keeped constant. After a while, its actual speed increased but did't follow the given trajectory.
here is the comparision of the position and speed between the planned trajectory and the actual trajectory:
self.realEgoY refers to the actual lateral movement of ego-vehicle
self.plan_y_ego refers to the planned lateral movement of ego-vehicle
self.realEgoLatVel refers to the actual lateral speed of ego-vehicle
self.latVelInforefers to the planned lateral speed of ego-vehicle (only shows 1.1s)
2. My codes
- the ego vehicle:
i have tried 0.1 and 10 for the
lcSublane, but there aren't apprent differences.<vType id="ego" accel="4" decel="4" emergencyDecel="9.0" length="5" color="1,0,0" vClass="passenger" maxSpeed="34" carFollowModel="IDM" laneChangeModel="SL2015" lcAccelLat="4.0" lcSublane="0.1" maxSpeedLat="3.0"/> - lane change
relLatMoverefers to the planned lateral movementplan_vx_egorefers to the planned longitudinal speed
traci.vehicle.changeSublane(self.egoID, relLatMove[self.stepNum]) traci.vehicle.setSpeed(self.egoID, self.plan_vx_ego[self.stepNum]) traci.simulationStep()
and i have set the lanechange mode with:
if vehID == self.egoID:
traci.vehicle.setLaneChangeMode(vehID, 0)
- sumocfg
<input>
<net-file value="test_planning_env.net.xml"/>
<route-files value="test_planning_env.rou.xml"/>
</input>
<time>
<begin value="0"/>
<end value="200"/>
<step-length value="0.1"/>
</time>
<gui_only>
<start value="t"/>
<quit-on-end value="t"/>
</gui_only>
<processing>
<lateral-resolution value = "0.1"/>
</processing>
3.
I’m sure there aren't any other vehicle in the road. The above are some necessary settings. If there are any other settings i should share, please tell me. I am really appreciated if anyone can solve this error
SUMO-version: 1.18.0
operating system: window 10
The lateral acceleration is limited by the lane change parameter lcAccelLat. If changing this does not help, could you maybe plot the speed over time and the lateral position over time (both requested and sumo)? This would be much easier to interpret as a bunch of numbers.
thank you for your advice. The timestep is 0.1s. The whole lane change process is about 3s and the lanewidth is 3.5m. So i think lcAccelLat='4' won't be over large.
Then I try 'lcAccelLat=8' and 'lcAccelLat=100', as the results show. Surprisely, when it is 'lcAccelLat=100', the vehicle can follow the planned trajectory perfectly. How did that happen?
well, I tried lcAccelLat=20. The ego-vehicle could also follow perfectly while lcAccelLat=15 couldn't.