Skip to content

Commit 4ad8a87

Browse files
committed
Gets rid of a few more deprecation warnings.
In particular, the last input to linspace has to be an integer!
1 parent cd91833 commit 4ad8a87

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

nitime/utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1161,8 +1161,8 @@ def fftconvolve(in1, in2, mode="full", axis=None):
11611161
"""
11621162
s1 = np.array(in1.shape)
11631163
s2 = np.array(in2.shape)
1164-
complex_result = (np.issubdtype(in1.dtype, np.complex) or
1165-
np.issubdtype(in2.dtype, np.complex))
1164+
complex_result = (np.issubdtype(in1.dtype, np.complex128) or
1165+
np.issubdtype(in2.dtype, np.complex128))
11661166

11671167
if axis is None:
11681168
size = s1 + s2 - 1
@@ -1209,7 +1209,7 @@ def get_freqs(Fs, n):
12091209
"""Returns the center frequencies of the frequency decomposition of a time
12101210
series of length n, sampled at Fs Hz"""
12111211

1212-
return np.linspace(0, Fs / 2, n / 2 + 1)
1212+
return np.linspace(0, Fs / 2, int(n / 2 + 1))
12131213

12141214

12151215
def circle_to_hz(omega, Fsamp):

0 commit comments

Comments
 (0)