CARLA: fix setting camera EOF (#24034)
* Fix Openpilot in Carla isn't accelerating The scalars of the timestamp are different in real-world and simulation, which will cause an infinite loop in selfdrive/modeld/modeld.cc. * Set eof based on the frame ID Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com> * remove global Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>pull/24009/merge
parent
8af20af66d
commit
db93275d87
|
@ -94,7 +94,7 @@ class Camerad:
|
|||
yuv_cl = cl_array.empty_like(rgb_cl)
|
||||
self.krnl(self.queue, (np.int32(self.Wdiv4), np.int32(self.Hdiv4)), None, rgb_cl.data, yuv_cl.data).wait()
|
||||
yuv = np.resize(yuv_cl.get(), np.int32(rgb.size / 2))
|
||||
eof = self.frame_id * 0.05
|
||||
eof = int(self.frame_id * 0.05 * 1e9)
|
||||
|
||||
# TODO: remove RGB send once the last RGB vipc subscriber is removed
|
||||
self.vipc_server.send(VisionStreamType.VISION_STREAM_RGB_ROAD, img.tobytes(), self.frame_id, eof, eof)
|
||||
|
|
Loading…
Reference in New Issue