On Tue, May 26, 2009 at 03:46:54PM +0200, Rohrhirsch, Jakob wrote:
> I hope this is the right place for my question.

It is. The enthought-dev mailing-list
(https://mail.enthought.com/mailman/listinfo/enthought-dev) may also be
useful, as it has more traffic, and thus more people to help you.

> As far as I understood this,
> the warp_scale='auto' option in mlab's surf() function is supposed to scale
> the z-axis to a reasonable ratio. Following is a script that demonstrates a
> problem I have found:


> from numpy import *
> from enthought.mayavi.mlab import *

> epsilon = 100
> x, y = mgrid[-10.05:10.05:0.1,-10.05:10.05:0.1]
> U = epsilon / sqrt(x**2+y**2)
> s = surf(x,y,U,warp_scale='auto')
> show()


> Now if you change the value of epsilon the image acts in a very weird way. If
> epsilon is 1 or 10 it seems to be ok (ratio of ~2/3). If it's 100 the peak is
> very low. If it's higher than that (1 000, 10 000), the peak is starting to
> rise again. is this a numerical problem I'm experiencing here, or is this
> indeed a bug in mayavi? Help would be very much apprecheated.

This is a bug! Thanks for reporting it. I have fixed it in svn,
https://svn.enthought.com/enthought/changeset/23682
You can work around it by using the extent keyword argument. It is not as
handy as setting warp_scale to 'auto', but if you don't want to install
svn or patch your local version, this is a way forward.

Cheers,

Gaƫl

------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, & 
iPhoneDevCamp asthey present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://www.creativitycat.com 
_______________________________________________
MayaVi-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mayavi-users

Reply via email to