Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use pint for units #91

Open
domna opened this issue Nov 2, 2022 · 2 comments
Open

Use pint for units #91

domna opened this issue Nov 2, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@domna
Copy link
Member

domna commented Nov 2, 2022

For easier unit conversion and loading we want to use pint.
There are a few considerations

  • As it integrates nicely with numpy arrays, we should make sure that it also works good with pandas and xarray (to support the further data representation path).
  • It should be usable without overhead when default units are used, so maybe conversion can happen automatically for wavelengths in nm.
  • It should make using data in other units as easy as possible (also conversion from wavenumber and energy), so it should be not more as using an ureg("eV") to specifiy the unit of the data used.
@domna domna added the enhancement New feature or request label Nov 2, 2022
@MarJMue
Copy link
Collaborator

MarJMue commented Nov 2, 2022

I have two small things i have read, which i want to keep in mind:

@domna
Copy link
Member Author

domna commented Feb 17, 2023

If we change our internal data structure to xarray it would be good to just add pint support via https://github.com/xarray-contrib/pint-xarray.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants