usdot-fhwa-stol / carma-platform

CARMA Platform is built on robot operating system (ROS) and utilizes open source software (OSS) that enables Cooperative Driving Automation (CDA) features to allow Automated Driving Systems to interact and cooperate with infrastructure and other vehicles through communication. Doxygen Source Code Documentation :
https://usdot-fhwa-stol.github.io/documentation/carma-platform/
402 stars 122 forks source link

Better handle spline inflection point #1027

Closed MishkaMN closed 3 years ago

MishkaMN commented 3 years ago

Types of Issue

The library we are currently using has limitations where combining individual splines will result in gap along the map due to cubic spline. This ultimately results in inaccurate curvatures and speeds along certain sections in the map. We would like to use a library that can curve fit the entire map or better handle those inflection points using existing library.

Since current library's license is not compatible with ours, ideally we would want a better library that addresses both issues.

CARMA still runs well without this, but performance could be better.

Descriptive summary

See above.

Carma version where this issue was discovered

carma-platform 3.3.0 +

Expected behavior

There is no gaps in recreated maps.

Actual behavior

The library cannot curve fit curves like S curve (because it can't find a function that has 2 or more y values for a single x) Therefore there is a gaps in a recreated map which is affecting curvature/speed calculation

Steps to reproduce the actual behavior

Turn on DEBUG level on inlanecruising_plugin Run unit test of full_generation in that package (pick a point where there is a big curve). Plot original points, curvatures, speeds and observe

Related work

https://github.com/usdot-fhwa-stol/carma-platform/issues/936 (current library's license is also incompatible with ours)

MishkaMN commented 3 years ago

Resolved by above PR