Barcode Recognition with Neuronal Network

  • Follow


Hi Guys,

Please help! Following problem. We have to do a project with Neuronal Networks. 
We would like to process a *.jpg in order to find a 2/5 interleaved barcode (barcode tag) on it. 

Barcode itself could be also slightly rotated or poor quality. This means fristly it is required to find the barcodes characteristic at the image and process it, means make algorithm too see were it is, with a simple Neuronal Network. This Network must classify if there is a barcode, according certain parameters eg.: horizontal, vertical lines, white window with black lines, ... and mark the boundaries. 

If the NN found a barcode, a reader should evaluate selected area --> result should be displayed.

As we are complete rookies on Matlab and NN´s we are quite in trouble ....

regards,
team 1
0
Reply Andreas 11/22/2010 4:42:05 PM

"Andreas " <andreas.salznig@knapp.com> wrote in message <ice6gt$jga$1@fred.mathworks.com>...
> Hi Guys,
> 
> Please help! Following problem. We have to do a project with Neuronal Networks. 
> We would like to process a *.jpg in order to find a 2/5 interleaved barcode (barcode tag) on it. 
> 
> Barcode itself could be also slightly rotated or poor quality. This means fristly it is required to find the barcodes characteristic at the image and process it, means make algorithm too see were it is, with a simple Neuronal Network. This Network must classify if there is a barcode, according certain parameters eg.: horizontal, vertical lines, white window with black lines, ... and mark the boundaries. 
> 
> If the NN found a barcode, a reader should evaluate selected area --> result should be displayed.
> 
> As we are complete rookies on Matlab and NN´s we are quite in trouble ....
> 
> regards,
> team 1

Well, I'm glad I'm not in your position.

We're not going to do your homework for you.  If you want any actual help on here, you need to show us what you've done, and what isn't working.  Be specific and show all error messages.  Provide us with images for a project like this.
0
Reply Sean 11/22/2010 5:17:04 PM


On Nov 22, 11:42 am, "Andreas " <andreas.salz...@knapp.com> wrote:
> Hi Guys,
>
> Please help! Following problem. We have to do a project with Neuronal Net=
works.
> We would like to process a *.jpg in order to find a 2/5 interleaved barco=
de (barcode tag) on it.
>
> Barcode itself could be also slightly rotated or poor quality. This means=
 fristly it is required to find the barcodes characteristic at the image an=
d process it, means make algorithm too see were it is, with a simple Neuron=
al Network. This Network must classify if there is a barcode, according cer=
tain parameters eg.: horizontal, vertical lines, white window with black li=
nes, ... and mark the boundaries.
>
> If the NN found a barcode, a reader should evaluate selected area --> res=
ult should be displayed.
>
> As we are complete rookies on Matlab and NN=B4s we are quite in trouble .=
....
>
> regards,
> team 1

One of the first steps in creating a regression or
classificationt neural net is to assemble a matrix
of N I-dimensional input column vectors in a matrix
p where

[I N] =3D size(p)

and assemble the corresponding matrix of O-dimensional
output column vectors in a target matrix t where

[O N] =3D size(t).

An underlying assumption is that there is a single
deterministic function that describes the trend of
the I/O relationship between columns pi and ti, i=3D1:N.

Based on the typically noisy data examples in the
(pi,ti) pairs, a neural network is to be designed
to characterize that deterministic trend function.

Another underlying assumption is that the sample
of N pairs adequately characterizes the I/O function
for unseen data obtained from the same source.

Now my question is:

What do you propose to put in the p and t matrices?

Hope this helps.

Greg
0
Reply Greg 11/23/2010 6:50:38 AM

"Andreas " <andreas.salznig@knapp.com> wrote in message <ice6gt$jga$1@fred.mathworks.com>...
> Hi Guys,
> 
> Please help! Following problem. We have to do a project with Neuronal Networks. 
> We would like to process a *.jpg in order to find a 2/5 interleaved barcode (barcode tag) on it. 
> 
> Barcode itself could be also slightly rotated or poor quality. This means fristly it is required to find the barcodes characteristic at the image and process it, means make algorithm too see were it is, with a simple Neuronal Network. This Network must classify if there is a barcode, according certain parameters eg.: horizontal, vertical lines, white window with black lines, ... and mark the boundaries. 
> 
> If the NN found a barcode, a reader should evaluate selected area --> result should be displayed.
> 
> As we are complete rookies on Matlab and NN´s we are quite in trouble ....
> 
> regards,
> team 1


Here are some inputs to be verified and explored:

1. image acquisition: Will be definitely done with the image acquisition toolbox, frames can be grabbed and directly stored in a matrix for further use! So far here are no questions?
2. image pre-processing:  The matrix of interest (image containing a barcode!) has to be deblured?/converted into greyscale?/.....to be able to use the appropriate segmentation function within the image processing toolbox. Could it be the texture segmentation using texture filters?
3. Verification: With the help of the Neural Networks Toolbox it should be possible to verify the segmented matrices whether or not it is a barcode or not. What about the use of the pattern recognition and classification (nprtool?) - but where to get the learning data from?
4. Barcode reading: This needs to be done by a solution, wihich should be able to adjust the matrix by itself (turn, read from left to right and right to left.....) but should be used from a standard library.
5. GUI to control the a.m. workflow.

So we're working on all this issues and who ever has inputs pls feel free to post here!
0
Reply Johannes 12/6/2010 8:49:04 AM

"Johannes " <weinzerl@gmail.com> wrote in message <idi820$lut$1@fred.mathworks.com>...
> "Andreas " <andreas.salznig@knapp.com> wrote in message <ice6gt$jga$1@fred.mathworks.com>...
> > Hi Guys,
> > 
> > Please help! Following problem. We have to do a project with Neuronal Networks. 
> > We would like to process a *.jpg in order to find a 2/5 interleaved barcode (barcode tag) on it. 
> > 
> > Barcode itself could be also slightly rotated or poor quality. This means fristly it is required to find the barcodes characteristic at the image and process it, means make algorithm too see were it is, with a simple Neuronal Network. This Network must classify if there is a barcode, according certain parameters eg.: horizontal, vertical lines, white window with black lines, ... and mark the boundaries. 
> > 
> > If the NN found a barcode, a reader should evaluate selected area --> result should be displayed.
> > 
> > As we are complete rookies on Matlab and NN´s we are quite in trouble ....
> > 
> > regards,
> > team 1
> 
> 
> Here are some inputs to be verified and explored:
> 
> 1. image acquisition: Will be definitely done with the image acquisition toolbox, frames can be grabbed and directly stored in a matrix for further use! So far here are no questions?
> 2. image pre-processing:  The matrix of interest (image containing a barcode!) has to be deblured?/converted into greyscale?/.....to be able to use the appropriate segmentation function within the image processing toolbox. Could it be the texture segmentation using texture filters?
> 3. Verification: With the help of the Neural Networks Toolbox it should be possible to verify the segmented matrices whether or not it is a barcode or not. What about the use of the pattern recognition and classification (nprtool?) - but where to get the learning data from?
> 4. Barcode reading: This needs to be done by a solution, wihich should be able to adjust the matrix by itself (turn, read from left to right and right to left.....) but should be used from a standard library.
> 5. GUI to control the a.m. workflow.
> 
> So we're working on all this issues and who ever has inputs pls feel free to post here!

Here's the first script to label the image, large label would contain the barcode label!
% Barcode recognition
% Code development J.Weinzerl, ATM1

% Read image from file system
img=imread('IMG_0098.jpg');
% Convert image to grayscale
im_g=rgb2gray(img);
% Convert image to binary (black&white)
umb=graythresh(im_g);
bw=im2bw(im_g,umb);
% Display image
imshow(img)
% Find all conected labels
[L Ne]=bwlabel(bw);
% Create picture property structur
propied=regionprops(L);
% Hold on to the image shown in figure
hold on
% Draw boxes around all labels
for n=1:size(propied,1)
    rectangle('Position',propied(n).BoundingBox,'EdgeColor','g','LineWidth',2)
end
% pause for a while
pause(3)
% Find all small labels 
s=find([propied.Area]<500);
% Change their color
for n=1:size(s,2)
    rectangle('Position',propied(s(n)).BoundingBox,'EdgeColor','r','LineWidth',2)
end
% Large labes could be validated by NN???
0
Reply Johannes 12/8/2010 10:52:05 AM

4 Replies
403 Views

(page loaded in 0.028 seconds)


Reply: