Open
Description
For example, consider the spectroscopy
context:
@context(n=1) spectroscopy = sp
There the conversion depends on the variable n
used. Now, consider a DataArray
/DataSet
where n
is a dimension
/coordinate
. Then when calling DataArray.pint.to("nm")
we would want the variable n
to be dynamically imported from the current context of the DataArray
coordinate.
API-wise I am not sure how that would work, maybe by passing a list/dict of context objects (+ variables)? This might also involve upstream pint
support for more complicated context and decorators.
Metadata
Metadata
Assignees
Labels
No labels