From: biswajit on
On Jun 1, 12:42 am, ImageAnalyst <imageanal...(a)mailinator.com> wrote:
> Where did you post your image?  Is this the same bar code issue (same
> poster) that came up several weeks ago?  If so, I don't have your link
> handy so could you post it again?  If not, post your image (hopefully
> more than one!!!) for the first time.

Hello ImageAnalyst,
This is my first post related to image processing in this
newsgroup.Has someone else also faced a problem like this before?
As far as posting the image is concerned ,I would love to but fail to
see any link to attach them.I am not aware of any other way to post a
file in this forum.
From: Matt J on
biswajit <biswami(a)gmail.com> wrote in message <4ea9b371-51e4-4cd0-90e0-c62d2e520cb5(a)z13g2000prh.googlegroups.com>...
> Thanks Matt...that resolved the last error,but theres a new one with
> the same function.
> %Read an image into the MATLAB workspace.
> I = double(imread('1.JPG'));
>
> I=rgb2gray(I);
>
> GradientX=diff(I,1,1);
> GradientY=diff(I,1,2);
> Angles=atan2(GradientX,GradientY);
> Now GradientX is a 190x518 matrix while GradientY is a 191x517
> matrix ..since they don't match,atan2( ) again throws error saying:
> Matrix dimensions must agree.
> Please shed some light.
===============

Hi. I'm not entirely clear what I'm shedding light on. Are you saying you don't understand why GradientX and GradientY are of different sizes? For that, you should read the documentation on the diff() function that created them:

help diff
From: ImageAnalyst on
On Jun 1, 2:04 pm, biswajit <bisw...(a)gmail.com> wrote:
> Hello ImageAnalyst,
> This is my first post related to image processing in this
> newsgroup.Has someone else also faced a problem like this before?
> As far as posting the image is concerned ,I would love to but fail to
> see any link to attach them.I am not aware of any other way to post a
> file in this forum.
------------------------------------------------------------------------------
You can post your image anywhere you want. Just search for "Free
image hosting." My favorite because it's by far the easiest for
everyone involved is http://drop.io but there are others such as
flickr.com and imageshack.us.

From: biswajit on

>
> Hi. I'm not entirely clear what I'm shedding light on. Are you saying you don't understand why GradientX and GradientY are of different sizes? For that, you should read the documentation on the diff() function that created them:
>
> help diff

Hi Matt,
I did look at the diff help and understand the reason behind the
matrix sizes of GradientX and Y[The image is a 191x518 matrix.Hence
gradientX is 190x518,one row less, and gradienty is 191x517,one column
less.But since these two matrices need to be passed as arguments to
atan2 which expects both the matrices of same sizes leaves me
confused.Do I need to modify the two matrices to make them same sized
before passing to atan2?
From: biswajit on
On Jun 2, 3:45 am, ImageAnalyst <imageanal...(a)mailinator.com> wrote:
> On Jun 1, 2:04 pm,biswajit<bisw...(a)gmail.com> wrote:> Hello ImageAnalyst,
> > This is my first post related to image processing in this
> > newsgroup.Has someone else also faced a problem like this before?
> > As far as posting the image is concerned ,I would love to but fail to
> > see any link to attach them.I am not aware of any other way to post a
> > file in this forum.
>
> --------------------------------------------------------------------------- ---
> You can post your image anywhere you want.  Just search for "Free
> image hosting."  My favorite because it's by far the easiest for
> everyone involved ishttp://drop.iobut there are others such as
> flickr.com and imageshack.us.

Hi,
I have posted the barcode image here:http://drop.io/maeu2hi.
Thanks