I’m releasing a Python package I named dimensionful. It’s a simple library that attaches symbolic units to any sort of data.
The idea is that you can create Unit objects and associate them to any data, using a Quantity object. You can then perform any operation on the Quantity objects and the units are handled behind the scenes for you, with as few conversions as necessary (almost always zero).
Here’s an example to give you an idea of how it works.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | |
This outputs [ 0.84771033 1.01795928 0.34694982 0.26888805] cm**2*g/s**3. And a brief version of the same thing:
1 2 3 | |
This package is similar to magnitude and sympy.physics.units, but I think there are some key differences.