help-octave
[Top][All Lists]
Advanced

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

Re: 'rgb2gray' undefined


From: Carnë Draug
Subject: Re: 'rgb2gray' undefined
Date: Thu, 17 May 2012 03:25:25 +0100

On 16 May 2012 22:01, Nathan Armer <address@hidden> wrote:
> Yes, that worked, but now I'm getting "imfilter: first input argument must be 
> an image":
>
> octave:1> im1=imread('01.jpg');
> warning: your version of GraphicsMagick limits images to 16 bits per pixel
> octave:2> im2=imread('02.jpg');
> octave:3> uv=estimate_flow_interface(im1,im2);
> error: imfilter: first input argument must be an image
> error: called from:
> error:   C:\Octave3.6.1_gcc4.6.2\share\octave\3.6.1\m\image\imfilter.m at 
> line 6
> 7, column 5
> error:   
> C:\Octave3.6.1_gcc4.6.2\share\octave\3.6.1\m\flow_code\utils\compute_im
> age_pyramid.m at line 46, column 5
> error:   C:address@hidden
> cal_flow\compute_flow.m at line 93, column 21
> error:   
> C:\Octave3.6.1_gcc4.6.2\share\octave\3.6.1\m\flow_code\estimate_flow_in
> terface.m at line 90, column 5
> octave:3>
>
> The images are the first and second frames from the MIT test sequence 
> "table": http://people.csail.mit.edu/celiu/motionAnnotation/database/table.zip

Looking at the source (please look into
C:\Octave3.6.1_gcc4.6.2\share\octave\3.6.1\m\image\imfilter.m ),
you'll see the following:

65      [imrows, imcols, imchannels, tmp] = size(im);
66      if (tmp != 1 || (imchannels != 1 && imchannels != 3))
67      error("imfilter: first input argument must be an image");
68      endif

this are the lines that are causing your error. You should look better
into what you're giving to the function. Could you isolate the source
of the problem?

Carnë


reply via email to

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