Numpy Float Issue and Syntax Warnings
Running Python 3.11.5 and NumPy 1.26.4 was causing a few issues. The first caused an import failure and is related to several calls to np.float which was deprecated in NumPy 1.20.0. Here is the error:
AttributeError: module 'numpy' has no attribute 'float'.
`np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, 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.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
The second was a more minor syntax warning due to several is or is not comparisons to literals. For example, in segmented_dpc_class.py line 252 was:
elif fudge is 'i0'
which caused a SyntaxWarning:
SyntaxWarning: "is" with a literal. Did you mean "=="?
I have fixed both of these issues in this branch:
https://gitlab.com/aaherzing/fpd/-/tree/Fix_NumPy_Float_Issue?ref_type=heads
The first was fixed by changing the instances of np.float to simply float. The second by replacing is not with != and is with ==. This seems to pass the tests and I can create a merge request if it would be helpful.