craffel / mir_eval

Evaluation functions for music/audio information retrieval/signal processing algorithms.
MIT License
588 stars 109 forks source link

Test fails on 32 bit x86 #351

Closed bgermann closed 2 months ago

bgermann commented 1 year ago
ERROR: test_sonify.test_time_frequency
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/builds/debian/mir-eval/debian/output/source_dir/tests/test_sonify.py", line 24, in test_time_frequency
    signal = mir_eval.sonify.time_frequency(
  File "/builds/debian/mir-eval/debian/output/source_dir/.pybuild/cpython3_3.10_mir-eval/build/mir_eval/sonify.py", line 177, in time_frequency
    wave[start:end] * gram_interpolator(np.arange(start, end)))
ValueError: array is too big; `arr.size * arr.dtype.itemsize` is larger than the maximum possible size.
======================================================================
ERROR: test_sonify.test_chroma
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/builds/debian/mir-eval/debian/output/source_dir/tests/test_sonify.py", line 36, in test_chroma
    signal = mir_eval.sonify.chroma(
  File "/builds/debian/mir-eval/debian/output/source_dir/.pybuild/cpython3_3.10_mir-eval/build/mir_eval/sonify.py", line 297, in chroma
    return time_frequency(gram, frequencies, times, fs, **kwargs)
  File "/builds/debian/mir-eval/debian/output/source_dir/.pybuild/cpython3_3.10_mir-eval/build/mir_eval/sonify.py", line 177, in time_frequency
    wave[start:end] * gram_interpolator(np.arange(start, end)))
ValueError: array is too big; `arr.size * arr.dtype.itemsize` is larger than the maximum possible size.
----------------------------------------------------------------------
bmcfee commented 3 months ago

I think this should have been addressed by #355 - we had a units conversion error between samples and seconds. For reasonable input values, this should no longer hit an integer overflow.

bmcfee commented 2 months ago

I tested this out on a 32bit environment and it seems fixed now. I'll close this out, but reopen if the problem recurs.