Code covered by the BSD License  

Highlights from
Optical Character Recognition (OCR)

4.14894

4.1 | 48 ratings Rate this file 737 Downloads (last 30 days) File Size: 95.6 KB File ID: #18169
image thumbnail

Optical Character Recognition (OCR)

by

 

31 Dec 2007 (Updated )

The aim of OCR is to classify optical patterns corresponding to alphanumeric or other characters.

| Watch this File

File Information
Description

The aim of Optical Character Recognition (OCR) is to classify optical patterns (often contained in a digital image) corresponding to alphanumeric or other characters. The process of OCR involves several steps including segmentation, feature extraction, and classification. This program use Image Processing Toolbox to get it.
For more information, visit: http://www.matpic.com (spanish).

Acknowledgements

This file inspired Optical Character Recognition(Lower Case And Space Included).

Required Products Image Processing Toolbox
MATLAB release MATLAB 7.1.0 (R14SP3)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (83)
18 Oct 2014 amandeep  
26 Aug 2014 alex yang

Very simple but powerful idea.
Thx..

08 Aug 2014 student s

from where can i download this code. I am under character recognition. Please help me for getting the code

27 May 2014 Lutful  
12 May 2014 omveer

please from where i get source cod?

21 Apr 2014 QUANG HUY

Please let me know, how can use this OCR with SVM. Thank a lot!

24 Feb 2014 hussein Ali

Good working

24 Jan 2014 sad

good

25 Jul 2013 Angie  
07 Apr 2013 Wej

Anyone can help, How to run this code ?

27 Mar 2013 Chandra Shekhar

Nice work.

21 Jan 2013 msp

sir it is not able to detect the text from video frame. please help

30 Dec 2012 thebohr

excuse me for all people,i'm newbie about this..i am a student of computer science departmen and i have an interest of making OCR buat read the character or text from hand writing. for example, i write something on the paper and convert it to digital..is it possible ?
thanks before

04 Dec 2012 Latte  
29 Oct 2012 samira

Hola diego, tengo una pregunta estoy tratando de hacer un algoritmo que me reconozca las letras usando redes neuronales con una interfaz grafica, pero el manuscrito de prueba lo tengo que cargar, queria saber si habia alguna manera de crear un recuadro sobre el GUI que sea como "paint" y se pueda dibujar la letra directamente ahi con el mouse

20 Oct 2012 shweta

hav used this image and getting errors

http://i275.photobucket.com/albums/jj286/onedrunkirishman/RagTagBanner6.jpg

17 Oct 2012 tiago  
11 Sep 2012 sriharsha ponnathapura

Nice code. I used it to generate the templates for 187 fonts in english. I dont know where to upload it for everyone to use..

12 Jul 2012 OCR_try

nice code...

12 Jun 2012 imran  
12 Jun 2012 imran

Sir its a nice code. i am getting little problem with understanding of this code. can you let me know how did you create the template.mat file from the letters. my is the same i also want to extend this code for lower case letters and local languages. one other thing is that when i replace
sem=corr2(templates{1,n},imagn); in read_letter.m to directly read the letters images and compare or find the correlation. but it does not gives the accurate results. if you read please must reply me.

31 May 2012 Shavi

Can anybody tell me that how to understand this code for character recognition?
or what is the way
please help.
Its Urgent!!

09 May 2012 Wyfi Mcfly

maximum rather

09 May 2012 Wyfi Mcfly

nicely done. for more robust results i found preforming a skeletal reduction of the input image text (when properly prepared), and making a template of skeletal comparisons for the correlation coefficient calculation can get around most font issues.
The next thing is properly aligning the input letter to that of the template. This can be accomplished in many ways, or you can simply preform an image rotation of all 360 degrees at take the minimum confidence coefficient of that process.

03 May 2012 Shavi

Hello Diego...
Cheers for ur code..
I want to know that how to recognize special characters like +,/,| etc..??
Also your code is not applicable for lowercase letters so please give me some information that how to tackle this.

Thanks!!

14 Feb 2012 Pon Selvalingam

Hello sir
It is perfect code, really thanks
Please send this project pdf

01 Feb 2012 sidharth jhawar

hello sir,the code works well for majority of the images..perhaps doesnt work for joined text.sir,if u cud plz send a text file describing the objective if all the four .m files??

23 Dec 2011 pankaj Durve

i use matlab 6.5,wheh i run oCR project,then templates loading error is come.why error is come?how to error is removed?

21 Dec 2011 kolayuyelik kolay

Quite good!

03 Dec 2011 sanjana

plz anyone can give me the logic behind this program....on wht basis feature extraction has been done...nd hw Image proceesing tool box is used for simulatin...plz help me out asap....

08 Oct 2011 Mr Smart  
04 Jul 2011 Fabio Bento

Quite good!

29 Jun 2011 Popescu

Hello! Did any one succeeded to add some new character templates? I am trying to add the OCR-B font templates but I don't know how to do it. I tried in photoshop but it didn't work. Does anyone know if is there a special program to do it?

08 Jun 2011 Fukuo

Thx!
It helps me so much!

22 Apr 2011 Lamis zaki

Really good job , you helped me out :) thnx

21 Apr 2011 Sadegh

It is perfect code, really thanks

18 Apr 2011 King Lee

Hi, im planning to improve your code to be able to recognize about the small cases alphabet also,but i cannot access the thumb.db files in the letter number's folder...
Can you tell me it need what to open?

19 Feb 2011 SURYA

sir, nice your OCR project...i also using your code for my character recognition for my project...but i code some error because of edge of image...can sir look my project and suggest a solution...i need ur help sir..tq

here is my project

http://www.filehosting.org/file/details/203684/my_project.rar

05 Jan 2011 vipin vc

good program
Dear Bogdan

Suppose that we have an image with two lines of text. With "clip", only obtain one line and leave the rest.

19 Dec 2010 Khaing Thaw

Hi Hannah,
these images of letters are in the letters_numbers folder. there are 36 image file, if u also want to recognize lower case letters u can add lower letter image files into that folder. and need to edit and add some coding in .m file in OCR folder.
clip is not built-in function, it is a sub function use in line.m function to crop the lines, u can see it lower part of line.m function.
good luck,
thaw

19 Dec 2010 Claus Becker  
08 Dec 2010 Hannah Whitby

Hi Diego and everyone,
Good program, but I have a few questions:
Where/how did you make these images of the letters that are in the template? I need to be able to identify lower case letters as well as upper case and have tried just using microsoft paint but although they are .bmp the appear the wrong format. Any ideas anyone?
Also - what is 'clip'? my matlab doesn't seem to support it but when i changed it to imcrop it stalls.
Thanks,
Hannah

05 Dec 2010 Khaing Thaw

Hi Diego, Nice ur coding, complete in a few lines, functions, templates ,... except clip function :P

Hi Ashley, to find the spaces calculate the spacing of components in image Labeled,. it is my suggestion, how Diego?

Hi Priyanka, add some coding in create_templates.m and image files (BMP, 42x24) for lower characters,.

Thanks Diego,.

12 Oct 2010 Ashley Figer

Dear sir,
how do we detect blank spaces between the characters?
and print them in the output

04 Oct 2010 Theodoros Giannakopoulos  
29 Aug 2010 pupu QQ

not very good for car plate in China.

31 Jul 2010 mrudula sekhar

hi sir, ur work is really good.
i am too trying to implement the same as a part of my academics, so like to know more about the subject. can u please help me ?
i did like to know about the different steps involved in character recognition. can u provide me with some pdf documents which i can depend to complete my project.

12 Jul 2010 Alexandru

Problem solved. The problem was the performance of my PC.

Thanks again for the program

12 Jul 2010 Alexandru

hello,

i use Matlab 7.9.0 (R2009b) and i received an error "Segmentation violation detected" while i tried to run the OCR program. i'm beginner in matlab so can anyone help me please?

PS: thank you Diego for the OCR program

11 Jul 2010 uet taxila  
08 Jul 2010 Eurico

Hi Mr. Diego,
at the moment i'm developing a computer vision system to detect and recognize license plates.I experienced your project and works very well but i have a question. What method are you using to do the recognition? SVM's? Neural Networks?

kind regards

16 Jun 2010 Priyanka M

Hi Diego..
dis is priyanka,from India
It was a very nice job.Can u plz help me with dis project..???
Plz tell me how to recognize lower case letters..?? and also plz help me with how to obtain the bitmap images of the letters u place in letters_numbers folder so dat I can try for the regional languages...
Plz plz plz do reply me....

11 Jun 2010 Diego Barragán

Dear Bogdan

Suppose that we have an image with two lines of text. With "clip", only obtain one line and leave the rest.

Kind regards.

10 Jun 2010 blue

Thank you for answare, but I have a nother question : in lines.m file exist next line:
im_texto=clip(im_texto);
What exactly make cilp in this expresion?

10 Jun 2010 Diego Barragán

Hello Bogdan

I use IMCROP instead CLIP.

Kind regards.

10 Jun 2010 blue

I hava a question for Mr Diego Barragán.
In the Zip file I cannt find the function clip, but On this page link http://www.matpic.com/MATLAB/MATLAB_OPTICAL_CHARACTER_RECOGNITION.html, exist!!!! Where is integrate this function?

25 Apr 2010 vaibhav sharma

Please can anyone tell me how to implement this code on fpga??
Its urgent....mail me at varun.rampal@yahoo.com

thank you very much

23 Mar 2010 nurul

dear sir,
it was a very nice job. however for certain pics it cant read the image correctly. do u have any idea on how to add the image filtering codes to make this program read the image more accurate?
i really need ur help on this matter.

23 Mar 2010 nurul  
17 Mar 2010 Thabit

Sid H, come on!

If you can do better, we are waiting!

31 Jan 2010 Sid H

Amateur work, both code and concepts. Not robust. Cant support fonts, noise or files different from what the up-loader provides. But great as a concepts demo for undergrad-and-below classes.

19 Dec 2009 chaogui xia

thank you

11 Dec 2009 Hooman

Very nice job, I have 2 questions the code ignores white space which should not and also it does not detect lowercase letters.
how should we detect white spaces between words?

03 Nov 2009 Cong Zhou

good job!

03 Nov 2009 Cong Zhou  
10 Sep 2009 karthik sarma

this program is not working for other image files. i created some image files using paint in ariel and times new roman font. the program failed to give correct result

07 Aug 2009 yusor

Anybody can help me? My FYP is about converting an image to text. Image may be frim newpaper (anywhere) and should be converted into text and saved into Doc. or pdf but it must retain the oiginal format.

Thank u,
Yusser

25 Mar 2009 Rushmi

It works great.But for images with dots or small patches the result is ambiguous.If the code can eliminate this problem,(not recognizing non characters) it will be a good algorithm for character recognition.

05 Dec 2008 athi rayan

hello sir please give me as a compltet report in ocr

09 Sep 2008 ved vrath

cz

20 May 2008 firas aakroum

?????

14 Apr 2008 manish arora

these files really works..
result not being 100%..

08 Apr 2008 minnal sagi

fine

04 Apr 2008 Bilal KONUK

hi author
i am using matlab 6.5 version. Can i work your project my matlab?

20 Mar 2008 eklil alwrd  
19 Mar 2008 Paul Paul  
05 Mar 2008 raghav khanna

can u tell me wat feature algorithm r u using??

01 Mar 2008 Tran Dinh Vuong

Dear Sir, I'm doing handwritten english character recognition.Please guide me to progress this project. thanks lot.

26 Feb 2008 Pradeep Mapitigama

Dear Sir,
I'm doing handwritten english character recognition.Please guide me to progress this project.I'm doing this for fullfill the MSc.in computer science.
thanks lot.

16 Jan 2008 Vihang Patil

Nice work. Tried creating my own images of numbers and names alike and found sometimes some letters being wrongly identified, especially I, 1, O,0,Q
Other than that nice work!

08 Jan 2008 John Smith

Good application

07 Jan 2008 Diego Barragán

Hi, this is Diego Barragán, from Ecuador.

I appreciate your comments about OCR.

The error perhaps is due the version of MATLAB. I use version 7.1.0.246 (R14) Service Pack 3.

And other restriction of OCR is the size of letter. The size must be bigger or equal to 42 x 24 pixels.

Regards.

07 Jan 2008 Austin K

this is a very good work.
a very good logic and simple to understand .
yet there are lot of sectors which can improve.
and i dont know why it happens is that there is a error while loading the templates.
always shows that the file was corrupted.
any way best wishes and once again good work.

Updates
02 Jan 2008

Update

03 Jan 2008

update

23 Jun 2008

update

09 Feb 2009

update

07 Aug 2014

Update.

08 Aug 2014

uupdate

08 Aug 2014

update

Contact us