Changeset 437ef07


Ignore:
Timestamp:
Apr 30, 2016, 6:22:58 AM (9 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
Children:
1f87c1b
Parents:
6014dc0
Message:

python/tests/test_fft.py: clean up, add tests for f.rdo input size

File:
1 edited

Legend:

Unmodified
Added
Removed
  • python/tests/test_fft.py

    r6014dc0 r437ef07  
    141141        f = fft(win_s)
    142142        t = fvec(win_s + 1)
    143         print f(t)
    144143        with self.assertRaises(ValueError):
    145             print f(t)
     144            f(t)
    146145
    147146    def test_small_input_timegrain(self):
     
    149148        f = fft(win_s)
    150149        t = fvec(1)
    151         print f(t).phas
    152150        with self.assertRaises(ValueError):
    153151            f(t)
     152
     153    def test_large_input_fftgrain(self):
     154        win_s = 1024
     155        f = fft(win_s)
     156        s = cvec(win_s + 1)
     157        with self.assertRaises(ValueError):
     158            f.rdo(s)
     159
     160    def test_small_input_timegrain(self):
     161        win_s = 1024
     162        f = fft(win_s)
     163        s = cvec(16)
     164        with self.assertRaises(ValueError):
     165            f.rdo(s)
    154166
    155167if __name__ == '__main__':
Note: See TracChangeset for help on using the changeset viewer.