Changeset 4120fbc for python/demos/demo_slicing.py
- Timestamp:
- May 16, 2016, 3:16:00 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:
- dc654f8
- Parents:
- 416ddd1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
python/demos/demo_slicing.py
r416ddd1 r4120fbc 7 7 if __name__ == '__main__': 8 8 if len(sys.argv) < 3: 9 print 'usage: %s <inputfile> <duration>' % sys.argv[0]9 print('usage: %s <inputfile> <duration>' % sys.argv[0]) 10 10 sys.exit(1) 11 11 source_file = sys.argv[1] … … 45 45 total_duration = total_frames_written / float(samplerate) 46 46 slice_n += 1 47 print 'created %(slice_n)s slices from %(source_base_name)s%(source_ext)s' % locals(), 48 print ' (total duration %(total_duration).2fs)' % locals() 47 outstr = 'created %(slice_n)s slices from %(source_base_name)s%(source_ext)s' % locals() 48 outstr += ' (total duration %(total_duration).2fs)' % locals() 49 print(outstr) 49 50 # close source and sink files 50 51 del f, g
Note: See TracChangeset
for help on using the changeset viewer.