motional / nuplan-devkit

The devkit of the nuPlan dataset.
https://www.nuplan.org
Other
700 stars 136 forks source link

Why is the ego_velocity calculation not divided by time_interval? #213

Closed JingyuQian closed 1 year ago

JingyuQian commented 1 year ago

Hello,

In this code of kinematic agent augmentation:

https://github.com/motional/nuplan-devkit/blob/b5d81a085adda3e1da3bc36fa3cd1eae686c852f/nuplan/planning/training/data_augmentation/kinematic_agent_augmentation.py#L70-L73

The calculation of ego_velocity first gets the diff of xy-positions, then calculate its norm. Shouldn't it be divided by dt? This affects the calculated trajectory that is used as training target.

JingyuQian commented 1 year ago

Also found it in other places where ConstrainedNonlinearSmoother class is used. Is there an inexplicit reason I'm missing here?

patk-motional commented 1 year ago

Hi @JingyuQian,

This is indeed a bug. You are correct. We will look to fix this as soon as possible.

This should only impact the initial state of the optimization. The resulting solution should accelerate to reach the reference trajectory still.

JingyuQian commented 1 year ago

Hi @patk-motional ,

As of the v1.1 release, I'm not seeing that this bug is fixed. Would you please confirm if this is still a bug? Thank you.

patk-motional commented 1 year ago

Yes, it is still a bug. We did not get a chance to include the fix in this release

JingyuQian commented 1 year ago

Thanks for the clarification!