[SciPy-dev] Bug in signaltools.py

Pearu Peterson pearu at cens.ioc.ee
Fri Feb 7 16:20:06 EST 2003


On 7 Feb 2003, Otto Tronarp wrote:

> On Fri, 2003-02-07 at 15:24, Nils Wagner wrote:
> > Hi,
> > 
> > I guess there is a bug in signaltools.py
> [snip]
> >   File
> > "/usr/local/lib/python2.1/site-packages/scipy/signal/signaltools.py",
> > line 190
> >     order = numels//2
> >                    ^
> > SyntaxError: invalid syntax
> > >>>
> > 
> > Any idea ?
> > 
> > Nils
> 
> I don't know if the // is a typo or if it is intentional, if it is
> intentional you need to upgrade your python to a version that uses //
> for integer division. (2.2.1 works for me)

Scipy should to work with Python 2.1 as well (until decided
otherwise). So, I have fixed this bug in CVS. I believe it is safe to use
int(n/m) for future n//m, even when n/m will return true division.

Pearu




More information about the SciPy-Dev mailing list