traffic icon indicating copy to clipboard operation
traffic copied to clipboard

Physical units with pint

Open xoolive opened this issue 6 years ago • 1 comments

It would probably make sense to annotate each column of the pandas dataframe with physical units. A basic improvement could be a basic annotation for features; a more advanced improvement would check consistency and convert units if need be.

Reference:

  • Pint https://pint.readthedocs.io/en/latest/

xoolive avatar Sep 07 '19 12:09 xoolive

The library has now a pandas extension: https://github.com/hgrecco/pint-pandas. We should have a look together with @junzis in https://github.com/junzis/openap to avoid potential troubles.

This could lead some incompatibility issues with past files, so maybe data without unit should be set to standard unit (e.g. feet for altitudes, etc.)

xoolive avatar Dec 22 '21 14:12 xoolive