Changeset 0e362b5 for python/tests
- Timestamp:
- Jul 27, 2015, 10:26:27 AM (9 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:
- a1718fc
- Parents:
- 9c8c8a6
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
python/tests/test_cvec.py
r9c8c8a6 r0e362b5 10 10 def test_vector_created_with_zeroes(self): 11 11 a = cvec(10) 12 a13 12 shape(a.norm) 14 13 shape(a.phas) … … 36 35 spec = cvec(1024) 37 36 spec.norm[40:100] = 100 38 assert_equal 39 assert_equal 40 assert_equal 41 assert_equal 37 assert_equal(spec.norm[0:40], 0) 38 assert_equal(spec.norm[40:100], 100) 39 assert_equal(spec.norm[100:-1], 0) 40 assert_equal(spec.phas, 0) 42 41 43 42 def test_assign_cvec_phas_slice(self): 44 43 spec = cvec(1024) 45 44 spec.phas[39:-1] = -pi 46 assert_equal 47 assert_equal 48 assert_equal 45 assert_equal(spec.phas[0:39], 0) 46 assert_equal(spec.phas[39:-1], -pi) 47 assert_equal(spec.norm, 0) 49 48 50 49 if __name__ == '__main__':
Note: See TracChangeset
for help on using the changeset viewer.