G-Node / nix

Neuroscience information exchange format
https://readthedocs.org/projects/nixio/
Other
66 stars 36 forks source link

Unit handling #704

Closed jgrewe closed 6 years ago

jgrewe commented 6 years ago

relaxed the unit handling at two places:

1) Properties may have non-SI units. Passing an empty string, or one that consists of only blanks, will remove the unit from the property. 2) DataArrays: The value unit may be non-SI. In case the dimensionality of the DataArray is 1-D and the first dimension is an AliasRangeDimension setting an non-SI will lead to an exception. In case a non-SI unit is set, the attempt of adding an AliasRangeDimension will lead to an exception.

Data retrieval functions behave as before: if there are units and theses can not be scaled, an exception will be thrown.

achilleas-k commented 6 years ago

I'll allow it. 🙂