[SciPy-user] Bug report - unwrap function error

Hugo Gamboa hgamboa at gmail.com
Thu Dec 29 18:03:13 CST 2005


I have the a recent svn version (1501), and when trying to use the
unwrap function it gave me the error transcribed above.

In a move to correct the bug to continue my work, I could not found
the definition of the mod function. I know that it exists in scipy.mod
but was unable to track the function.

If someone could help this beginner to simply track a function in
scipy, I would be very appreciated.

Thanks in advance for your help.

Hugo Gamboa

The error reported in a ipython session

In [13]: scipy.unwrap([1,2,3,4])
exceptions.NameError                                 Traceback (most
recent call last)

/usr/lib/python2.4/site-packages/scipy/base/function_base.py in
unwrap(p, discont, axis)
    480     slice1 = [slice(None, None)]*nd     # full slices
    481     slice1[axis] = slice(1, None)
--> 482     ddmod = mod(dd+pi, 2*pi)-pi
    483     _nx.putmask(ddmod, (ddmod==-pi) & (dd > 0), pi)
    484     ph_correct = ddmod - dd;

NameError: global name 'mod' is not defined

More information about the SciPy-user mailing list