You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For a few functions, mainly related to CWT, I get the error below about the use of np.int. When I adjust the fft_kwargs in helpers.py, updating to np.int64 (an arbitrary choice, as opposed to np.int32), the bug resolves. I see that np.int is also used in cwt and wct functions (wavelet.py) and the smooth method of the Morlet class (mothers.py).
This seems like a pretty quick fix. I'm happy to open a pull request myself!
File "..\anaconda3\envs\wavelet-dashboard\lib\site-packages\pycwt\wavelet.py", line 91, in cwt
signal_ft = fft.fft(signal, **fft_kwargs(signal))
File "..\anaconda3\envs\wavelet-dashboard\lib\site-packages\pycwt\helpers.py", line 30, in fft_kwargs
return {'n': np.int(2 ** np.ceil(np.log2(len(signal))))}
File "..\anaconda3\envs\wavelet-dashboard\lib\site-packages\numpy\__init__.py", line 305, in __getattr__
raise AttributeError(__former_attrs__[attr])
AttributeError: module 'numpy' has no attribute 'int'.
`np.int` was a deprecated alias for the builtin `int`. To avoid this error in existing code, use `int` by itself. Doing this will not modify any behavior and is safe. When replacing `np.int`, you may wish to use e.g. `np.int64` or `np.int32` to specify the precision. If you wish to review your current use, check the release note link for
additional information.
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. Did you mean: 'inf'?
The text was updated successfully, but these errors were encountered:
For a few functions, mainly related to CWT, I get the error below about the use of
np.int
. When I adjust thefft_kwargs
inhelpers.py
, updating tonp.int64
(an arbitrary choice, as opposed tonp.int32
), the bug resolves. I see thatnp.int
is also used incwt
andwct
functions (wavelet.py
) and thesmooth
method of theMorlet
class (mothers.py
).This seems like a pretty quick fix. I'm happy to open a pull request myself!
The text was updated successfully, but these errors were encountered: