Bug#1079681: python-ltfatpy: tests fail with scipy 1.14

Antonio Valentino antonio.valentino at tiscali.it
Sat Sep 28 17:34:46 BST 2024


Il 28/09/24 18:20, Antonio Valentino ha scritto:
> Dear Drew,
> 
> On Mon, 26 Aug 2024 09:56:21 +0200 Drew Parsons <dparsons at debian.org> 
> wrote:
>> Source: python-ltfatpy
>> Version: 1.0.16-10
>> Severity: normal
>>
>> python-ltfatpy is failing tests with scipy 1.14 (from experimental)
>>
>>
>>  94s _________________________ TestGabWin.test_str_entries 
>> __________________________
>>  94s  94s self = <ltfatpy.tests.gabor.test_gabwin.TestGabWin 
>> testMethod=test_str_entries>
>>  94s  94s     def test_str_entries(self):
>>  94s         a = random.randint(10, 40)
>>  94s         M = random.randint(10, 40)
>>  94s         L = M * random.randint(2, 5)
>>  94s  94s         # psech
>>  94s         mess = "a = {0:d}, M = {1:d}, L = {2:d}".format(a, M, L)
>>  94s         (g, info) = gabwin("psech", a, M, L)
>>  94s         mess += "\ng = " + str(g)
>>  94s         mess += "\ninfo = " + str(info)
>>  94s         self.assertFalse(info['gauss'], mess)
>>  94s         self.assertTrue(info['wasreal'], mess)
>>  94s         self.assertFalse(info['istight'], mess)
>>  94s         self.assertFalse(info['isdual'], mess)
>>  94s         self.assertFalse(info['wasrow'], mess)
>>  94s         self.assertFalse(info['isfir'], mess)
>>  94s         self.assertEqual(info["tfr"], a*M/L, mess)
>>  94s         self.assertEqual(info["gl"], len(g), mess)
>>  94s         gt = psech(L, a*M/L)[0]
>>  94s         mess += "\ngt = " + str(gt)
>>  94s         np.testing.assert_array_almost_equal(g, gt, 10, mess)
>>  94s         self.assertRaises(ValueError, gabwin, "sech", a, M)
>>  94s  94s         # dualgauss
>>  94s         mess = "a = {0:d}, M = {1:d}, L = {2:d}".format(a, M, L)
>>  94s         (g, info) = gabwin("dualgauss", a, M, L)
>>  94s         mess += "\ng = " + str(g)
>>  94s         mess += "\ninfo = " + str(info)
>>  94s         self.assertFalse(info['gauss'], mess)
>>  94s         self.assertTrue(info['wasreal'], mess)
>>  94s         self.assertFalse(info['istight'], mess)
>>  94s         self.assertTrue(info['isdual'], mess)
>>  94s         self.assertFalse(info['wasrow'], mess)
>>  94s         self.assertFalse(info['isfir'], mess)
>>  94s         self.assertEqual(info["tfr"], a*M/L, mess)
>>  94s         self.assertEqual(info["gl"], len(g), mess)
>>  94s         gt = gabdual(pgauss(L, a*M/L)[0], a, M)
>>  94s         mess += "\ngt = " + str(gt)
>>  94s >       np.testing.assert_array_almost_equal(g, gt, 10, mess)
>>  94s  94s 
>> /usr/lib/python3/dist-packages/ltfatpy/tests/gabor/test_gabwin.py:153: 
>>  94s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
>> _ _ _ _ _ _ _  94s /usr/lib/python3.12/contextlib.py:81: in inner
>>  94s     return func(*args, **kwds)
>>  94s _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
>> _ _ _ _ _ _ _  94s  94s args = (<function 
>> assert_array_almost_equal.<locals>.compare at 0x7f93d85ce700>, array([ 
>> 2.43659318e-01,  2.49038983e-01,  2....366e-01,  5.41698845e+13,  
>> 4.79537976e-01,
>>  94s         3.50772907e-01,  2.97075482e-01,  2.65937405e-01,  
>> 2.49038983e-01]))
>>  94s kwds = {'err_msg': 'a = 12, M = 12, L = 48\ng = [ 2.43659318e-01  
>> 2.49038983e-01  2.65937405e-01  2.97075482e-01\n  
>> 3.5077290...937405e-01  2.49038983e-01]', 'header': 'Arrays are not 
>> almost equal to 10 decimals', 'precision': 10, 'verbose': True}
> 
> 
> Unfortunately I'm unable to replicate the issue locally using the latest 
> version of scipy 1.14 form experimental (1.14.0-1exp5 - amd64).
> I have just triggered a new build in debian-ci to understand if, maybe, 
> the issue is on my side.
> 
> Is this still an issue for you?
> 
> kind regards

Indeed debci seems to work fine now:

https://ci.debian.net/packages/p/python-ltfatpy/unstable/amd64/52579773/


Can we close?

regards
-- 
Antonio Valentino



More information about the debian-science-maintainers mailing list