Skip to content

Commit 70a2a9f

Browse files
committedNov 25, 2024·
test: fix compat problems with scipy 1.13
1 parent c6c5c8b commit 70a2a9f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
 

‎requirements.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
numpy>=1.24.0
22
numpy<2.0.0
3-
scipy>=1.10.0
3+
scipy>=1.13.0
44
utm>=0.7.0
55
pandas>=1.5.0
66
bokeh>=3.0.0

‎tests/test_basic.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def test_no_models(self):
168168
os.environ["PATH"] = ""
169169

170170
self.assertEqual(uwapm.models(), [])
171-
171+
172172
class SignalTestSuite(MyTestCase):
173173

174174
def test_time(self):
@@ -178,12 +178,12 @@ def test_time(self):
178178
def test_cw(self):
179179
self.assertArrayEqual(signal.cw(10000, 0.1, 50000), np.sin(2*np.pi*10000*np.arange(5000, dtype=np.float64)/50000), precision=6)
180180
self.assertArrayEqual(signal.cw(10000, 0.1, 50000, complex_output=True), np.exp(2j*np.pi*10000*np.arange(5000, dtype=np.complex128)/50000), precision=6)
181-
self.assertArrayEqual(signal.cw(10000, 0.1, 50000, ('tukey', 0.1)), sp.tukey(5000, 0.1)*np.sin(2*np.pi*10000*np.arange(5000, dtype=np.float64)/50000), precision=2)
181+
self.assertArrayEqual(signal.cw(10000, 0.1, 50000, ('tukey', 0.1)), sp.windows.tukey(5000, 0.1)*np.sin(2*np.pi*10000*np.arange(5000, dtype=np.float64)/50000), precision=2)
182182

183183
def test_sweep(self):
184184
self.assertArrayEqual(signal.sweep(5000, 10000, 0.1, 50000), sp.chirp(np.arange(5000, dtype=np.float64)/50000, 5000, 0.1, 10000, 'linear'))
185185
self.assertArrayEqual(signal.sweep(5000, 10000, 0.1, 50000, 'hyperbolic'), sp.chirp(np.arange(5000, dtype=np.float64)/50000, 5000, 0.1, 10000, 'hyperbolic'))
186-
self.assertArrayEqual(signal.sweep(5000, 10000, 0.1, 50000, window=('tukey', 0.1)), sp.tukey(5000, 0.1)*sp.chirp(np.arange(5000, dtype=np.float64)/50000, 5000, 0.1, 10000), precision=2)
186+
self.assertArrayEqual(signal.sweep(5000, 10000, 0.1, 50000, window=('tukey', 0.1)), sp.windows.tukey(5000, 0.1)*sp.chirp(np.arange(5000, dtype=np.float64)/50000, 5000, 0.1, 10000), precision=2)
187187

188188
def test_envelope(self):
189189
x = np.random.normal(0, 1, 1000)

0 commit comments

Comments
 (0)
Please sign in to comment.