Closed chauvinSimon closed 3 years ago
@jackbart94 Could you follow up on this please?
Took me a while to answer, but here's the solution: you must set hybrid mode before spawning the hero vehicle. I've done so and it works flawlessly, so I'll close this.
Took me a while to answer, but here's the solution: you must set hybrid mode before spawning the hero vehicle. I've done so and it works flawlessly, so I'll close this.
That should be in the documentation, I just ran into this and was wondering why my vehicles were moving at 0 speed.
I open this issue following a discussion with @jackbart94 in the discord channel. I did not find any duplicate among the existing issues. https://github.com/carla-simulator/carla/issues/3145 could seem close, but the problem only prompts when replaying.
Use case here:
To reproduce, you can run this script
USE_HYBRID_PHYSICS = True
USE_HYBRID_PHYSICS = False
(line~63).In both cases, the ego ("hero" attribute) sees the other vehicle driving close (distance to ego ~ 40m). Its location changes, because it is moving. But:
with
USE_HYBRID_PHYSICS = False
:speed != 0
(expected)with
USE_HYBRID_PHYSICS = True
:speed == 0
<- PROBLEMNote1: I am using
0.9.10.0
andpython3.7
.Note2: for the ego, everything looks file. When applying
carla.VehicleControl
to it, itsget_velocity()
is not zero (as expected).