Hi guys,

I was wondering what is the strategy adopted by Mayavi when has to
render an -Inf value.
I don't know if that's the problem, but I can't see anything on the window.

Consider this code:

    import numpy as np
    from enthought.mayavi.mlab import *

    def f(x, y):

        return pow(x,-3) * y

    x, y = np.mgrid[0.1:3:0.1, -2.:2:0.01]

    s = surf(x, y, f)


    In [6]: f(x,y)
    Out[6]:
    array([[            -Inf,             -Inf,             -Inf, ...,
                         Inf,              Inf,              Inf],
           [ -2.00000000e+03,  -1.99000000e+03,  -1.98000000e+03, ...,
              1.97000000e+03,   1.98000000e+03,   1.99000000e+03],
           [ -2.50000000e+02,  -2.48750000e+02,  -2.47500000e+02, ...,
              2.46250000e+02,   2.47500000e+02,   2.48750000e+02],
           ...,
           [ -1.01610527e-01,  -1.01102474e-01,  -1.00594422e-01, ...,
              1.00086369e-01,   1.00594422e-01,   1.01102474e-01],
           [ -9.11078717e-02,  -9.06523324e-02,  -9.01967930e-02, ...,
              8.97412536e-02,   9.01967930e-02,   9.06523324e-02],
           [ -8.20041822e-02,  -8.15941613e-02,  -8.11841404e-02, ...,
              8.07741195e-02,   8.11841404e-02,   8.15941613e-02]])

Cheers,
Michele.

------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
MayaVi-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Reply via email to