Click here to load reader

Aug 19, 2015

ihihi

Digital Image Processing Morphology Basic Morphology Concepts MathematicalMorphologyisbasedonthealgebraofnon-linearoperators operatingonobjectshapeandinmanyrespectssupersedesthelinear algebraic system of convolution. Itperformsinmanytaskspre-processing,segmentationusingobject shape,andobjectquantificationbetterandmorequicklythanthe standard approach. Mathematical morphology tool is different from the usual standard algebra and calculus. Morphology tools are implemented in most advanced image analysis. Mathematical morphology is very often used in applications where shape of objectsandspeedisanissueexample:analysisofmicroscopicimages, industrial inspection, optical character recognition, and document analysis. Thenon-morphologicalapproachtoimageprocessingisclosetocalculus, beingbasedonthepointspreadfunctionconceptandlinear transformations such as convolution. Mathematicalmorphologyusestoolsofnon-linearalgebraandoperates with point sets, their connectivity and shape. Morphologyoperationssimplifyimages,andquantifyandpreservethe main shape characteristics of objects. Morphological operations are used for the following purpose: Image pre-processing (noise filtering, shape simplification). Enhancingobjectstructure(skeletonzing,thinning,thickening,convex hull, object marking). Segmenting objects from the background. Quantitativedescriptionofobjects(area,perimeter,projections,Euler-Poincare characteristics). Mathematicalmorphologyexploitspointsetproperties,resultsofintegral geometry, and topology. Therealimagecanbemodeledusingpointsetsofanydimension;the Euclidean2Dspaceanditssystemofsubsetsisanaturaldomainfor planar shape description. Set difference is defined by \ =

ComputervisionusesthedigitalcounterpartofEuclideanspacesetsof integerpairs( )forbinaryimagemorphologyorsetsofinteger triples( ) for gray-scale morphology or binary 3D morphology. Discrete grid can be defined if the neighborhood relation between points is welldefined.Thisrepresentationissuitableforbothrectangularand hexagonal grids. Amorphologicaltransformation isgivenbytherelationoftheimage withanothersmallpointsetBcalledstructuringelement.Bisexpressed with respect to a local origin . Structuringelementisasmallimage-usedasamovingwindow--whose support delineates pixel neighborhoods in the image plane. It can be of any shape, size, or connectivity (more than 1 piece, have holes). Toapplythemorphologicaltransformation()totheimagemeans thatthestructuringelementBismovedsystematicallyacrosstheentire image.AssumethatBispositionedatsomepointintheimage;thepixelinthe imagecorrespondingtotherepresentativepointOofthestructuring element is called the current pixel. The result of the relation between the image X and the structuring element B in the current position is stored in the output image in the current image pixel position.

Fig 1: Typical structuring elements. Thedualityofmorphologicaloperationsisdeducedfromtheexistenceof thesetcomplement;foreachmorphologicaltransformation()there exists a dual transformation () () = ()

Thetranslationofthepointsetbythevectorisdenotedby ;itis defined by = , = + . Fig 2: Translation by a vector Morphological Principles:1.Compatibilitywithtranslation:Letthetransformationdependonthe positionoftheoriginoftheco-ordinatesystem,anddenotesucha transformationby .Ifallpointsaretranslatedbythevector ,itis expressed as . The compatibility with translation principle is given by() = () . Ifdoesnotdependonthepositionoftheorigin,thenthecompatibility with translation: principle reduces to invariance under translation () = () . 2.Compatibilitywithchangeofscale:Let representthehomothetic scalingofapointset(i.e.,theco-ordinatesofeachpointofthesetare multipliedbysomepositiveconstant ).Thisisequivalenttochangeof scalewithrespecttosomeorigin.Let denoteatransformationthat depends on the positive parameter(change of scale). Compatibility with change of scale is given by () = 1Ifdoesnotdependonthescale ,thencompatibilitywithchangeof scale reduces to invariance to change of scale () = ()3.Localknowledge:Thelocalknowledgeprincipleconsidersthesituationin which only a part of a larger structure can be examinedthis is always the caseinreality,duetotherestrictedsizeofthedigitalgrid.The morphologicaltransformation satisfiesthelocalknowledgeprincipleif foranyboundedpointset inthetransformation ()thereexistsa boundedset ,knowledgeofwhichissufficienttoprovide .Thelocal knowledge principle may be written symbolically as ) = ) .4.Uppersemi-continuity:Theuppersemi-continuityprinciplesaysthatthe morphological transformation does not exhibit any abrupt changes. Binary Dilation and Erosion Thesetsofblackandwhitepixelsconstituteadescriptionofabinary image.Assumeonlyblackpixelsisconsidered,andtheothersaretreated as a background. Theprimarymorphologicaloperationsaredilationanderosion,andfrom thesetwo,morecomplexmorphologicaloperationssuchasopening, closing, and shape decomposition can be constituted. Dilation Themorphologicaltransformationdilation combinestwosetsusing vector addition (e.g., (a, b) +(c, d) = (a+c, b+d)). The dilation is the point set of all possible vector additions of pairs of elements, one from each of the sets and = : = +, } Example: ={(1,0),(1,1),(1,2),(2,2),(0,3),(0,4)}, = {(0, 0), (1, 0)}, ={(1,0),(1,1),(1,2),(2,2),(0,3),(0,4),(2,0),(2,1),(2,2),(3,2),(1,3),(1,4)} Fig 3: Dilation Fig4shows256x256originalimageontheleft.Astructuringelementsize 3x3 is used. TheresultofdilationisshownontherightsideofFig4.Inthiscasethe dilation is an isotropic expansion (Fill or Grow).

Fig 4: Dilation as isotropic expansion Dilationwithanisotropic3x3structuringelementmightbedescribedasa transformation which changes all background pixels neighboring the object to object pixels. Dilation properties: Dilation operation is commutative = Dilation operation is associative ( ) = ( ) Dilation may also be expressed as a union of shifted point sets = Invariant to translation = ( ) Dilation is an increasing transformation Dilationisusedtofillsmallholesandnarrowgulfsinobjects.Itincreases the object size if the original size needs to be preserved, and then dilation is combined with erosion. Fig 5: Dilation where the representative point is not a member of the structuring element. Fig5illustratestheresultofdilationiftherepresentativepointisnota memberofthestructuringelementB,ifthisstructuringelementisused; the dilation result is substantially different from the input set. Erosion Erosion combines two sets using vector subtraction of set elements and is dual operator of dilation. = : = + }. This formula says that every point from the image is tested; the result of the erosion is given by those points for which all possible + are in X. Example: ={(1,0),(1,1),(1,2),(0,3),(1,3),(2,3),(3,3),(1,4)}, = {(0, 0), (1, 0)}, = {(0, 3), (1, 3), (2, 3)}. Fig 6: Erosion The result of the erosion is shown in the right side of the Fig 7. Erosion with an isotropic structuring element is called as shrink or reduce. Fig 7: Erosion as isotropic shrink Basicmorphologicaltransformationscanbeusedtofindthecontoursof objectsinanimageveryquickly.Thiscanbeachieved,forinstance,by subtraction from the original picture of its eroded version as in Fig 8. Fig 8: Contours obtained by subtraction of an eroded image from the original (left). Erosionisusedtosimplifythestructureofanobject.Itdecomposes complicated object into several simple ones. The equivalent definition for erosion = : }. Theerosionmightbeinterpretedbystructuringelementslidingacross theimage ;then,iftranslatedbythevectoriscontainedinthe image , the point corresponding to the representative point belongs to the erosion . Animplementationoferosionmightbesimplifiedbynotingthatan image erodedbythestructuringelementcanbeexpressedasan intersection of all translations of the image by the vector = . Iftherepresentativepointisamemberofthestructuringelement,then erosionisananti-extensivetransformation;thatis,if(0,0) ,then .Erosion properties: Erosion is translation invariant = ( ), = ( ), Erosion as increasing transformation: Erosion and dilation are dual transformations ( ) = . Erosion is not commutative . Erosion and intersection combined together ( ) = ( ) ( ), ( ) ( ) ( ). Image intersection and dilation cannot be interchanged; the dilation of the intersection of two images is contained in the intersection of their dilations ( ) = ( ) ( ) ( ). The order of erosion may be interchanged with set union. This fact enables thestructuringelementtobedecomposedintoaunionofsimpler structuring elements ( ) = ( ) = ( ) ( ), ( ) ( ) ( ), ( ) = ( ) ( ). Successivedilationoftheimagefirstbythestructuringelementand then by the structuring element is equivalent to the dilation of the image X by ( ) = ( ), ( ) = ( ). Hit-or-miss transformation Hit-or-misstransformationisthemorphologicaloperatorforfindinglocal patterns of pixels, where local means the size of the structuring element. Itisavariantoftemplatematchingthatfindscollectionsofpixelswith certain shape properties. Structuringelement ,TestedpointsX,operationdenotedbyapairof disjoint sets = (, ), called a composite structuring element. The Hit-or-miss transformation is defined as = : }. Findinglocalpatternsinimagetestsobjects,background (complement), Useful for finding corners, for instance. Thehit-or-misstransformationoperatesasabinarymatchingbetweenan imageandthestructuringelement(, ).Itmaybeexpressedusing erosions and dilations as well = ( ) ( ) = ( )( ). Opening and closing Erosion and dilation are not inverse transformationif an image is eroded and then dilated, the original image is not re-obtained. Erosionfollowedbydilationiscalledopening.Theopeningofanimage by the structuring element is denoted by and is defined as = (X B) B. Dilation followed by erosion is called Closing. The clos

Related Documents See more >