Hi,
 
You can also use Numpy.gradient to compute the gradient , if e.g. your dx and dy aren't the same.
 
Cheers,
 
Thom

**********************
Thomas Lecocq
Geologist
Ph.D.Student (Seismology)
Royal Observatory of Belgium
**********************


 
> Date: Tue, 29 Jun 2010 16:28:11 +0200
> From: mathieu.dubois@limsi.fr
> To: matplotlib-users@lists.sourceforge.net
> Subject: Re: [Matplotlib-users] Displaying the gradient of an image
>
> Hello,
>
> I finally found the solution. It's as simple as:
> figure();
> imshow(img);
> pylab.quiver(U, V, units='x');
>
> Mathieu
>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Sprint
> What will you do first with EVO, the first 4G phone?
> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users