isi-nmr / brukerapi-python

A Python package providing I/O interface for Bruker data sets
MIT License
18 stars 11 forks source link

np.float #10

Open andrewendlinger opened 1 year ago

andrewendlinger commented 1 year ago

In the latest numpy version (1.24.1) the use of 'np.float' raises an error. 'np.float' is e.g. used in brukerapi/schemas.py: line 580.

According to the DepricationWarning from an earlier numpy version, this is a quick fix: DeprecationWarning: np.float is a deprecated alias for the builtin float. To silence this warning, use float by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.float64 here. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations

wtclarke commented 1 year ago

Hi @tomas-psorn Just chipping in to say that I'm also seeing issues with this. e.g. https://github.com/isi-nmr/brukerapi-python/blob/c2f449dcfac743623603df08760f9d95e536477d/brukerapi/jcampdx.py#L292.

I will open a PR for this and the above np.float (and any others that I can spot) shortly.

BW

Will

wtclarke commented 1 year ago

PR now made. See #11

musicinmybrain commented 1 year ago

Since https://github.com/isi-nmr/brukerapi-python/pull/11 was merged and released, it seems like this can be closed.