[SciPy-user] scipy tutorials
gruben at bigpond.net.au
Fri Jun 24 21:19:26 CDT 2005
First, thanks for producing and advertising the existence of these.
I thought I'd try your Echo Cancellation tute. A few problems I found:
The comment "the python sound docs at python.org are an excellent
resource." isn't enough info for me to easily find the docs you're
talking about - in fact I quickly gave up. Perhaps adding a "search for
'foo'" would help.
You need to add a line to make it stand-alone:
>>> from scipy import *
The first time I tried this:
>>> original_signal[i] = struct.unpack('B',osf.readframes(1))
I got a traceback
Traceback (most recent call last):
File "<pyshell#22>", line 2, in -toplevel-
original_signal[i] = struct.unpack('B',osf.readframes(1))
error: unpack str size does not match format
so presumably there are restrictions on the .wav file format. I tried a
different .wav file and it worked fine. Perhaps providing a short .wav
file of the correct format would be a good idea. In fact, I found that
the .wav I use locks up at the correlation step, presumably because it's
too big (65k ~ 5 seconds), so at least put a comment in to keep the .wav
of the order of a second. I'll try again later.
Half-way through you change from using original_signal to osig
This needs fixing.
You haven't shown the commands to produce the waveform plots.
Something simple like
>>> from pylab import *
[<matplotlib.lines.Line2D instance at 0x028909B8>]
unless you want to assume usage with Ipython in interactive mode.
I had a quick look at the DTMF tute. Since, this contains plotting
instructions, I assume it is intended to be done before the Echo
Cancellation tute. This needs commenting or at a minimum reordering of
the links on the webpage.
I haven't run through it, but I noticed there's a syntax-error
>>> From scipy import *
Hope this helps,
Matt Fishburn wrote:
> Hello all,
> I've written some basic scipy tutorials, located at:
> The tutorials are meant to be a resource to people starting to work with
> scipy/matplotlib/ipython. A few more tutorials should be coming over
> the next month or so. Please let me have any feedback - if you find the
> tutorials useful, if you thought something wasn't explained well, etc.
> -Matt Fishburn
More information about the SciPy-user