projects
/
aubio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9aa0af3
)
python/demos/demo_source_auto_samplerate.py: define hop_size
author
Paul Brossier
<piem@piem.org>
Sat, 22 Feb 2014 20:03:46 +0000
(17:03 -0300)
committer
Paul Brossier
<piem@piem.org>
Sat, 22 Feb 2014 20:03:46 +0000
(17:03 -0300)
python/demos/demo_source_auto_samplerate.py
patch
|
blob
|
history
diff --git
a/python/demos/demo_source_auto_samplerate.py
b/python/demos/demo_source_auto_samplerate.py
index
31ba55a
..
1d45a6b
100755
(executable)
--- a/
python/demos/demo_source_auto_samplerate.py
+++ b/
python/demos/demo_source_auto_samplerate.py
@@
-7,9
+7,10
@@
if __name__ == '__main__':
if len(sys.argv) < 2:
print 'usage: %s <inputfile>' % sys.argv[0]
sys.exit(1)
- f = source(sys.argv[1], 0, 256)
- samplerate = f.get_samplerate()
- total_frames, read = 0, 256
+ hop_size = 512
+ f = source(sys.argv[1], 0, hop_size)
+ samplerate = f.samplerate
+ total_frames, read = 0, hop_size
while read:
vec, read = f()
total_frames += read