octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: automated (or otherwise) tests for graphics code?


From: John W. Eaton
Subject: Re: automated (or otherwise) tests for graphics code?
Date: Fri, 17 Oct 2008 11:20:38 -0400

On 17-Oct-2008, David Bateman wrote:

| David Bateman wrote:
| > John W. Eaton wrote:
| >> We seem to be having a lot of regressions in the graphics code
| >> lately, so maybe it is time to start thinking of some way to provide
| >> tests for these functions.  
| >
| > Hey progress is making a different mistake -)
| 
| I applied the attached patch that fixes a few more of the plotting problems

Thanks.

With your patch, I currently see these remaining demo failures

  /home/jwe/src/octave/scripts/plot/plotyy.m example 1:
   x = 0:0.1:2*pi; 
   y1 = sin (x);
   y2 = exp (x - 1);
   ax = plotyy (x, y1, x - 1, y2, @plot, @semilogy);
   xlabel ("X");
   ylabel (ax(1), "Axis 1");
   ylabel (ax(2), "Axis 2");

  /home/jwe/src/octave/scripts/plot/plotyy.m example 1: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/quiver.m example 1:
   [x,y] = meshgrid(1:2:20);
   h = quiver(x,y,sin(2*pi*x/10),sin(2*pi*y/10))
   set (h, "maxheadsize", 0.33);

  /home/jwe/src/octave/scripts/plot/quiver.m example 1: failed
  axes: expecting argument to be a scalar axes handle
  Press <enter> to continue: 


  /home/jwe/src/octave/scripts/plot/quiver.m example 2:
   axis("equal");
   x=linspace(0,3,80); y=sin(2*pi*x); theta=2*pi*x+pi/2;
   quiver(x,y,sin(theta)/10,cos(theta)/10);
   hold on; plot(x,y,"r"); hold off;

  /home/jwe/src/octave/scripts/plot/quiver.m example 2: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/quiver3.m example 1:
   [x,y]=meshgrid (-1:0.1:1); 
   z=sin(2*pi*sqrt(x.^2+y.^2)); 
   theta=2*pi*sqrt(x.^2+y.^2)+pi/2;
   quiver3(x,y,z,sin(theta),cos(theta),ones(size(z)));
   hold on; 
   mesh(x,y,z); 
   hold off;

  /home/jwe/src/octave/scripts/plot/quiver3.m example 1: failed
  axes: expecting argument to be a scalar axes handle
  Press <enter> to continue: 


  /home/jwe/src/octave/scripts/plot/quiver3.m example 2:
   [x, y, z] = peaks (25);
   surf (x, y, z);
   hold on;
   [u, v, w] = surfnorm (x, y, z / 10);
   h = quiver3 (x, y, z, u, v, w);
   set (h, "maxheadsize", 0.33);

  /home/jwe/src/octave/scripts/plot/quiver3.m example 2: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/refreshdata.m example 1:
   x = 0:0.1:10;
   y = sin (x);
   plot (x, y, "ydatasource", "y");
   for i = 1 : 100
     pause(0.1)
     y = sin (x + 0.1 * i);
     refreshdata();
   endfor

  /home/jwe/src/octave/scripts/plot/refreshdata.m example 1: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/ribbon.m example 1:
   [x, y, z] = sombrero ();
   [x, y] = meshgrid (x, y);
   ribbon (y, z);

  /home/jwe/src/octave/scripts/plot/ribbon.m example 1: failed
  get: invalid handle (= -112.307)


  /home/jwe/src/octave/scripts/plot/rose.m example 1:
   rose ([2*randn(1e5,1), pi + 2 * randn(1e5,1)])


  /home/jwe/src/octave/scripts/plot/rose.m example 1: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/scatter.m example 1:
   x = randn (100, 1);
   y = randn (100, 1);
   scatter (x, y, [], sqrt(x.^2 + y.^2));

  /home/jwe/src/octave/scripts/plot/scatter.m example 1: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/scatter3.m example 1:
   [x, y, z] = peaks (20);
   scatter3 (x(:), y(:), z(:), [], z(:));

  /home/jwe/src/octave/scripts/plot/scatter3.m example 1: failed
  axes: expecting argument to be a scalar axes handle


  /home/jwe/src/octave/scripts/plot/surfnorm.m example 1:
   [x, y, z] = peaks(10);
   surfnorm (x, y, z);

  warning: implicit conversion from matrix to real vector
  /home/jwe/src/octave/scripts/plot/surfnorm.m example 1: failed

  Invalid call to any.  Correct usage is:

   -- Built-in Function:  any (X, DIM)


  Additional help for built-in functions and operators is
  available in the on-line version of the manual.  Use the command
  `doc <topic>' to search the manual index.

  Help and information about Octave is also available on the WWW
  at http://www.octave.org and via the address@hidden
  mailing list.
  error: get: invalid handle (= -93.25)
  error: called from:
  error:   /home/jwe/src/octave/scripts/plot/__go_draw_axes__.m at line 60, 
column 9
  error:   /home/jwe/src/octave/scripts/plot/__go_draw_figure__.m at line 56, 
column 8
  error:   /home/jwe/src/octave/scripts/plot/gnuplot_drawnow.m at line 68, 
column 5
  error: input: reading user-input failed!
  error:   /home/jwe/src/octave/scripts/testfun/demo.m at line 111, column 7
  error:   /home/jwe/src/octave/scripts/testfun/rundemos.m at line 65, column 2
  error:   /home/jwe/src/octave/scripts/testfun/rundemos.m at line 52, column 5


I'll take a look at these if no one else is, but I don't want to
duplicate work.

Thanks,

jwe


reply via email to

[Prev in Thread] Current Thread [Next in Thread]