冈萨版数字图像处理—双语课程-复习PPT.ppt_第1页
冈萨版数字图像处理—双语课程-复习PPT.ppt_第2页
冈萨版数字图像处理—双语课程-复习PPT.ppt_第3页
冈萨版数字图像处理—双语课程-复习PPT.ppt_第4页
冈萨版数字图像处理—双语课程-复习PPT.ppt_第5页
已阅读5页,还剩78页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

Duetoprocessing storage andsamplinghardwareconsiderations thenumberofgraylevelstypicallyisanintegerpowerof2 L 2k kiscalledthebitdepth Storagerequirementcalculation Thenumberofbits b requiredtostoreadigitizedimageis b M N kWhenM N thisequationbecomes b N2k TherequirementofthegraylevelvalueL Asetofpixelsallofwhichare4 connectedtoeachotheriscalleda4 component ifallthepixelsare8 connectedthesetisan8 component 4 component 4 component Onlyone8 componentbuttwo4 component 8 component Illustrationofdifferentconnectedcomponents 1 TheEuclideandistancebetweenpandqisdefinedas Differentwaysofmeasuringdistance Usingthismethod thepixelshavingadistancelessthanorequaltosomevaluerfrom x y arethepointscontainedinadiskofradiusrcenteredat x y 2 TheD4distance alsocalledcityblockdistance betweenpandqisdefinedas Usingthismethod thepixelshavingaD4distancefrom x y lessthanorequaltosomevaluerformadiamondcenteredat x y Forexample thepixelswithD4distance 2from x y formthefollowingcontoursofconstantdistance ThepixelswithD4 1arethe4 neighborsof x y Differentwaysofmeasuringdistancecon t 3 TheD8distance alsocalledchessboarddistance betweenpandqisdefinedas D8 p q max x s y t Differentwaysofmeasuringdistancecon t ThepixelswithD8 1arethe8 neighborsof x y Assumethatp p2 andp4havevalue1andthatp1andp3canhaveavalue0or1 ForV 1 solveforDmdistancebetweenpandp4 Solution Ifp1andp3are0 thenDmis2 Ifp1is1 p3are0 thenDmbecomes3 Similarly ifp3is1andp1is0 Dmalsois3 Finally ifbothp1andp3are1 Dmis4 ExampletoillustratefindingDmdistance Contraststretching 对比拉伸 Thresholding 二值化 Transformationfunctions T r CharacteristicsofGray leveltransformationfunctions Sdependsononlyonepixelvaluerforcalculation Thisiscalled pointprocessing Illustrationofhistogramequalization 4x4image Grayscale 0 9 histogram Performhistogramequalization Resultsafterhistogramequalization 255194157103155911620223990155523523420712420918810532271134522835 255 11111111235 11101011188 10111100155 10011011124 0111110090 01011010 Bit plane7image Bit plane2image 1 1 1 1 0 0 1 1 1 0 0 0 Asimplebit planeexample Movingwindowexample findtheminimum 242116235105354595188228521901552094515511131241131039015423822715723920769119194202234351107 2422421162351053544242242116235105354459595188228521901901551552094515511131131241241131039015423823822722715723920769119119194194202234351107107194194202234351107107 Ifmovingwindowsizeismxn thenthepaddedrowandcolumnshouldbe m 1 2and n 1 2respectively Originalimage Paddedimage Originalimage mask Filteredimage 10 Illustrationofaweightedaveragefilter IllustrationofMedianfilter Definition highlightfinedetailinanimageortoenhancedetailthathasbeenblurred Itistheoppositeofaveraging Basicthinking sinceaveragingisanalogoustointegration itislogictoconcludethatsharpeningcouldbeaccomplishedbyspatialdifferentiation Imagedifferentiationenhancesedgesandotherdiscontinuities suchasnoise anddeemphasizesareaswithslowlyvaryinggray levelvalues Sharpeningspatialfilters 锐化滤波器 ImplementingtheFouriertransform PropertiesofFouriertransform review 1 Translation 位移性质 Applicationoftranslationproperty Whenu0 M 2andv0 N 2 itfollowsthat Inthiscase similarly ThediscreteFouriertransform canbeexpressedintheseparableform Separability Periodicity ThediscreteFouriertransformhasthefollowingperiodicityproperties F u v F u M v F u v N F u M v N Theinversetransformalsoisperiodic f x y f x M y f x y N f x M y N Theideaofconjugatesymmetrywasintroducedinprevioussection andisrepeatedhereforconvenience F u v F u v Thespectrumalsoissymmetricabouttheorigin Conjugatesymmetry Componentscharacteristics Theilluminationcomponentofanimagegenerallyischaracterizedbyslowspecialvariations whilethereflectancecomponenttendstovaryabruptly particularlyatthejunctionsofdissimilarobjects TheabovecharacteristicsleadtoassociatingthelowfrequenciesoftheFouriertransformofthelogarithmofanimagewithilluminationandthehighfrequencieswithreflectance Theneedforpadding 补零 Someimportantfactsthatneedspecialattention 1 ForDFT theperiodicityisamathematicalby productofthewayinwhichthediscreteFouriertransformpairisdefined Periodicityispartoftheprocess anditcannotbeignored 2 Ifperiodicityissueisnothandledproperly itwillgiveincorrectresultsofsomemissingdata 3 Thefollowingexampleshowsdetailsofneedforpadding Paddingof2 Dfunctions Twoimagesf x y andh x y ofsizesA BandC D withperiodPinthex directionandQinthey direction Toavoidwraparounderror weneedtoproperlychoosePandQaccordingtofollowingprinciple P A C 1andQ B D 1 Theperiodicsequencesareformedbyextendingf x y andh x y asfollows fe x y f x y 0 x A 1and0 y B 1 0A x PorB y Q he x y h x y 0 x C 1and0 y D 1 0C x PorD y Q Paddingrules Estimatingthedegradationfunction Therearethreeprincipalwaystoestimatethedegradationfunctionforuseinimagerestoration ObservationExperimentationMathematicalmodeling Theprocessofrestoringanimagebyusingadegradationfunctionthathasbeenestimatedinsomewaysometimesiscalledblinddeconvolution duetothefactthatthetruedegradationfunctionisseldomknowncompletely Inordertoreducetheeffectofnoiseinourobservation wewouldlookforareasofstrongsignalcontentinthedegradedimage so x y isignored Usingsamplegraylevelsoftheobjectandbackground wecanconstructanunblurredsubimage Lettheobservedsubimagebedenotedbygs x y andtheconstructedsubimagebedenotedby Thenweget Wecanapplythisfunctiontothewholeimage EstimateH u v forsubimage 1 Usinganimageacquiringdevicetogetasimilardegradedimagebyadjustingsystemparametersettings 2 Letabrightdotoflightpassingthroughtheabovesystemwiththesameparametersettings ThenweobtainedadegradedimageG u v toimpulseresponse Itfollowsthat whichisthemethodusedtodeterminePSF Stepsofexperimentation Estimationbymodeling 建模 Insituationswheredegradationiscausedbybadenvironmentalconditions estimationbyexperimentationisdifficulttoimplement Modelingwillbeagoodwaytosolvetheproblem Therearestandardmodelsalreadyconstructedtomodelrealworldproblems Forexample theGaussianLPFisusedsometimestomodelmild uniformblurring Wejustneedtoidentifythedegradationandchoosetherightmodel Anothermajorapproachinmodelingistoderiveamathematicalmodelstartingfrombasicprinciples Wewillknowthedetailfromanexample DefinitionofInversefiltering 逆滤波 Recalltheimagedegradationmodel IfwedivideG u v byH u v togetanestimateofF u v thenweget Thisiscalleddirectinversefiltering Problems 1 F u v isarandomfunctionwhoseFouriertransformisnotknown 2 IfdegradationfunctionH u v haszeroorverysmallvalues thentheratioN u v H u v couldeasilydominatetheestimateF u v Solutions fromchapter4 wealreadyknowthatH 0 0 isequaltotheaveragevalueofh x y andthisisusuallythehighestvalueofH u v inthefrequencydomain Thusbylimitingtheanalysistofrequenciesneartheorigin wereducetheprobabilityofencounteringzerovalues Solvinginversefilteringproblems Fromthedefiningequation wecanderivetheestimateinfrequencydomainsuchthatitmakestheerrorminimum Notethatifthenoiseiszero thenthenoisepowerspectrumvanishesandtheWienerfilterreducestotheinversefilter Wiener filteringFrequencydomainexpression Solutiontoconstrainedoptimization Thefrequencydomainsolutiontothisoptimizationproblemisgivenbytheexpression where isaparameterthatmustbeadjustedmanuallysothattheconstraintissatisfied andP u v istheFouriertransformofthefunction whichistheLaplacianoperator Notethattheaboveequationreducestoinversefilteringif iszero Waystofindthecoefficientsa b c d Thefourcoefficientsareeasilydeterminedfromthefourequationsinfourunknownsthatcanbewrittenusingthefourknownneighborsof x y v x1 y1 ax1 by1 cx1y1 d v x2 y2 ax2 by2 cx2y2 d v x3 y3 ax3 by3 cx3y3 d v x4 y4 ax4 by4 cx4y4 d x2 x1 y3 y1 x4 x3 y4 y2 Datacompressionisachievedwhenoneormoreoftheseredundanciesarereducedoreliminated Typesofredundancy Indigitalimagecompression wediscussthreebasicdataredundancies 1 Codingredundancy 2 Interpixelredundancy 3 Psychovisualredundancy Illustrationofvariable lengthcoding 不等长编码 Illustrationofvariable lengthcodingcon t Objective Whenpr rk islarge l2 rk shouldbeshort whenpr rk issmall l2 rk shouldbelong Psychovisualredundancy 视觉冗余 Thehumaneyedoesnotrespondwithequalsensitivitytoallvisualinformation certaininformationsimplyhaslessrelativeimportancethanotherinformationinnormalvisualprocessing Thisinformationissaidtobepsychovisuallyredundant Itcanbeeliminatedwithoutsignificantlyimpairingthequalityofimageperception Theeliminationofpsychovisuallyredundantdataresultsinalossofquantitativeinformation soitiscommonlyreferredtoasquantization Itisanirreversibleoperation visualinformationislost quantizationresultsinlossydatacompression Characteristicsofquantization Thesourceencoderanddecoder Mapperisdesignedtoreduceinterpixelredundancies eg Run lengthcoding Quantizerreducespsychovisualredundancies thisoperationisirreversible Symbolencoderreducescodingredundancy thisoperationisreversible Threepartofthesourceencoder ForaninformationsourceproducingJpossiblesourcesymbols a1 a2 aj eachwithprobabilityP aj thentheaverageinformationpersourceoutputobtainedfromthesourcez denotedH z is H z iscalledtheuncertaintyorentropyofthesource Theentropy 熵 ofthesource Usinginformationtheory Example computetheentropyofthefollowing8 bitgraylevelimageofsize4 8 Method 1 vieweachpixelwithequalprobabilityofgeneratingnumbersfrom0to255 Entropyperpixeliscomputedfromformula Thetotalentropyis Meaning thisparticularimageisbutoneof2256 1077 equallyprobable4 8imagesthatcanbeproducedbythesource Huffmancodinganddecoding Theaveragelengthofthiscodeis Lavg 0 4 1 0 3 2 0 1 3 0 1 4 0 06 5 0 04 5 2 2bits symbol Theentropyofthesourceis H z 0 4log2 0 4 0 3log2 0 3 2 0 1log2 0 1 0 06log2 0 06 0 04log2 0 04 2 1435 Huffmancodeefficiencyis Huffmandecoding Huffmancodeisaninstantaneousuniquelydecodableblockcode Theencodedsymbolscanbedecodedbyexaminingtheindividualsymbolsofthestringinalefttorightmanner Forexample decodingtheencodedstring010100111100revealthatthefirstvalidcodewordis01010 whichisthecodeforsymbola3 Thenextvalidcodeis011 whichisforsymbola1 Continuinginthismannerrevealsthecompletelydecodedmessagetobea3a1a2a2a6 Arithmeticcodingcon t SourceAcontainsa1a2a3a4 p a1 0 2 p a2 0 2 p a3 0 4 p a4 0 2 Anynumberinthisrangerepresentsthemessagea1a2a3a3a4 Forexample 0 068canbeusedtodoso Result TheentropyH z 0 58 a5 symbolmessagereducesto068 thatis3symbols thistranslatesto3 5 0 6decimaldigitspersourcesymbol whichisclosetotheentropy IllustrationofArithmeticdecoding Given pA pB 0 25 pC 0 2 pD pE 0 15 Decodethenumber0 386 How Byextractingandcodingonlythenewinformationineachpixel Newinformation thedifferencebetweenactualandpredictedvalueofthatpixel Losslesspredictivecoding Predictorsinencoderanddecoderarethesame Variouslocal globalandadaptivemethodscanbeusedtogeneratetheprediction Losslesspredictivecodingmodel Codeonlythepredictederror Linearpredictoriscommon Previouspixelsareusedtoestimatethevalueofthecurrentpixel Thepreviouspixelscouldbeonthesamerow column withthecurrentpixel 1 Dprediction oraroundthecurrentpixel 2 D Generalcodingmethod Lossypredictivecoding Becausethepredictionatthedecoderandencodershouldbethesame Thisclosedloopconfigurationwillpreventerrorbuiltupatthedecoderoutput Deltamodulation DM example Thepredictorandquantizeraredefinedas Notethetwodistortions 1 granularnoise 2 slopeoverload toolarge toosmall granularnoise slopeoverload roughsurface blurrededges Decoderoutput figure8 22demo m Basicapproachtotransformcoding TwodimensionalmatrixformofWHTanditsinverse Kroneckerproduct 直积 张量积 AHadamardmatrixisasymmetricmatrixwhoseelementsare 1and 1 WHTNcanbegeneratedusingMatlabfunctionhadamard n IllustrationofKroneckerproduct Reconstructionerrorvs subimagesize Foreachtransformedsubimage truncating75 oftheresultingcoefficient andtakingtheinversetransformofthetruncatedarrays Differentwaysoftruncatingcoefficients Inmosttransformcodingsystems theretainedcoefficientsareselectedonthebasisofmaximumvariance calledzonalcoding oronthebasisofmaximummagnitude calledthresholdcoding Theoverallprocessoftruncating quantizing andcodingthecoefficientsofatransformedsubimageiscommonlycalledbitallocation Bitallocationdeterminesthenumberofbitstobeusedtocodeeachcoefficientbasedonitsimportance Preview Segmentationistosubdivideanimageintoitsconstituentregionsorobjects Segmentationshouldstopwhentheobjectsofinterestinanapplicationhavebeenisolated Principalapproaches Segmentationalgorithmsgenerallyarebasedononeoftwobasicpropertiesofintensityvaluesdiscontinuity topartitionanimagebasedonabruptchangesinintensity suchasedges similarity topartitionanimageintoregionsthataresimilaraccordingtoasetofpredefinedcriteria LineDetection Horizontalmaskwillresultwithmaxresponsewhenalinepassedthroughthemiddlerowofthemaskwithaconstantbackground thesimilarideaisusedwithothermasks note thepreferreddirectionofeachmaskisweightedwithalargercoefficient i e 2 thanotherpossibledirections LineDetection ApplyeverymasksontheimageletR1 R2 R3 R4denotestheresponseofthehorizontal 45degree verticaland 45degreemasks respectively if atacertainpointintheimage Ri Rj forallj i thatpointissaidtobemorelikelyassociatedwithalineinthedirectionofmaski GradientMasks DiagonaledgeswithPrewittandSobelmasks Sobelmaskshaveslightlysuperiornoise suppressioncharacteristicswhichisanimportantissuewhendealingwithderivatives RoleofLaplacianoperatorinsegmentation TheLaplaciangenerallyisnotusedinitsoriginalformforedgedetectionforseveralreasons Unacceptablysensitivetonoise Thedoubleedgesitproduceswouldcomplicatesegmentation Unabletodetectedgedirection Therole Usingitszerocrossingpropertyforedgelocation Usingitforthecomplementarypurposeofdecidingwhetherapixelisonthedarkorlightside LaplacianofGaussian LoG Laplaciancombinedwithsmoothingasaprecursortofindedgesviazero crossing Considerthefunction wherer2 x2 y2 and isthestandarddeviation Convolvethisfunctionwithanimageblurstheimage thelargerthes themoreblur ExpressionofLoG plane problemofusingequationy ax bisthatvalueofaisinfiniteforaverticalline Toavoidtheproblem usenormallineequationxcos ysin torepresentalineinstead verticallinehas 90 with equalstothepositivey interceptor 90 with equalstothenegativey intercept xcos ysin plane 90 measuredwithrespecttox axis whereDisthedistancebetweencornersintheimage IllustrationofHoughTransformation LocalProcessing analyzethecharacteristicsofpixelsinasmallneighborhood say 3 3 5 5 abouteveryedgepixels x y inanimage allpointsthataresimilaraccordingtoasetofpredefinedcriteriaarelinked forminganedgeofpixelsthatsharethosecriteria Criteria thestrengthoftheresponseofthegradientoperatorusedtoproducetheedgepixelanedgepixelwithcoordinates x0 y0 inapredefinedneighborhoodof x y issimilarinmagnitudetothepixelat x y if f x y f x0 y0 E Criteria thedirectionofthegradientvectoranedgepixelwithcoordinates x0 y0 inapredefinedneighborhoodof x y issimilarinangletothepixelat x y if x y x0 y0 A Criteria Apointinthepredefinedneighborhoodof x y islinkedtothepixelat x y ifbothmagnitudeanddirectioncriteriaaresatified theprocessisrepeatedateverylocationintheimage arecordmustbekept simplybyassigningadifferentgrayleveltoeachsetoflinkededgepixels Probabilityoferroneouslyclassifying background object Region BasedSegmentation BasicFormulation P Ri isalogicalpredicatepropertydefinedoverthepointsinsetRi ex P Ri TRUEifallpixelinRihavethesamegraylevel RegionGrowing startwithasetof seed pointsgrowingbyappendingtoeachseedthoseneighborsthathavesimilarpropertiessuchasspecificrangesofgraylevel Region

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论