compas-dev / compas

Core packages of the COMPAS framework.
https://compas.dev/compas/
MIT License
309 stars 105 forks source link

`scale_factor` attribute to Configuration #811

Open matteo-pacher opened 3 years ago

matteo-pacher commented 3 years ago

When serializing a Configuration, I think it is meaningful to keep track of its scale_factor. For example, if I plan a path using a scaled robot (robot.scale(1000)), the configuration's prismatic or planar joint values will also be scaled, and serialized as such. When deserializing that information, the scale_factor information is lost.

EPIC: @gonzalocasas mentioned the idea of a compas_units library that would take care of such issue.

yck011522 commented 3 years ago

I testify it would be beneficial to my project workflow if the units are explicitly saved. Expecially because I serialize my data multiple times passing them between comaps_fab planning, visualization with Rhino and execution with compas_rrc.