Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #14868

Remaining numpy 1.24 issues on 32bit architectures

From Andreas Tille <andreas@an3as.eu>
Newsgroups linux.debian.maint.python
Subject Remaining numpy 1.24 issues on 32bit architectures
Date 2023-01-29 12:20 +0100
Message-ID <FTdT3-1XbN-5@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hi,

I think there are some remaining issues with numpy 1.24 migration on 32
bit architectures[1].

Here is one example:

_________ TestSequence.test_getitem_with_slice_has_positional_metadata _________

self = <skbio.sequence.tests.test_sequence.TestSequence testMethod=test_getitem_with_slice_has_positional_metadata>

    def test_getitem_with_slice_has_positional_metadata(self):
        s = "0123456789abcdef"
        length = len(s)
        seq = Sequence(s, metadata={'id': 'id3', 'description': 'dsc3'},
                       positional_metadata={'quality': np.arange(length)})
    
        eseq = Sequence("012", metadata={'id': 'id3', 'description': 'dsc3'},
                        positional_metadata={'quality': np.arange(3)})
        self.assertEqual(seq[0:3], eseq)
        self.assertEqual(seq[:3], eseq)
        self.assertEqual(seq[:3:1], eseq)
    
        eseq = Sequence("def", metadata={'id': 'id3', 'description': 'dsc3'},
                        positional_metadata={'quality': [13, 14, 15]})
>       self.assertEqual(seq[-3:], eseq)
E       AssertionError: Seque[128 chars]: int32>
E       Stats:
E           length: 3
E       ----------------[14 chars]0 def != Seque[128 chars]: int64>
E       Stats:
E           length: 3
E       ----------------[14 chars]0 def

skbio/sequence/tests/test_sequence.py:748: AssertionError

How can I ensure that in both cases the arrays have the same type (I think it makes
no difference whether it is np.int32 or np.int64 as long as they are of same type.

Kind regards

     Andreas.

[1] https://buildd.debian.org/status/package.php?p=python-skbio&suite=experimental

-- 
http://fam-tille.de

Back to linux.debian.maint.python | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

Remaining numpy 1.24 issues on 32bit architectures Andreas Tille <andreas@an3as.eu> - 2023-01-29 12:20 +0100
  Re: Remaining numpy 1.24 issues on 32bit architectures Andreas Tille <andreas@an3as.eu> - 2023-01-30 09:20 +0100
    Re: Remaining numpy 1.24 issues on 32bit architectures Nilesh Patra <nilesh@debian.org> - 2023-01-30 12:40 +0100
      Re: Remaining numpy 1.24 issues on 32bit architectures Andreas Tille <tille@debian.org> - 2023-01-30 13:50 +0100

csiph-web