frc-862 / valkyrie

Full steam ahead!!!
http://www.lightningrobotics.com
MIT License
1 stars 0 forks source link

[WIP] Add binary serializer for cheezy path #48

Open mstojcevich opened 7 years ago

mstojcevich commented 7 years ago

This adds a new serializer for cheezy paths. It does not actually switch the current code to use the new serializer.

This is not fully tested for accuracy yet and I would not recommend switching the production code to use this serializer. It should be more accurate (albeit different) than the text serializer, as it serializes all bits of the double as opposed to truncating the decimal representation to three digits after the decimal point.

Benchmarking on my laptop vs the current plaintext serializer, the binary serializer finishes in 3ms while the text serializer finishes in 130ms.

The 130ms is a significant chunk of the total time to generate a path and serialize it. Not sure how significant it will be for the rio, though.

The deserializer is faster too.