duckietown / gym-duckietown

Self-driving car simulator for the Duckietown universe
http://duckietown.org
Other
52 stars 19 forks source link

Coordinate system is not x,y - plane, z -height #83

Closed jzilly closed 5 years ago

jzilly commented 6 years ago

Hi everyone,

Can we change the coordinate system of the simulator to correspond to a more user friendly coordinate system like x,y create the plane and z is the height (right-hand-rule)? That will greatly accelerate any robotic developments. Example picture: https://www.thelocal.ch/20180815/this-is-how-switzerlands-new-200-franc-note-looks

Thank you!

maximecb commented 6 years ago

If you mean what's internally used in the code, the coordinate system is the OpenGL default. Changing it is possible, but might be pretty tedious. I think it shouldn't be too hard to change what's externally-facing, however. That being said, there are already people using the simulator, and the official start of the competition is getting very close, so I'm not sure I'd recommend going in this direction.

jzilly commented 6 years ago

Hi Maxime, Your concerns make sense and I do share them. From where I am sitting it still appears to make sense to at least change the externally-facing coordinates. Currently, I am using coordinate transforms from (z,x,y) to (x,y,z) plus angle correction to convert what the simulator environment is supplying. Ideally this could be done internally in the simulator such that development of any kind of algorithm using this information is greatly sped up. In the long run the current coordinate system will create more work than changing it and adapting to the more common (x,y,z) coordinate system.

AndreaCensi commented 6 years ago

@maximecb all the robotics modules use the standard coordinate system convention (e.g. the localization system being developed). I think the external data convention change can be implemented by just a matrix multiplication.

jzilly commented 5 years ago

Has this issue been addressed?