[SciPy-user] scipy.sign

Fernando Perez Fernando.Perez at colorado.edu
Wed Sep 22 13:32:41 EDT 2004


p.berkes at biologie.hu-berlin.de wrote:
> Using the last CVS scipy_base module, I get a problem with scipy.sign 
> after a call to scipy.alter_numeric:
> 
>  Python 2.3.4 (#1, Jul 30 2004, 12:17:30)
>  [GCC 3.2 20020903 (Red Hat Linux 8.0 3.2-7)] on linux2
>  Type "help", "copyright", "credits" or "license" for more
>  information.
>  >>> import scipy
>  >>> scipy.__version__
>  '0.3.0_266.4239'
>  >>> scipy.scipy_base_version.scipy_base_version
>  '0.3.1_20.301'
>  >>> scipy.sign(-1)
>  -1
>  >>> scipy.alter_numeric()
>  >>> scipy.sign(-1)
>  255
> 
> which is the wrong answer. Is anybody able to reproduce this bug?

No problems here:

In [1]: import scipy

In [2]: scipy.sign(-1)
Out[2]: -1

In [3]: scipy.alter_numeric()

In [4]: scipy.sign(-1)
Out[4]: -1

In [5]: scipy.__version__
Out[5]: '0.3.1_281.4212'

In [6]: scipy.scipy_base_version.scipy_base_version
Out[6]: '0.3.1_20.297'

Cheers,

f




More information about the SciPy-User mailing list