版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
CS414–MultimediaSystemsDesign
Lecture7–BasicsofCompression(Part1)
CS414–MultimediaSystemsDeCS414-Spring2014AdministrativeMP1ispostedSeeClasswebsiteandcompassMP1lecturewillbeonFebruary7inclass.Please,readtheMP1beforeattendingtheclassMP1dueFebruary19(Wednesday)5pm.CS414-Spring2014AdministraQuestiononDLP3DGlassesDLP=DigitalLightProcessingDLP=projectiontechnologyDLP=ATexasInstrumentprocessofprojectingvideoimagesusingalightsourcereflectingoffanarrayoftensofthousandsofmicroscopicmirrors….CS414-Spring2014QuestiononDLP3DGlassesDLPTodayIntroducedConceptsNeedforcompressionandcompressionalgorithmsclassificationBasicCodingConceptsFixed-lengthcodingandvariable-lengthcodingCompressionRatioEntropyRLECompression(EntropyCoding)HuffmanCompression(StatisticalEntropyCoding)CS414-Spring2014TodayIntroducedConceptsNeedReadingMediaCodingandContentProcessing,Steinmetz,Nahrstedt,PrenticeHall,2002DataCompression–chapter7Basiccodingconcepts–Sections7.1-7.4andlecturenotesCS414-Spring2014ReadingMediaCodingandConteIntegratingAspectsofMultimediaCS414-Spring2014Image/VideoCaptureImage/VideoInformationRepresentationMediaServerStorageTransmissionCompressionProcessingAudio/VideoPresentationPlaybackAudio/VideoPerception/PlaybackAudioInformationRepresentationTransmissionAudioCaptureA/VPlaybackIntegratingAspectsofMultimeNeedforCompressionUncompressedaudio8KHz,8bit8Kpersecond30Mperhour44.1KHz,16bit88.2Kpersecond317.5Mperhour100Gbytediskholds315hoursofCDqualitymusicUncompressedvideo640x480resolution,8bitcolor,24fps7.37Mbytespersecond26.5Gbytesperhour640x480resolution,24bit(3bytes)color,30fps27.6Mbytespersecond99.5Gbytesperhour1980x1080resolution,24bits,60fps(384,912MBps)1,385Gbyteper1hourofHDTVCS414-Spring2014NeedforCompressionUncompressBroadClassificationEntropyCoding(statistical)lossless;independentofdatacharacteristicse.g.RLE,Huffman,LZW,ArithmeticcodingSourceCodinglossy;mayconsidersemanticsofthedatadependsoncharacteristicsofthedatae.g.DCT,DPCM,ADPCM,colormodeltransformHybridCoding(usedbymostmultimediasystems)combineentropywithsourceencodinge.g.,JPEG-2000,H.264,MPEG-2,MPEG-4,MPEG-7CS414-Spring2014BroadClassificationEntropyCoDataCompressionBranchofinformationtheoryminimizeamountofinformationtobetransmittedTransformasequenceofcharactersintoanewstringofbitssameinformationcontentlengthasshortaspossibleCS414-Spring2014DataCompressionBranchofinfoConceptsCoding(thecode)mapssourcemessagesfromalphabet(A)intocodewords(B)Sourcemessage(symbol)isbasicunitintowhichastringispartitionedcanbeasingleletterorastringoflettersEXAMPLE:aabbbccccdddddeeeeeefffffffggggggggA={a,b,c,d,e,f,g,space}B={0,1}CS414-Spring2014ConceptsCoding(thecode)mapsTaxonomyofCodesBlock-blocksourcemsgsandcodewordsoffixedlength;e.g.,ASCIIBlock-variablesourcemessagefixed,codewordsvariable;e.g.,HuffmancodingVariable-blocksourcevariable,codewordfixed;e.g.,RLEVariable-variablesourcevariable,codewordsvariable;e.g.,ArithmeticCS414-Spring2014TaxonomyofCodesBlock-blockCSExampleofBlock-BlockCoding“aabbbccccdddddeeeeeefffffffgggggggg”Requires120bitsSymbolCodeworda000b001c010d011e100f101g110space111ExampleofBlock-BlockCoding“ExampleofVariable-VariableCoding“aabbbccccdddddeeeeeefffffffgggggggg”Requires30bitsdon’tforgetthespacesSymbolCodewordaa0bbb1cccc10ddddd11eeeeee100fffffff101gggggggg110space111ExampleofVariable-VariableCoConcepts(cont.)Acodeisdistinctifeachcodewordcanbedistinguishedfromeveryother(mappingisone-to-one)uniquelydecodable
ifeverycodewordisidentifiablewhenimmersedinasequenceofcodewordse.g.,withprevioustable,message11couldbedefinedaseitherdddddorbbbbbbCS414-Spring2014Concepts(cont.)AcodeisCS41StaticCodesMappingisfixedbeforetransmissionmessagerepresentedbysamecodewordeverytimeitappearsinmessage(ensemble)HuffmancodingisanexampleBetterforindependentsequencesprobabilitiesofsymboloccurrencesmustbeknowninadvance;CS414-Spring2014StaticCodesMappingisfixedbDynamicCodesMappingchangesovertimealsoreferredtoasadaptivecodingAttemptstoexploitlocalityofreferenceperiodic,frequentoccurrencesofmessagesdynamicHuffmanisanexampleHybrids?buildsetofcodes,selectbasedoninputCS414-Spring2014DynamicCodesMappingchangesoTraditionalEvaluationCriteriaAlgorithmcomplexityrunningtimeAmountofcompressionredundancycompressionratioHowtomeasure?CS414-Spring2014TraditionalEvaluationCriteriMeasureofInformationConsidersymbols
siandtheprobabilityofoccurrenceofeachsymbolp(si)Incaseoffixed-lengthcoding,smallestnumberofbitspersymbolneededisL≥log2(N)bitspersymbolExample:Messagewith5symbolsneed3bits(L≥log25)CS414-Spring2014MeasureofInformationConsiderVariable-LengthCoding-EntropyWhatistheminimumnumberofbitspersymbol?Answer:Shannon’sresult–theoreticalminimumaveragenumberofbitspercodewordisknownasEntropy(H)Entropy–measureofuncertaintyinrandomvariableCS414-Spring2014Variable-LengthCoding-EntropEntropyExampleAlphabet={A,B}p(A)=0.4;p(B)=0.6ComputeEntropy(H)-0.4*log20.4+-0.6*log20.6=.97bitsCS414-Spring2014EntropyExampleAlphabet={A,CompressionRatioComparetheaveragemessagelengthandtheaveragecodewordlengthe.g.,averageL(message)/averageL(codeword)Example:{aa,bbb,cccc,ddddd,eeeeee,fffffff,gggggggg}Averagemessagelengthis5Ifweusecode-wordsfromslide11,thenWehave{0,1,10,11,100,101,110}Averagecodewordlengthis2.14..BitsCompressionratio:5/2.14=2.336CS414-Spring2014CompressionRatioComparetheaSymmetrySymmetriccompressionrequiressametimeforencodinganddecodingusedforlivemodeapplications(teleconference)Asymmetriccompressionperformedoncewhenenoughtimeisavailabledecompressionperformedfrequently,mustbefastusedforretrievalmodeapplications(e.g.,aninteractiveCD-ROM)CS414-Spring2014SymmetrySymmetriccompressionCEntropyCodingAlgorithms(ContentDependentCoding)Run-lengthEncoding(RLE)ReplacessequenceofthesameconsecutivebyteswithnumberofoccurrencesNumberofoccurrencesisindicatedbyaspecialflag(e.g.,!)Example:abcccccccccdeffffggg(20Bytes)abc!9def!4ggg(13bytes)CS414-Spring2014EntropyCodingAlgorithms(ConVariationsofRLE(Zero-suppressiontechnique)Assumesthatonlyonesymbolappearsoften(blank)ReplaceblanksequencebyM-byteandabytewithnumberofblanksinsequenceExample:M3,M4,M14,…SomeotherdefinitionsarepossibleExample:M4=8blanks,M5=16blanks,M4M5=24blanksCS414-Spring2014VariationsofRLE(Zero-suppreHuffmanEncodingStatisticalencodingTodetermineHuffmancode,itisusefultoconstructabinarytreeLeavesarecharacterstobeencodedNodescarryoccurrenceprobabilitiesofthecharactersbelongingtothesubtreeExample:HowdoesaHuffmancodelooklikeforsymbolswithstatisticalsymboloccurrenceprobabilities:P(A)=8/20,P(B)=3/20,P(C)=7/20,P(D)=2/20?CS414-Spring2014HuffmanEncodingStatisticaleHuffmanEncoding(Example)P(C)=0.09P(E)=0.11P(D)=0.13P(A)=0.16P(B)=0.51Step1:SortallSymbolsaccordingtotheirprobabilities(lefttoright)fromSmallesttolargestthesearetheleavesoftheHuffmantreeCS414-Spring2014HuffmanEncoding(Example)P(C)HuffmanEncoding(Example)P(C)=0.09P(E)=0.11P(D)=0.13P(A)=0.16P(B)=0.51P(CE)=0.20P(DA)=0.29P(CEDA)=0.49P(CEDAB)=1Step2:BuildabinarytreefromlefttoRightPolicy:alwaysconnecttwosmallernodestogether(e
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2026医务人员手卫生规范
- 贵州省遵义市桐梓县三校联考2026-2027学年高一上学期11月期中英语试卷(含答案含听力原文不含音频)
- 安徽省阜阳市颍上县部分校2026-2027学年九年级上学期11月期中语文试题(含答案)
- 2025-2026学年云南省普洱市墨江县高二(上)期末语文试卷(含答案)
- 2026年消防工程师《消防安全技术实务》模拟试题集
- 2026年播音主持《广播节目主持》专项模拟试卷
- 2025年西宁市检察院书记员招聘笔试真题附答案
- 2026年幼儿教师资格证综合素质测评模拟试题集
- 2026年注册建筑师考试建筑法规与设计原理冲刺押题卷
- 2025年物业总监招聘笔试题与参考答案(城投国企)
- 2026年青岛海检集团有限公司第三批岗位公开招聘笔试参考题库及答案解析
- 欧盟限制在电子电气设备中使用有害物质指令 2011-65-EU 中文版(全文翻译 + 产品合规指南)
- 养老院室内装饰装修施工方案
- 2027年临床医学检验技术(副主任技师)副高面审答辩高频面试题
- 2026年南京大学辅导员考试真题及答案
- 2026语文新教材 1四上第六单元《习作》
- 临终关怀和疼痛管理
- 2026年四川省成都市技能人才评价考评员考试题库(附答案)
- ASTM E165-E165M-24 中文版(一般工业用液体渗透检测标准实施方法)
- 第18课 冷战与国际格局的演变 教学设计2025-2026学年高中历史统编版(2019)必修中外历史纲要下册
- 浙江省财开集团有限公司2026年招聘笔试题库
评论
0/150
提交评论