by toxik · 2y ago · 0 comments
A similar thing I have been thinking about doing in robotics contexts is to annotate vectors and transformation matrices with their reference frames. So you can only matrix-vector multiply between compatible types: `object_in_world = camera_to_world @ object_in_camera`. It can be done somewhat in C++.
At least you can check the input of functions at runtime [1].
[0]: https://github.com/hgrecco/pint
[1]: https://pint.readthedocs.io/en/stable/advanced/wrapping.html
https://docs.sympy.org/latest/modules/physics/units/index.ht...