You are on page 1of 39

DISCRETE COSINE TRANSFORM

Presented by :Avinash Kumar Chaurasia !"""##$ Puneet %u&ta !"""#'(

A)enda
DCT A*)+rithms ,+r -+nventi+na* DCT E.am&*e Dire-ti+na* DCT

DCT
A te-hni/ue ,+r -+nvertin) si)na* int+ e*ementary ,re/uen-y -+m&+nents

0hy 1e need -+m&ressi+n2 The need ,+r su,,i-ient st+ra)e s&a-e3 *ar)e transmissi+n band1idth3 and *+n) transmissi+n time ,+r ima)e3 audi+3 and vide+ data

Prin-i&*es behind -+m&ressi+n

Redundan-y redu-ti+n Aims at rem+vin) du&*i-ati+n ,r+m the si)na* s+ur-e Irre*evan-y redu-ti+n It +mits &arts +, the si)na* that 1i** n+t be n+ti-ed by the si)na* re-eiver4

C+din)
Predi-tive C+din) - In &redi-tive -+din)3 in,+rmati+n a*ready sent +r avai*ab*e is used t+ &redi-t ,uture va*ues3 and the di,,eren-e is -+ded4 Trans,+rm C+din) - Trans,+rms the ima)e ,r+m its s&atia* d+main re&resentati+n t+ a di,,erent ty&e +, re&resentati+n usin) s+me 1e**5n+1n trans,+rm and then -+des the trans,+rmed va*ues 6-+e,,i-ients7

C+ntinued44
Trans,+rm -+din) re*ies +n the &remise that &i.e*s in an ima)e e.hibit a -ertain *eve* +, -+rre*ati+n 1ith their nei)hb+rin) &i.e*s C+nse/uent*y3 these -+rre*ati+ns -an be e.&*+ited t+ &redi-t the va*ue +, a &i.e* ,r+m its res&e-tive nei)hb+urs4

One-Dimensional Discrete Cosine Transform


The DCT can be written as the product of a vector (the input list) and the n x n orthogonal matrix whose rows are the basis Vectors. 0e -an ,ind that the matri. is +rth+)+na* And ea-h basis ve-t+r -+rres&+nds t+ a sinus+id +, a -ertain ,re/uen-y4 The )enera* e/uati+n ,+r a "D 6N data items7 DCT is de,ined by the ,+**+1in) e/uati+n:

1here 3

This e/uati+n e.&resses F as a *inear -+mbinati+n +, the basis ve-t+rs4 The -+e,,i-ients are the e*ements +, the inverse trans,+rm3 1hi-h may be re)arded as re,*e-tin) the am+unt +, ea-h ,re/uen-y &resent in the in&ut F.

The one dimensional DCT is useful in processing one dimensional signals such as speech waveforms. For anal!sis of two dimensional ("D) signals such as images# we need a "D version of the DCT.

The Two-Dimensional DCT


"D DCT is a&&*ied t+ ea-h r+1 +, F and then t+ ea-h -+*umn +, the resu*t4The )enera* e/uati+n ,+r a 'D 6N by $ ima)e7 DCT is de,ined by the ,+**+1in) e/uati+n:

and the -+rres&+ndin) inverse 'D DCT trans,+rm is sim&*e F %6u3v73 1here

The e/uati+ns are )iven by:

Sin-e the 'D DCT -an be -+m&uted by a&&*yin) "D trans,+rms se&arate*y t+ the r+1s and -+*umns3 1e say that the 'D DCT is separable in the t1+ dimensi+ns4

A Typical Lossy Signal/Image Encoder

S+ur-e En-+der 6+r 8inear Trans,+rmer7 used is Dis-rete C+sine Trans,+rm 6DCT7 9uanti:er -A /uanti:er sim&*y redu-es the number +, bits needed t+ st+re the trans,+rmed -+e,,i-ients by redu-in) the &re-isi+n +, th+se va*ues4 9uanti:ati+n -an be &er,+rmed +n ea-h individua* -+e,,i-ient3 1hi-h is 5n+1n as S-a*ar 9uanti:ati+n 6S974

C+ntinued 444

Entr+&y En-+der - An entr+&y en-+der ,urther -+m&resses the /uanti:ed va*ues *+ss*ess*y t+ )ive better +vera** -+m&ressi+n by a--urate*y determine the &r+babi*ities ,+r ea-h /uanti:ed va*ue and &r+du-es an a&&r+&riate -+de based +n it3 s+ that the resu*tant +ut&ut -+de stream 1i** be sma**er than the in&ut stream

e)4 ;u,,man en-+der and the arithmeti- en-+der4

DCT-based are either -+m&ressed entire*y +ne at a time3 +r are -+m&ressed by a*ternate*y inter*eavin) $.$ sam&*e b*+-5s ,r+m ea-h in turn4 F+r a ty&i-a* $.$ sam&*e b*+-5 ,r+m a ty&i-a* s+ur-e ima)e3 m+st +, the s&atia* ,re/uen-ies have :er+ +r near-:er+ am&*itude and need n+t be en-+ded4 DCT intr+du-es n+ *+ss t+ the s+ur-e ima)e sam&*es4 DCT merely transforms them to a domain in which they can be more efficiently encoded. The DC coefficient, which contains a significant fraction of the total image energy, is differentially encoded. Entropy Coding EC! achie"es additional compression losslessly by encoding the #$anti%ed DCT coefficients more compactly based on their statistical characteristics.

&hile the DCT'based image coders perform "ery well at moderate bit rates, at higher compression ratios, image #$ality degrades beca$se of the artifacts res$lting from the bloc('based DCT scheme.

Pr+&erties +, DCT
De-+rre*ati+n - The &rin-i&*e advanta)e +, ima)e trans,+rmati+n is the rem+va* +, redundan-y bet1een nei)hb+urin) &i.e*s4 This *eads t+ un-+rre*ated trans,+rm -+e,,i-ients 1hi-h -an be en-+ded inde&endent*y4

Ener)y C+m&a-ti+n - DCT e.hibits e.-e**ent ener)y -+m&a-ti+n ,+r hi)h*y -+rre*ated ima)es4 The un-+rre*ated ima)e has its ener)y s&read +ut3 1hereas the ener)y +, the -+rre*ated ima)e is &a-5ed int+ the *+1 ,re/uen-y re)i+n4

C+ntinued44
Orth+)+na*ity - IDCT basis ,un-ti+ns are +rth+)+na* 4 Thus3 the inverse trans,+rmati+n matri. +, A is e/ua* t+ its trans&+se i4e4 invA< A=4 Se&arabi*ity > Per,+rm DCT +&erati+n in any +, the dire-ti+n ,irst and then a&&*y +n se-+nd dire-ti+n3 -+e,,i-ient 1i** n+t -han)e

Advanta)es and Disadvanta)es


The DCT d+es a better ?+b +, -+n-entratin) ener)y int+ *+1er +rder -+e,,i-ients than d+es the DFT ,+r ima)e data

The DCT is &ure*y rea*3 the DFT is -+m&*e.4

Assumin) a &eri+di- in&ut3 the ma)nitude +, the DFT -+e,,i-ients is s&atia**y invariant 4 This is n+t true ,+r the DCT

Dire-ti+na* Dis-rete C+sine Trans,+rms Near*y a** b*+-5 based trans,+rm te-hni/ues uses "D DCT +r 'D DCT i4e C+nventi+na* DCT

@ut Ima)e b*+-5s may -+ntain ed)es in dire-ti+n +ther than h+ri:+nta* and verti-a*

In+rder t+ im&r+ve -+din) &er,+rman-e 1e use dire-ti+na* DCT in ab+ve -ases

C+ntinued44
The -+nventi+na* NAN '-D DCT is a*1ays im&*emented se&arate*y by t1+ N &+int "-D DCTs 'D -+nventi+na* DCT may -ause s+me de,e-ts 1hen it is a&&*ied t+ an ima)e b*+-5 in 1hi-h +ther dire-ti+na* ed)es d+minate I, 1e a&&*y "D DCT then 1e )et s+me n+n:er+ -+e,,i-ient that are n+t a*i)ned a,ter a&&*yin) se-+nd "D DCT 1e may &r+du-e m+re n+n:er+ -+e,,i-ients4

Dire-ti+na* DCT

Dire-ti+na* DCT ,+r the Dia)+na* D+1n-8e,t M+de A*)+rithm "4 The ,irst "-D DCT 1i** be &er,+rmed a*+n) the dia)+na* d+1n-*e,t dire-ti+n4 A** +, the -+e,,i-ients are e.&ressed in )r+u& +, -+*umn ve-t+r '4 Se-+nd "-D DCT is a&&*ied t+ ea-h r+1 B4Then &ush the -+e,,i-ients t+ h+ri:+nta**y *e,t (4Per,+rm :i):a) s-annin) t+ -+nvert 'D -+e,,i-ient b*+-5 int+ "D se/uen-e

Pr+b*ems

Mean 0ie)htin) de,e-t

S+*uti+n t+ ab+ve ste& usin) dia)+na* *en)th 1i** &r+du-e n+ise 1ie)htin) de,e-t

S+*uti+n
9uanti:ed mean va*ue +, ima)e b*+-5 is subtra-ted ,r+m ima)e b*+-5 A&&*y dia)+na* *e,t DCT A&&*y se-+nd "D DCT h+ri:+nta**y and -+e,,i-ients are &ushed t+ *e,t

Re,ren-es

"4htt&:CC1114-s4-,4a-4u5CDaveCMu*timediaCn+de'B"4htm* '4htt&:CC1114y+utube4-+mC1at-h2v<h)rDO#du-s) B4htt&:CC1isnet4see-s4edu4&5C&ub*i-ati+nsCte-hEre&+rtsCDCTETR$#'4&d, (4 Directional Discrete Cosine TransformsA New Frame1+r5 ,+r Ima)e C+din) by @in) Fen)# $ember# &'''3 and Gin)?in) Fu
htt&:CCieee.&*+re4ieee4+r)Cstam&Cstam&4?s&2t&<Harnumber<(((!(I#Hisnumber<((I!D!I

End 9uesti+ns22

You might also like