ApolloAuto / apollo

An open autonomous driving platform
Apache License 2.0
25.05k stars 9.68k forks source link

2 Apollo on the same Simualtion #15290

Open gmvc2000 opened 8 months ago

gmvc2000 commented 8 months ago

I'm running 2 autonomous vehicles on the same simulation to test a cooperative autonomous driving scenario. But I can't understand if those vehicles can see each other or not and stop if one vehicle is in front of the other

daohu527 commented 8 months ago

Self-driving cars obtain surrounding environment information through perception modules. That is to say, the perception module will detect vehicles and pedestrians and provide feedback to the self-driving car to avoid them.

Back to your question, you can parse the autonomous car's perception messages(topic: /apollo/perception/obstacles) to see if another car is detected.

go further

I think you may need to identify it automatically. You can use the simulator to obtain the position of the self-driving vehicle, and then compare it with the perceived results. For example, use IOU to determine whether it is the same car.

YuqiHuai commented 7 months ago

https://github.com/Software-Aurora-Lab/DoppelTest This project allows multiple Apollo instances to be simulated in SimControl. The underlying mechanism passes one Apollo's localization as perception to other instances, so all the instances can see each other.

daohu527 commented 7 months ago

https://github.com/Software-Aurora-Lab/DoppelTest This project allows multiple Apollo instances to be simulated in SimControl. The underlying mechanism passes one Apollo's localization as perception to other instances, so all the instances can see each other.

So are there no other NPCs? All vehicles are Apollo self-driving cars?

YuqiHuai commented 7 months ago

https://github.com/Software-Aurora-Lab/DoppelTest This project allows multiple Apollo instances to be simulated in SimControl. The underlying mechanism passes one Apollo's localization as perception to other instances, so all the instances can see each other.

So are there no other NPCs? All vehicles are Apollo self-driving cars?

Not exactly. In this implementation, all vehicles are Apollo self driving cars, pedestrians can be included and they walk around crosswalks (didn’t have a better way to simulate realistic pedestrian), no bicycle, with valid traffic lights (conflicting ones won’t be green at the same time).

daohu527 commented 7 months ago

What I want to express is that there will be conflicts between groundtruth and perception modules. It is best for them to choose 1 from 2.

YuqiHuai commented 7 months ago

I see. Yes, in the project linked above, perception module is replaced by ground truth perception messages generated by the project.