Changeset 5e9c68a for python/aubio
- Timestamp:
- Aug 9, 2005, 7:56:21 PM (19 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:
- a29ad46
- Parents:
- 28d8c4a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
python/aubio/aubioclass.py
r28d8c4a r5e9c68a 30 30 def __init__(self,filename,model=None): 31 31 if (model!=None): 32 self.file = new_ file_wo(model.file,filename)32 self.file = new_aubio_sndfile_wo(model.file,filename) 33 33 else: 34 self.file = new_ file_ro(filename)35 def __del__(self): 36 del_ file(self.file)34 self.file = new_aubio_sndfile_ro(filename) 35 def __del__(self): 36 del_aubio_sndfile(self.file) 37 37 def info(self): 38 file_info(self.file)38 aubio_sndfile_info(self.file) 39 39 def samplerate(self): 40 return aubio_ file_samplerate(self.file)40 return aubio_sndfile_samplerate(self.file) 41 41 def channels(self): 42 return aubio_ file_channels(self.file)42 return aubio_sndfile_channels(self.file) 43 43 def read(self,nfram,vecread): 44 return file_read(self.file,nfram,vecread())44 return aubio_sndfile_read(self.file,nfram,vecread()) 45 45 def write(self,nfram,vecwrite): 46 return file_write(self.file,nfram,vecwrite())46 return aubio_sndfile_write(self.file,nfram,vecwrite()) 47 47 48 48 class pvoc: … … 205 205 return mylist 206 206 207 def getpitch(filein,mode=aubio_ mcomb,bufsize=1024,hopsize=512,omode=aubio_freq,207 def getpitch(filein,mode=aubio_pitch_mcomb,bufsize=1024,hopsize=512,omode=aubio_pitchm_freq, 208 208 samplerate=44100.,silence=-70): 209 209 frameread = 0 … … 228 228 229 229 class pitchdetection: 230 def __init__(self,mode=aubio_ mcomb,bufsize=2048,hopsize=1024,231 channels=1,samplerate=44100.,omode=aubio_ freq):230 def __init__(self,mode=aubio_pitch_mcomb,bufsize=2048,hopsize=1024, 231 channels=1,samplerate=44100.,omode=aubio_pitchm_freq): 232 232 self.pitchp = new_aubio_pitchdetection(bufsize,hopsize,channels, 233 233 samplerate,mode,omode)
Note: See TracChangeset
for help on using the changeset viewer.