Changeset 7e114c8 for tests/python/src
- Timestamp:
- Sep 30, 2009, 1:24:56 AM (15 years ago)
- 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:
- 1cc007c
- Parents:
- f11d78d
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
tests/python/src/temporal/a_weighting.py
rf11d78d r7e114c8 1 from template import aubio_unit_template 2 from aubio.aubiowrapper import * 1 from localaubio import * 3 2 4 3 samplerate = 44100 … … 9 8 10 9 def setUp(self): 11 self.o = new_aubio_ adsgn_filter(samplerate, channels)10 self.o = new_aubio_filter_a_weighting (samplerate, channels) 12 11 13 12 def tearDown(self): 14 del_aubio_ adsgn_filter(self.o)13 del_aubio_filter (self.o) 15 14 16 15 def test_creation(self): … … 20 19 """ check filter run on a vector full of zeroes returns zeros """ 21 20 vec = new_fvec(buf_size, channels) 22 aubio_ adsgn_filter_do(self.o, vec)21 aubio_filter_do (self.o, vec) 23 22 for index in range(buf_size): 24 23 for channel in range(channels): … … 31 30 for channel in range(channels): 32 31 fvec_write_sample(vec, 1., channel, index) 33 aubio_ adsgn_filter_do(self.o, vec)32 aubio_filter_do (self.o, vec) 34 33 for index in range(buf_size): 35 34 for channel in range(channels): … … 41 40 for index in range(buf_size): 42 41 for channel in range(channels): 43 fvec_write_sample(vec, 1.e-37, channel, index)44 aubio_ adsgn_filter_do(self.o, vec)42 fvec_write_sample(vec, 2.e-42, channel, index) 43 aubio_filter_do (self.o, vec) 45 44 for index in range(buf_size): 46 45 for channel in range(channels): … … 49 48 50 49 if __name__ == '__main__': 50 import unittest 51 51 unittest.main()
Note: See TracChangeset
for help on using the changeset viewer.