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

Platoon at signalized intersection #9

Open
TrinhTuanHung2021 opened this issue Jan 12, 2022 · 18 comments
Open

Platoon at signalized intersection #9

TrinhTuanHung2021 opened this issue Jan 12, 2022 · 18 comments

Comments

@TrinhTuanHung2021
Copy link

TrinhTuanHung2021 commented Jan 12, 2022

Hello

I created some platoons at the signalized intersection.

And I saw that the platoons don't stop at red lights.
only the leader vehicles stop.
Could you show me how to fix this? Thanks

image

image

@thardes2
Copy link

this is not possible without further ado. The car following model does not handle any traffic lights or regulations such as "right before left" or similar.
You can work around this by instantiating the leader as a "DRIVER" and not as an "ACC". In case of a DRIVER, the Krauss model is used and traffic lights are considered.
However, you will probably get further issues as the desired acceleration (as required by CACC) cannot be calculated and transmitted to the followers.

@TrinhTuanHung2021
Copy link
Author

TrinhTuanHung2021 commented Jan 22, 2022

this is not possible without further ado. The car following model does not handle any traffic lights or regulations such as "right before left" or similar. You can work around this by instantiating the leader as a "DRIVER" and not as an "ACC". In case of a DRIVER, the Krauss model is used and traffic lights are considered. However, you will probably get further issues as the desired acceleration (as required by CACC) cannot be calculated and transmitted to the followers.

Thank you for replying to me. I changed the setSpeedMode to 31 instead of 0.
traci.vehicle.setSpeedMode(vid, 31)

But only the leader car stopped abruptly, and the following cars kept going through the front car. Do you know a way to make the following cars also stop when the leader car stops? Thanks

image
giphy

And you can see, the simulator is lagged when the leader of platoon hits the red line

@Q-max007
Copy link

Q-max007 commented May 8, 2022

But only the leader car stopped abruptly, and the following cars kept going through the front car. Do you know a way to make the following cars also stop when the leader car stops? Thanks

Hey, Have you solved this problem?

@michele-segata
Copy link
Owner

But only the leader car stopped abruptly, and the following cars kept going through the front car. Do you know a way to make the following cars also stop when the leader car stops? Thanks

I guess the issue here is that, by changing the speed mode, SUMO forces the vehicle to stop, but the vehicle itself still computes an ACC desired acceleration which is shared with the others. As SUMO slows down the vehicles, the ACC algorithm will compute a positive acceleration, because it wants to speed it up to reach the desired speed. So the other vehicles believe the leader will accelerate, while it is actually slowing down.
But to confirm this, you should do some debugging by printing the values exchanged between the vehicles.

@TrinhTuanHung2021
Copy link
Author

thank you for replying to me. But how to print the value exchanged between vehicles?

I only know the position, speed and acceleration of vehicles over times

@thardes2
Copy link

You first have to use the right controller. This would be either "CACC" or "Ploeg". ACC is not working since it is not suitable for platooning.

In case you use one of the two, the vehicle still relies on the 'controller acceleration', which cannot be provided by a human driven vehicle. This needs to be changed in the code, e.g. you use the real acceleration for the controller acceleration as well.
This will very likely not keep the platoon string stable. Thus you somehow need to change the protocol for the beacon exchange or the properties of the controller. This is up to your scenario and your overall conditions.

@TrinhTuanHung2021
Copy link
Author

TrinhTuanHung2021 commented May 21, 2022

You first have to use the right controller. This would be either "CACC" or "Ploeg". ACC is not working since it is not suitable for platooning.

In case you use one of the two, the vehicle still relies on the 'controller acceleration', which cannot be provided by a human driven vehicle. This needs to be changed in the code, e.g. you use the real acceleration for the controller acceleration as well. This will very likely not keep the platoon string stable. Thus you somehow need to change the protocol for the beacon exchange or the properties of the controller. This is up to your scenario and your overall conditions.

Thank you for replying to me. I modified Segata's model by adding traffic signals to the model. I would like to check the behavior of platoons when approaching the red signal. I understand that I have to change the protocol but I do not know how to change it. Could you provide examples about Plexe API with traffic signals so I can follow it? Thanks

My model here

@TrinhTuanHung2021
Copy link
Author

@michele-segata
Copy link
Owner

Sorry for my late reply. What do you mean by

I would like to check the behavior of platoons when approaching the red signal. I understand that I have to change the protocol but I do not know how to change it.

It is not really clear to me what you want to do.

@prasuka4
Copy link

prasuka4 commented Jun 28, 2022

Hi All,
Even I'm facing the same issue, while vehicle reach the Junction/intersection... Vehicles are crossing the signal irrespective of phase of signal colour. I have tried to change the driver controller as well from IDM, ACC and CACC but none of them were working fine.
Could you please solve this or provide any solution that could help in solving this issue.
image

@michele-segata
Copy link
Owner

I guess the only way is to use the plexe::DRIVER controller in MSCFModel_CC for the leader, but then you still need to modify the car following model to be able to provide the followers with the required acceleration they need for control.

@way-thu
Copy link

way-thu commented Aug 22, 2023

@TrinhTuanHung2021 @michele-segata @prasuka4 @Q-max007 hi all, I'm facing the same issue, vehicles do not stop at red lights at signalized intersections, have you solved this problem?

@TrinhTuanHung2021
Copy link
Author

@TrinhTuanHung2021 @michele-segata @prasuka4 @Q-max007 hi all, I'm facing the same issue, vehicles do not stop at red lights at signalized intersections, have you solved this problem?

It related to the deceleration of vehicles in the platoon. If the leader stops suddenly, the following cars can not stop in time because the gap is too small. So I set the deceleration to be high to stop the following cars immediately.

@thardes2
Copy link

The initial approach suggested by @michele-segata is to utilize the plexe:: DRIVER model. This will result in a scenario utilizing the actual acceleration rather than the desired acceleration. To resolve this issue, begin by setting the *.node[*].scenario.useControllerAcceleration value in the omnetpp.ini file to false.

This gives you a scenario where the actual acceleration is used instead of the desired one. As a consequence, this leads to a situation where the vehicles behind the leader in the platoon cannot respond "immediately" to the leader's actions, which could result in collisions. One potential solution is to increase the distance between the vehicles in the platoon.

Yet, by using the actual acceleration instead of the desired one, you cannot achieve the same 'performance' as in the ACC controlled scenario, but it will allow for successful stopping at red traffic lights.

@way-thu
Copy link

way-thu commented Aug 24, 2023

The initial approach suggested by @michele-segata is to utilize the plexe:: DRIVER model. This will result in a scenario utilizing the actual acceleration rather than the desired acceleration. To resolve this issue, begin by setting the *.node[*].scenario.useControllerAcceleration value in the omnetpp.ini file to false.

This gives you a scenario where the actual acceleration is used instead of the desired one. As a consequence, this leads to a situation where the vehicles behind the leader in the platoon cannot respond "immediately" to the leader's actions, which could result in collisions. One potential solution is to increase the distance between the vehicles in the platoon.

Yet, by using the actual acceleration instead of the desired one, you cannot achieve the same 'performance' as in the ACC controlled scenario, but it will allow for successful stopping at red traffic lights.

much thanks for your reply, i will try

@way-thu
Copy link

way-thu commented Aug 24, 2023

@TrinhTuanHung2021 @michele-segata @prasuka4 @Q-max007 hi all, I'm facing the same issue, vehicles do not stop at red lights at signalized intersections, have you solved this problem?

It related to the deceleration of vehicles in the platoon. If the leader stops suddenly, the following cars can not stop in time because the gap is too small. So I set the deceleration to be high to stop the following cars immediately.

much thanks, Can we exchange a wechat or something for better communication? i saw u on github so many times

@thardes2
Copy link

Sorry - I mixed up the projects... The approach would work for the OMNeT implementation.

@michele-segata
Copy link
Owner

As I wrote in my answer above, you should use the Plexe::DRIVER controller for the leader and change the SUMO code so that you can fetch the acceleration of the human driver model via the API. Then you have to share such value with the followers in the platoon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants