language emulator
TRANSCRIPT
-
8/13/2019 Language Emulator
1/39
Language EmulatorFinal Year Project Report
IndexPage
Chapter 1: Introduction................................................................................ 5
1.1 Abstract......... 6
1.2 Advantages & Applications ... 7
Chapter 2: Design Modules.. 8
2.1 ver vie!.. . 9
2.2 Re"uest Acceptance 11
2.2.1 #$R% '(. 12
2.2.2 )lue *ove
.... 122.3 *+aracter Recognition
.. 15
2.3.1 ImagePreprocessing........ 15
-
8/13/2019 Language Emulator
2/39
2.3.2 $egmentation............... 20
2.3.3 Recognition 23
2.3.3.1 ,istogram Extraction 23
2.3.3.2 Feature Point Extraction. 2
2. Language -ranslation.. 28
2.5 Response eliver/
.. 29Chapter 3: !esults.. 30
3.1 $naps+ots.. 31
3.2 *onclusion.. 35
3.3 Furt+er Improvement.. 37
3. Re0erences. 38
*+apter 1
-
8/13/2019 Language Emulator
3/39
Introduction
-
8/13/2019 Language Emulator
4/39
1.1 Abstract
-ourism pla/s an important role in modern !orld. It contributes a lot tot+e national revenue. -ourists 0ace a perpetual problem o0understanding t+e local languages !+erever t+e/ go. And in Europe allt+e sign boards are !ritten in local languages li2e in 3erman/ t+e/ are!ritten in 3erman etc.
ur project is intended to +elp tourist understand !+at +as been
!ritten on sign boards. -+e project uses t+e primar/ gadget ever/tourist carries t+at is +is mobile p+one. A p+oto ta2en 0rom t+e mobilep+one is needed to be sent to t+e server and server does t+e c+aracterrecognition4 language translation and sends t+e customer t+etranslated text via $5$.
ur project mainl/ is divided into 6 modules.
1. Re"uest Acceptance(. *+aracter Recognition
7. Language -ranslation
6. Response eliver/
In Re"uest Acceptance module t+e re"uest 0rom t+e customer is
ac2no!ledged i.e. t+e image is received 0rom t+e client8s mobilep+one. In *+aracter Recognition module t+e c+aracters are extracted0rom t+e given image. In Language -ranslation t+e extracted string isconverted into Englis+ language. In Response eliver/ t+e text is sentbac2 to t+e client8s mobile via $5$.
9e +ave success0ull/ implemented algorit+ms 0or c+aractersegmentation4 c+aracter recognition4 and 0eature extraction. 9e +ave
-
8/13/2019 Language Emulator
5/39
success0ull/ created application 0or connectivit/ bet!een P* serverand 5obile *lient.
:ote; 9e +ave basicall/ translated a 3erman language into Englis+.
1.2 Advantages & Applications
-+e 0ore most advantage o0 our project is t+at customer need not bu/an/ additional gadgets to avail t+is service. It can be readil/ usedusing a p+one !it+ a built%in camera.
-+e advantages o0 our project are as 0ollo!s;
1. *ost E00ective.
(. :o additional gadget necessar/.
7.
-
8/13/2019 Language Emulator
6/39
*+apter (
Design Modules
-
8/13/2019 Language Emulator
7/39
2.1 ver vie!
iagrammaticall/ our project can be put as 0ollo!s;
-
8/13/2019 Language Emulator
8/39
Flo! iagram
*lient 5obile5I let
$upporting #$R%'(
$erver !it+)luetoot+ =sing
)lue *ove
9aiting 0or *lients
*+aracter Recognitionusing jt *R
Image is convertedinto computerreadable text.
Language -ranslation
3erman -ext is convertedto Englis+ -ext.
Image
$5$
Image
3erman -ext
Englis+ -ext
-
8/13/2019 Language Emulator
9/39
2.2 Re"uest Acceptance
In t+is module mobile act as a *lient and a standalone P* acts as a$erver. 9e +ave created a 5I let 0or t+e *lient8s mobile. 9e +aveimplemented bot+ programs using #$R% '( API.
-+roug+ t+is 5I let *lient can detect t+e $erver b/ per0orming a)luetoot+ device en"uir/. A0ter t+e $erver is detected all t+e servicesavailable on t+e services are displa/ed in t+e 5obile. As t+e re"uiredservice is selected mobile8s camera !ill be automaticall/ s!itc+ed on.*lient can t+en ta2e an image o0 t+e +oarding. As soon as t+e image is
ta2en it is passed on to t+e $erver.
9e implemented t+is module using )lue *ove4 a )luetoot+ librar/.
Firstl/ I !ant to introduce !+at is #$R% '( & )lue *ove.
-
8/13/2019 Language Emulator
10/39
2.2.1 "#!$082
-+e #$R%'( is t+e o00icial #ava API 0or )luetoot+ !ireless tec+nolog/.=sing t+is API /ou can create applications t+at per0orm an/ o0 t+e0ollo!ing 0unctions;
1. etermine and inspect t+e properties o0 /our o!n )luetoot+device
(. iscover )luetoot+ devices !it+in t+e communication range o0/our device
7. $earc+ 0or services on remote )luetoot+ devices6. *reate )luetoot+ client applications t+at can communicate !it+
remote )luetoot+ servers
>. *reate )luetoot+ server applications t+at can service re"uests0rom )luetoot+ clients
-+e #$R%'( consists o0 t!o pac2ages4 javax.bluetoot+ and javax.obex. Your o!n )luetoot+ device is represented b/ t+e javax.bluetoot+.Local evice class and all remote )luetoot+ devices arerepresented b/ t+e javax.bluetoot+.Remote evice class.
2.2.2 %lue Co&e
)lue *ove is a #$R%'( #($E implementation t+at currentl/ inter0aces!it+ t+e 5ac $ ?4 9I * 554 )lue$oleil and 5icroso0t )luetoot+ stac20ound in 9indo!s ?P $P( and ne!er. riginall/ developed b/ IntelResearc+ and currentl/ maintained b/ volunteers.
)lue *ove runs on an/ #
-
8/13/2019 Language Emulator
11/39
-+e bottom la/er o0 t+e stac2 is t+e ,*I4 t+e ,ost *ontroller Inter0ace.
-+is la/er is literall/ t+e inter0ace bet!een t+e +ost @/our computerand t+e controller @t+e )luetoot+ device . As /ou can see4 all ot+erla/ers go t+roug+ t+e ,*I.
-+e la/er above t+e ,*I is L(*AP4 t+e Logical Lin2 *ontrollerAdaptation Protocol. -+is la/er acts as t+e data multiplexer 0or all ot+erla/ers.
-
8/13/2019 Language Emulator
12/39
-+e next la/er is ):EP4 t+e )luetoot+ :et!or2 Encapsulation Protocol.=sing ):EP4 /ou can run ot+er net!or2ing protocols4 suc+ as IP4 -*P4and = P4 over )luetoot+.
RF* 55 is 2no!n as t+e virtual serial port protocol because it allo!s a)luetoot+ device to simulate t+e 0unctions o0 a serial port.
-+e )E? protocol la/er is implemented above t+e RF* 55 la/er andis use0ul !+en /ou !ant to trans0er data as an object4 suc+ as 0iles.
$ P is t+e $ervice iscover/ Protocol la/er4 !+ic+ is used !+enever/ou !ant to 0ind services on a remote )luetoot+ device.
-+e 0inal t!o la/ers4 A
-
8/13/2019 Language Emulator
13/39
-
8/13/2019 Language Emulator
14/39
Points to Consider:
1. As !e +ave to process t+e !+ole image pixel b/ pixel it ispre0erable to resiDe t+e picture into a lo!er resolution o0 around7 x7 . -+is !ill +elp process 0aster.
(. As t+e received image !ill be o0 #PE3 extension4 it !ill be +aving
7 bands Red4 )lue4 3reen. 9e +ave to convert into a 3ra/ $caleimage !+ic+ is o0 a single band.
7. -o process an image it is better to +ave an image single bit perpixel instead 1 or 7( bit per pixel. $o t+e image is convertedinto a single band and single bit per pixel.
6. -+e c+aracters in t+e image +ave a varied t+ic2ness. $o todecrease t+e error probabilit/ !e !ill t+in t+e image using+ang$uen Algorit+m !+ic+ !ill leave t+e c+aracter !it+ a singlepixel t+ic2ness. :o! t+e image is read/ 0or text extraction.
:o! !e !ill ta2e one b/ one point in detail. Processing an image in java uses #AI @#ava Advanced Imaging API. 5oving 0urt+er4 a smallintroduction o0 #AI API8s 0undamentals.
-
8/13/2019 Language Emulator
15/39
JAI (Java Advanced Imaging)[6]
-+e #ava language advantages are its lo! cost4 licensing independenceand inter%plat0orm portabilit/. -+e #AI API advantages are its 0lexibilit/and variet/ o0 image processing operators. Image processingalgorit+ms usuall/ re"uire t+e manipulation o0 t+e image data @pixels .
ne example o0 a #AI operator is t+e G0ilestoreH operator used in t+e
code in t+e listings 1 and ( to store an instance o0 PlanarImage @or o0 asubclass o0 it in a 0ile. -+e call 0or t+e #AI.create met+od used asarguments t+e name o0 t+e operator4 t+e instance o0 PlanarImage4 a0ile name and a string containing t+e desired image 0ile name @G-IFFH4G#PE3H4 GP:3H4 etc. . Anot+er example o0 operator4 !+ic+ does not uset+e instance o0 Parameter)loc24 a call to #AI.create @ 0ileload4image:ame B !ill load and return an image !+ic+ 0ile name4 iscontained on t+e string image:ame. t+er operators and codesnippets t+at illustrate its usage !ill be s+o!n in t+is section. A list o0
all operators can be 0ound on t+e #AI API documentation J K4 on t+edocumentation 0or t+e pac2age javax.media.jai.operator.
)and manipulation operator is t+e GbandcombineH operator4 !+ic+uses several image bands to combine t+em into a single multibandimage. -+is met+od could be used to create a R3) image 0rom t+reeseparate red4 green and blue images4 0or example.
$ome ot+er simple operators are GaddH4 GsubtractH4 G5ultipl/H andGdivideH4 !+ic+ per0orms basic arit+metic operations on t!o images4giving a t+ird as result. -+e code snipped s+o!n in listing 11 s+o!s+o! t!o images @!+ic+ are presumabl/ alread/ created or read 0rom0iles can be added4 subtracted4 multiplied or divided depending on!+ic+ button on an user inter0ace !as clic2ed.
-
8/13/2019 Language Emulator
16/39
hinning /8 :$
In t+inning t+ere are 7 to 6 algorit+ms available.
1. +ang%$uen -+inning Algorit+m
(. ,ilditc+8s -+inning Algorit+m
7. A. Rosen0eld & A. a2
)ut among all t+e t+ree algorit+ms4 +ang%$uen Algorit+ms is beingimplemented b/ us. As ,ilditc+8s Algorit+m doesn8t prove to beappropriate 0or patterns !it+ s+arp edges and A. Rosen0eld Algorit+m
is not a 0ast one to implement. 9+ereas +ang%$uen -+inningAlgorit+m is a 0ast parallel algorit+m 0or t+inning digital patterns orbinar/ images.
Zhang-Suen Thinning A gorithm
-+is algorit+m !or2s on '%connected pixel !indo!.
P1 is t+e pixel under consideration. And surrounding pixelsare addressed in cloc2!ise manner. )e0ore going to t+ealgorit+m t+ere are some basics to be pondered on.
In t+is algorit+m;
p1 is no o0 non Dero neig+bors o0 p1.
# p1 is no o0 %1 transitions in t+e neig+bors in t+e se"uence p(%p7%
p6%p>%p %pM%p'%pN%p(.
-
8/13/2019 Language Emulator
17/39
-+e algorit+m is to continue t+e 0ollo!ing steps until t+e image is nomore le0t to be t+inned.
A. Flag all t+e contour points !+ic+ satis0/ conditions 1 to 6
). elete all t+e 0lagged points.
*. Flag all t+e contour points !+ic+ satis0/ conditions > to '
. elete all t+e 0lagged points.
Conditions
1. (O :@p1 O
(. $@p1 1
7. p( Q p6 Q p
6. p6 Q p Q p'
>. (O :@p1 O
. $@p1 1
M. P( Q p6 Q p'
'. P( Q p Q p'
a First Pass
b $econdPass
c FinalImage
-
8/13/2019 Language Emulator
18/39
2.3.2 #eg+entation
From t+e gra/ scale image !e +ave to extract individual c+aracters.For doing t+e same !e +ave to 0irst divide t+e image into regions usingRegion 3ro!ing Algorit+m. And t+en !e +ave to move individualregions into separate images so +as to obtain images o0 individualc+aracters seriall/.
-+is is done in 0ollo!ing !a/;
1. First appl/ Region 3ro!ing Algorit+m to t+e image so t+at !e getpixels grouped into separate regions.
(. -+en separate out individual regions and save t+em in ne! 0iles.
!egion "ro#ing A gorithm
-+e goal o0 segmentation is to partition a digital image or curve intosegments suc+ t+at t+e points in eac+ segment s+are a commonpropert/. For example4 !e can partition a curve into connected subsetssuc+ t+at t+e points o0 eac+ subset lie on a common straig+t line4 or!e can partition an image suc+ t+at intensit/ 0unction is linearl/var/ing !+en restricted to one part. A region gro!ing algorit+m starts0rom a small seed segment4 and t+en repeatedl/ tries to add ne!points to t+is segment. Eac+ time a point is added4 t+e algorit+mveri0ies !+et+er t+e segmentation criterion is still satis0ied 0or t+eenlarged segment4 ot+er!ise a ne! segment is started. In general4 t+everi0ication o0 t+e segmentation criterion becomes increasingl/ moredi00icult !+en t+e segment gets larger. 9e propose ne! linear%timealgorit+ms 0or region gro!ing. -+ese algorit+ms are related to t+eeconomical design o0 mec+anical 0rame!or2s4 !+ere t+e goal is toma2e a rigid construction !it+ as 0e! bars as possible. According tot+is analog/4 t+e region gro!ing algorit+m tries to attac+ eac+ ne!point as 0irml/ as possible to t+e existing region !it+ a minimalamount o0 computation.
-
8/13/2019 Language Emulator
19/39
-
8/13/2019 Language Emulator
20/39
-+e Algorit+m goes t+is !a/;
1. $elect an/ pixel 0rom t+e image called t+e seed pixel. Assign aregion number to it.
(. 5ove to ot+er pixel. I0 t+e pixel properties matc+ !it+ t+e seedpixel t+en assign t+e same Region :umber.
7. I0 t+e pixel properties don8t matc+ !it+ t+e seed pixel t+en sett+e ne! pixel as seed pixel and assign it a ne! Region :umber.
6. *ontinue t+e procedure until eac+ and ever/ pixel is assigned aRegion :umber.
Se$arating !egions
:o! !e +ave image grouped out into regions. 9e !ill no! separateeac+ region b/ doing 0ollo!ing steps;
For eac+ region
For eac+ pixel
*ompute t+e 5inimum ?8 coordinate.*ompute t+e 5inimum Y8 coordinate.
*ompute t+e 5aximum ?8 coordinate.
*ompute t+e 5aximum Y8 coordinate.
S
S
For :umber o0 Regions
*reate $ub%image 0rom t+e 5ain%image 0rom
5in ?4 5in Y4 5ax ?4 5ax Y.
$ave t+is sub%image into :e! File using #AI.
S
-
8/13/2019 Language Emulator
21/39
S
-
8/13/2019 Language Emulator
22/39
2.3.3 !ecognition
-+ere are 0e! !a/s to per0orm c+aracter recognition. :eural :et!or2is an e00icient and 0ast !a/. )ut !e +ave implemented recognition int!o p+ases;
1. Histogram extraction
(. Feature point extraction
2.3.3.1 Histogram extraction
)e0ore doing t+e Feature extraction !e narro! t+e total comparisonsb/ comparing ,istograms o0 t+e image received.
9e ta2e +istogram o0 t+e received image 0rom 7 angles. ,oriDontal4vertical and diagonal.
*ompare it !it+ t+e +istograms o0 c+aracter set alread/ stored. -+is!ill leave us !it+ a less number o0 c+aracters to be compared inFeature Extraction P+ase.
-
8/13/2019 Language Emulator
23/39
2.3.3.1
2.3.3.2 Feature Point Extraction
%$tica character recognition (%C!) +as been a topic o0 interest sincepossibl/ t+e late 1N6 Cs !+en #acob Rabino! started +is !or2 in t+e
0ield 1 . -+e earliest *R mac+ines !ere primitive mec+anical devices!it+ 0airl/ +ig+ 0ailure rates. As t+e amount o0 ne! !ritten materialincreased4 so did t+e need to process it all in a 0ast and reliablemanner4 and t+ese mac+ines !ere clearl/ not up to t+e tas2. -+e/"uic2l/ gave !a/ to computer%based *R devices t+at couldoutper0orm t+em bot+ in terms o0 speed and reliabilit/.
-oda/ t+ere are man/ *R devices in use based on a plet+ora o0di00erent algorit+ms. All o0 t+e popular algorit+ms sport +ig+ accurac/
and most +ig+ speed4 but still man/ su00er 0rom a 0airl/ simple 0la!;!+en t+e/ do ma2e mista2es @and t+e/ all do 4 t+e mista2es are o0tenver/ unnatural to t+e +uman point o0 vie!. -+at is4 mista2ing a > 0oran $ is not too surprising because most people are !illing to agreet+at t+ese t!o c+aracters are similar4 but mista2ing a > 0or an 5 iscounter%intuitive and unexpected. Algorit+ms ma2e suc+ mista2esbecause t+e/ generall/ operate on a di00erent set o0 0eatures t+an+umans 0or computational reasons. ,umans observe stro2es and t+erelations bet!een t+em4 !+ile algorit+ms measure an/t+ing 0rom
-rans0ormation Ring Projections ( o0 a c+aracter to t+e Fourier -rans0orm o0 t+e ,oriDontal%ave is easier to connect !it+ $ave t+an 5ave .
-+is project describes an algorit+m t+at attempts to !or2 !it+ a subseto0 t+e 0eatures in a c+aracter t+at a +uman !ould t/picall/ see 0or t+eidenti0ication o0 mac+ine%printed Englis+ c+aracters. Its recognitionrate is currentl/ not as +ig+ as t+e recognition rates o0 t+e older4 moredeveloped c+aracter recognition algorit+ms4 but it is expected t+at i0 it
http://www.ccs.neu.edu/home/feneric/charrec.html#danasawyerhttp://www.ccs.neu.edu/home/feneric/charrec.html#danasawyer -
8/13/2019 Language Emulator
24/39
!ere expanded to !or2 !it+ a larger set o0 0eatures t+is problem !ouldbe removed. I0 it !ere expanded to use more 0eatures4 it !ould bemade correspondingl/ slo!erB !it+ t+e advent o0 0astermicroprocessors t+is 0act is not vie!ed as a crippling problem.
-+e c+aracters in most 9estern c+aracter sets can com0ortabl/ bedescribed using onl/ an eig+t b/ eig+t grid. $ince t+e 0ocus o0 t+isalgorit+m is currentl/ just mac+ine printed Englis+ c+aracters t+ealgorit+m !as designed to +andle eig+t b/ eig+t data. It s+ould not beimpossible to use t+is algorit+m on c+aracters !it+ +ig+er resolution4but some met+od o0 data reduction !ould +ave to be applied to t+era! data 0irst. A bloc2 reduction met+od s+ould produce acceptableresults 0or most mac+ine printed data4 but t+ere is no reason t+at agood t+inning algorit+m 6 could not do just as !ell provided t+at t+einput needs o0 t+is algorit+m are properl/ understood.
-+e algorit+m presentl/ avoids t+inning @and ot+er preprocessing b/assuming t+at t+e input eig+t b/ eig+t data is not particularl/ aberrant%% lines in an eig+t b/ eig+t grid s+ould not normall/ be t+ic2er t+ant!o pixels. 9it+ t+is assumption4 it t+en proceeds to loo2 0or 0eaturepoints.
Definition:
A 0eature point is a point o0 +uman interest in an image4 a place !+eresomet+ing +appens. It could be an intersection bet!een t!o lines4 or itcould be a corner4 or it could be just a dot surrounded b/ space. $uc+points serve to +elp de0ine t+e relations+ip bet!een di00erent stro2es.
-!o stro2es could 0ull/ cross eac+ ot+er4 come toget+er in a Y or a- intersection4 0orm a corner4 or avoid eac+ ot+er altoget+er. Peopletend to be sensitive to t+ese relations+ipsB t+e 0act t+at t+e lines in a
connect in a certain !a/ is more important t+an t+e individuallengt+s o0 t+ose lines. -+ese relations+ips are !+at s+ould be used 0or
c+aracter identi0ication4 and t+e 0eature points can be exploited 0or t+etas2.
-+e procedure 0or extracting t+ese 0eature points utiliDed b/ t+isalgorit+m is 0airl/ straig+t0or!ard. $ince an eig+t b/ eig+t c+aracterconsists o0 onl/ sixt/%0our pixels4 it is viable to simpl/ loop t+roug+ t+eentire c+aracter and examine eac+ pixel in turn. I0 a pixel is on4 itseig+t neig+bors are c+ec2ed. $ince eac+ neig+bor can also onl/ be on
-
8/13/2019 Language Emulator
25/39
or o004 t+ere are merel/ (> possible combinations o0 neig+bor+oods.0 t+ese (> 4 0i0t/%eig+t !ere 0ound to represent signi0icant 0eaturepoints in a 0airl/ unambiguous !a/. Extracting 0eature points t+usreduced to calculating a number bet!een Dero and (> to describe apixelCs neig+bor+ood and t+en comparing t+at number against a table
o0 2no!n 0eature points @see -able 14 Enumeration o0 Possible Pixel:eig+bor+oods4 . 9+ile it is true t+at t+is met+od does not al!a/scatc+ ever/ 0eature point @some can onl/ be seen in a larger context itcatc+es t+e majorit/. 5issing 0eature points is certainl/ not a limiting0actor in t+e algorit+mCs accurac/. It also does not su00er 0rom labelingtoo man/ uninteresting points as being 0eature points. It +as virtuall/no 0alse positives. -+e 0eature point extractor is t+us 0ast and reliable.
+ +
*
+
*
+
**
*+ *+
*
*+
*
*+
**
*
+
*
+
*
*
+
*
*
+
**
*
*+
*
*+
*
*
*+
*
*
*+
**
0 16 32 48 64 80 96 112 128 144 160 176 192 208 224 240
*
+
*
+
*
*
+
*
*
+
**
*
*+
*
*+
*
*
*+
*
*
*+
**
**
+
**
+
*
**
+
*
**
+
**
**
*+
**
*+
*
**
*+
*
**
*+
**
1 17 33 49 65 81 97 113 129 145 161 177 193 209 225 241
*
+
*
+
*
*
+
*
*
+
**
*
*+
*
*+
*
*
*+
*
*
*+
**
* *
+
* *
+
*
* *
+
*
* *
+
**
* *
*+
* *
*+
*
* *
*+
*
* *
*+
**
2 18 34 50 66 82 98 114 130 146 162 178 194 210 226 242 **
+
**
+
*
**
+
*
**
+
**
**
*+
**
*+
*
**
*+
*
**
*+
**
***
+
***
+
*
***
+
*
***
+
**
***
*+
***
*+
*
***
*+
*
***
*+
**
3 19 35 51 67 83 99 115 131 147 163 179 195 211 227 243
+*
+*
*
+*
*
+*
**
*+*
*+*
*
*+*
*
*+*
**
*
+*
*
+*
*
*
+*
*
*
+*
**
*
*+*
*
*+*
*
*
*+*
*
*
*+*
**
4 20 36 52 68 84 100 116 132 148 164 180 196 212 228 244
*
+*
*
+*
*
*
+*
*
*
+*
**
*
*+*
*
*+*
*
*
*+*
*
*
*+*
**
**
+*
**
+*
*
**
+*
*
**
+*
**
**
*+*
**
*+*
*
**
*+*
*
**
*+*
**
5 21 37 53 69 85 101 117 133 149 165 181 197 213 229 245
*
+*
*
+*
*
*
+*
*
*
+*
**
*
*+*
*
*+*
*
*
*+*
*
*
*+*
**
* *
+*
* *
+*
*
* *
+*
*
* *
+*
**
* *
*+*
* *
*+*
*
* *
*+*
*
* *
*+*
**
6 22 38 54 70 86 102 118 134 150 166 182 198 214 230 246
**
+*
**
+*
*
**
+*
*
**
+*
**
**
*+*
**
*+*
*
**
*+*
*
**
*+*
**
***
+*
***
+*
*
***
+*
*
***
+*
**
***
*+*
***
*+*
*
***
*+*
*
***
*+*
**
-
8/13/2019 Language Emulator
26/39
7 23 39 55 71 87 103 119 135 151 167 183 199 215 231 247
+
*
+
**
+
* *
+
***
*+
*
*+
**
*+
* *
*+
***
*
+
*
*
+
**
*
+
* *
*
+
***
*
*+
*
*
*+
**
*
*+
* *
*
*+
***
8 24 40 56 72 88 104 120 136 152 168 184 200 216 232 248
*
+
*
*
+
**
*
+
* *
*
+
***
*
*+
*
*
*+
**
*
*+
* *
*
*+
***
**
+
*
**
+
**
**
+
* *
**
+
***
**
*+
*
**
*+
**
**
*+
* *
**
*+
***
9 25 41 57 73 89 105 121 137 153 169 185 201 217 233 249
*
+
*
*
+
**
*
+
* *
*
+
***
*
*+
*
*
*+
**
*
*+
* *
*
*+
***
* *
+
*
* *
+
**
* *
+
* *
* *
+
***
* *
*+
*
* *
*+
**
* *
*+
* *
* *
*+
***
10 26 42 58 74 90 106 122 138 154 170 186 202 218 234 250
**
+
*
**
+
**
**
+
* *
**
+
***
**
*+
*
**
*+
**
**
*+
* *
**
*+
***
***
+
*
***
+
**
***
+
* *
***
+
***
***
*+
*
***
*+
**
***
*+
* *
***
*+
***
11 27 43 59 75 91 107 123 139 155 171 187 203 219 235 251
+*
*
+*
**
+*
* *
+*
***
*+*
*
*+*
**
*+*
* *
*+*
***
*
+*
*
*
+*
**
*
+*
* *
*
+*
***
*
*+*
*
*
*+*
**
*
*+*
* *
*
*+*
***
12 28 44 60 76 92 108 124 140 156 172 188 204 220 236 252
*
+*
*
*
+*
**
*
+*
* *
*
+*
***
*
*+*
*
*
*+*
**
*
*+*
* *
*
*+*
***
**
+*
*
**
+*
**
**
+*
* *
**
+*
***
**
*+*
*
**
*+*
**
**
*+*
* *
**
*+*
***
13 29 45 61 77 93 109 125 141 157 173 189 205 221 237 253
*
+*
*
*
+*
**
*
+*
* *
*
+*
***
*
*+*
*
*
*+*
**
*
*+*
* *
*
*+*
***
* *
+*
*
* *
+*
**
* *
+*
* *
* *
+*
***
* *
*+*
*
* *
*+*
**
* *
*+*
* *
* *
*+*
***
14 30 46 62 78 94 110 126 142 158 174 190 206 222 238 254
**
+*
*
**
+*
**
**
+*
* *
**
+*
***
**
*+*
*
**
*+*
**
**
*+*
* *
**
*+*
***
***
+*
*
***
+*
**
***
+*
* *
***
+*
***
***
*+*
*
***
*+*
**
***
*+*
* *
***
*+*
***
15 31 47 63 79 95 111 127 143 159 175 191 207 223 239 255
-able 14 Enumeration o0 Possible Pixel :eig+bor+oods
9it+ bot+ a met+od 0or extracting 0eature points and a dictionar/ o0c+aracters and associated 0eature point data 0or re0erence4 identi0/ingc+aracters becomes a problem o0 measuring t+e degree o0 similarit/bet!een t!o sets o0 0eatures. -+e met+od emplo/ed b/ t+is algorit+mis just a slig+t modi0ication o0 Euclidean distance. All t+e distancesbet!een eac+ o0 t+e 0eature points in t+e un2no!n c+aracter and t+eirclosest corresponding 0eature points in t+e re0erence c+aracter aresummed and missing or extra 0eature points are penaliDed.
-
8/13/2019 Language Emulator
27/39
Identi0ication is t+en a matter o0 0inding t+e c+aracter in t+e dictionar/t+at is !it+in a certain t+res+old distance o0 t+e un2no!n c+aracter. Inpractice4 t+e algorit+m currentl/ c+ec2s ever/ c+aracter in t+ere0erence set to 0irst locate t+e minimum distance4 and t+en veri0iest+at t+e minimum distance is less t+an t+e t+res+old.
-
8/13/2019 Language Emulator
28/39
(.6 Language -ranslation
-+is module !or2s on a ver/ simple logic. Its main aim is to get t+e3erman -ext 0rom t+e Recognition module and translate it into Englis+.)ut as c+aracter recognition cannot be considered 1 T accurate solittle care must be ta2en in t+is module to ma2e t+e project morereliable.
,ere in t+is module !e +ave devised a dictionar/ using simple #($E. -+e recogniDed text string is searc+ed 0or in t+e dictionar/ to +ave itstranslated version. -+is translated version is t+e re"uired emulated
text.
Points to be noted;
I +ave considered situations as jotted later to improve t+e e00icienc/ o0t+e result.
Li2e !+en I !as testing m/ application sometimes m/ c+aracterrecognition module made some minor mista2es !+ic+ are ver/ muc+possible !it+ our na2ed e/e also li2e !+ile recogniDing a !or2 li2eG$AAUA
-
8/13/2019 Language Emulator
29/39
-
8/13/2019 Language Emulator
30/39
*+apter 7
Results
-
8/13/2019 Language Emulator
31/39
7.1 $naps+ots
Fig; $tarting screen o0 t+e 5I letapplication.
-
8/13/2019 Language Emulator
32/39
Fig; $naps+ot o0 t+e mobile p+onesearc+ing 0or devices.
-
8/13/2019 Language Emulator
33/39
Fig; $naps+ot o0 a mobilebe0ore starting service.
-
8/13/2019 Language Emulator
34/39
Fig; $erver module. $+o!ingconnectivit/ 0unctions.
-
8/13/2019 Language Emulator
35/39
7.( *onclusion
At t+e time o0 t+e beginning o0 t+e development o0 t+is project !e+ave 2ept certain goals in mind and it gives us great pleasure t+at t+eapplication is meeting most o0 its re"uirement. In t+is project report !e+ave mention all t+e details regarding t+e project4 !+ic+ includes allt+e stages o0 t+e application.
Finall/ t+e 0ollo!ing pictorial representations !ill indicate t+e !+oleapplication step b/ step along !it+ t+e results obtained during eac+p+ase.
An Image Is *aptured -+roug+ A 5obile 9+ic+ *ontains a -ext In3erman Language. $a/ 0or demonstration purpose its Gbuc+H as s+o!nbelo!. -+e image is ta2en b/ a 5otorola L i 5obile p+one.
-
8/13/2019 Language Emulator
36/39
Image $ent$5$ btained
As s+o!n above t+e translated version o0 3erman !ord Gbuc+H isreceived b/ t+e mobile !+ic+ is Gboo2H.
-
8/13/2019 Language Emulator
37/39
9e did t+is !it+ images o0 di00erent resolutions ta2en 0rom variabledistances at di00erent luminar/ conditions @i.e. brig+t lig+t4 mediumlig+t4 dim lig+t etc. etc. . -+e accurac/ obtained in 0avourableconditions !as good as compared to t+at in odd conditions @i.e. lesslig+t more distance etc. etc . $o a0ter mulling over t+e considerations!e did some o0 t+e experiments b/ ta2ing di00erent +andsets +aving
cameras o0 di00erent resolutions at 0avourable conditions. All suc+statistical log is as belo!;
Accurac/ Results5obile P+one Resolution :o o0 times
accurateresultsobtained@max tries >
Accurac/
J:eglectingtrails !it+out
1 TaccurateresultsK
:o2ia 7(7 1.75 6 ' T
5otorola L i 6 x 6' 7 T
:o2ia 7 (5 6 ' T
-
8/13/2019 Language Emulator
38/39
7.7 Furt+er Improvements
-+ere can be some en+ancements !+ic+ can be implemented in ourproject. -+ese en+ancements !ill surel/ ma2e it 0easible to be includedas one o0 t+e services !+ic+ !ill be provided b/ t+e mobile companiesand net!or2 providers. $ome o0 t+em are as belo!;
i. In image sending module4 )luetoot+ connectivit/ is implementedto send image to t+e server. -o broaden its range instead o0)luetoot+4 !ireless trans0er can be implemented !+ic+ !ill deal!it+ 55$8s to send t+e image. It is not implemented b/ uspresentl/ because o0 t+e +ig+ cost involved in sending 55$8s.
ii. In recognition part !e +ave considered straig+t text !it+in t+eimage. Furt+er it ma/ be implemented 0or inclined4 invertedstrings o0 c+aracters.
iii. -+e image in our project s+ould +ave onl/ t!o colors. All t+ec+aracters o0 a text are comprised o0 one color and t+ebac2ground8s color comprising t+e second one. -+is can beextended to more t+an t!o color sc+eme as pragmaticall/ it isnot possible to +ave uni0orm bac2ground color.
iv. -+e text !it+in our project s+ould be a single !ord i.e. name o0t+e cit/. It s+ould not be a sentence 0ormed o0 grammaticall/connected !ords. $o 0urt+er improvement can be implemented torecogniDe sentence and interpret it !it+ proper grammaticalsentence in t+e target language.
v. -+is language emulator can be implemented as a stand aloneso0t!are 0or t+e mobile p+ones. i.e. t+is so0t!are s+ould beinstalled in t+e p+one to directl/ get t+e translated text !it+out
sending it to t+e server and getting bac2 t+e message.
-
8/13/2019 Language Emulator
39/39