Leas squares ad moo uo Vascocelos ECE Deparme UCSD
Pla for oda oda we wll dscuss moo esmao hs s eresg wo was moo s ver useful as a cue for recogo segmeao compresso ec. s a grea eample of leas squares problem we wll also wrap up dscusso o leas squares roduce wo pes of moo esmao bloc machg dffereal mehods wll al abou moo ambgues ad local vs global moo
Leas squares a leas squares problem s oe where we have wo varables XY relaed b a uow fuco Y gx a rag se D { } a model Y f;φ where Φ s a vecor of parameers he goal s: o fd he model parameers ha lead o he bes appromao o he observed daa.e. o deerme he caocal eample s he problem of fg a le o a se of pos here * ε m Φ [ f Φ ] Φ a b ad f ; a b a + b 3
Two ma cases o-lear leas squares fφ o lear o Φ e.g. lear leas squares fφ lear o Φ e.g. f ; Φ s f ; Φ s oe: all ha maers s lear o Φ boh olear o oher lear models: polomals sples eural ewors Fourer decomposos ec. 4
5 o-lear leas squares mos dffcul case opmal soluo f ad ol f: grade of ε s zero Hessa of ε egave defe geeral hs has o closed form umercal soluo e.g. grade desce pc al esmae Φ erae < Φ z z z T ε Φ ε ε ε Φ ε ε ε ε ε L L Φ Φ Φ Φ + ε α εφ Φ ε
6 Lear leas squares closed form soluo wre soluo s gve b ormal equaos e.g. for a le f; + Φ Γ Φ Φ f f L T T Γ Γ Γ Φ Γ L
7 Ver powerful Q: wha s he bes lear appromao of a po sequece b DFT sle epoeals? o ge leas squares soluo we eed Γ j e π 4 4 j j j j j j j j j e e e e e e e e e π π π π π π π π π L L L
8 Bes Fourer appromao hs meas ha hs s orhoormal.e. Γ T Γ ad.e. he bes appromao are he DFT coeffces assocaed wh he epoeals Γ j j j j j j e e e e e e 4 4 π π π π π π L L L T T T Γ Γ Γ Γ Φ... e j π
Sgal appromao Q: wha s he bad-pass fler h whose oupu bes appromaes a sgal he frequec rage Ω? we have see ha mus have DFT Y X hece opmal fler has DFT Ω oherwse Ω H oherwse.e. s he deal bad-pass fler of bad Ω uve: deal bes appromao LS sese! 9
oo esmao s a mpora praccal eample of LS problems ma applcaos: recogo: ma eves are characerzed b he pe of moo e.g. walg vs rug srog clues abou scee srucure e.g. whe we roae a 3D objec moo of a pel deermed b how far he 3D po s from camera segmeao hgs ha move ogeher belog o he same objec algme oce we ow he moo we ca alg mages a sequece e.g. he ASA paoramas compresso esmae moo alg mages rasm ol error ec
oo esmao cosder he followg wo mages me
oo esmao cosder he followg wo mages me +
oo esmao goal: gve mages ad + for each pel fd uv whch mmzes dfferece [ u v ] D + problem: mpossble o solve from oe pel aloe wo uows uv oe equao uv -u-v me 3
Fudameal law moo ca ol be solved over a eghborhood eed a leas wo pels maes sese o cosder more ad mmze he average error hs s leas squares ε [ u v + ] uv -u-v me 4
Bloc machg fac s a o-lear leas squares problem sce -u-v s a o-lear fuco of uv soluo : bloc machg for each bloc + do a ehausve search for he closes mach ver commo compresso e.g. PEG 5
Bloc machg s compuaoall esve eed o compue he squared error bewee he bloc ad a colleco of blocs he prevous mage does o alwas produce good moo esmaes e.g. ma maches ca be equall good hs s a problem for all moo esmao mehods: moo ca be ambguous whe measured locall e.g. b machg wdows? 6
oo ambgues clearl we cao deerme he moo of a fla eghborhood for a edge eghborhood we ca ol deerme oe of he wo compoes he wo compoes are uquel defed ol whe he eghborhood coas D mage srucure hs s called he aperure problem?????? 7
8 Dffereal mehods we ca a leas elmae he comple problem b loog for a closed-form soluo o problem: hs s a o-lear fuco of uv soluo: clearl he problem s due o hs equao ca be made lear o uv b a Talor seres appromao v u + [ ] + d d v u * m ε v u v u
9 Dffereal mehods whch leads o oe: we ow how o compue hese erms A s he dfferece bewee cosecuve frames B s.e. a fuco of he mage grade 4444 4 3 4444 4 444 4 3 444 4 B A v u + + + T A + T v u B T
Dffereal mehods we hus have ad he leas squares problem s oe: sce s cosa we om hs s ow lear leas squares we ca jus use our formula recall ha + u v * ε + [ + u + v ]
Lear leas squares f he he LS soluo s: wre soluo s gve b ormal equaos [ ] * m Φ Φ f ε Φ Γ Φ Φ f f L T T Γ Γ Γ Φ
Leas squares soluo for moo sead of we have ad wre [ ] * Φ f ε [ ] * + + v u ε Φ Φ v u f f
3 Leas squares soluo he ormal equaos are leadg o he soluo v u L L L L v u
4 Leas squares soluo whe s hs well defed? oe ha has o be verble urs ou ha hs s a fuco of he mage srucure wh he wdow
Oreao represeaos more geeral queso: wha sors of srucure are here? s commo o descrbe mage paches b he varao of he grade oreao cos. edge flow D mpora pes: cosa wdow small grade mags edge wdow few large grade mags oe dreco flow wdow ma large grade mags oe dreco e.g. har corer wdow large grade mags ha swg e.g. corer 5
epreseg Wdows how ca we deec hese pes of wdows? he e s he mar H wdow T H T H edge ps H #{ edges } how does relae o edges? he aswer s he ra H ver edge horz edge + 6
epreseg Wdows recall: he egevalues of a dagoal mar are he dagoal eres hece: cosa wdow small egevalues edge wdow oe medum oe small flow wdow oe large oe small corer wdow wo large egevalues H wdow H H H H T 7
epreseg Wdows wha abou oher oreaos? useful proper f A s a mar he λλ de A λ + λ a + a race A o have full ra we eed dvers he compoe marces.e. eed edges of dffere oreao H wdow T a a ab H edge b λ a + b ; λ a H ab a + c ab λ λ > a b ab b ab c + b ab b 8
epreseg Wdows summar: cosa wdow small egevalues edge wdow oe medum oe small flow wdow oe large oe small corer wdow wo large egevalues H H H H hs cofrms wha we had alread see: moo ca ol be compued uambguousl whe he eghborhood coas D formao e.g. corers 9
3 summar [UV] lsme w compue grades - for each pel le wdow compue mae U u V v reur UV v u { } w w w w + +
3 Problems recall we used he Talor seres appromao hs s a good appromao ol for small uv o avod hs problem we eed o use pramds v u v u +
Herarchcal esmao algorhm: do moo esmao usg ad o oba u v warp wh u v : wpd -u -v up-sample b o ge wpd warp moo esmao u v do moo esmao usg ad o oba u v warp wh u v warp moo esmao u v ec. wpd... 3
Herarchcal esmao each sage mproves he mach u v soluo: upsample all u v o full resoluo add o oba uv u v + oe ha small dsplacemes a low resoluo are large dsplacemes a full resoluo combes lear wh abl o esmae large dsplacemes... 33
oo models so far we have deal local moo each pel moves b self raslao + u v local moo s he mos geerc e.g. ree leaves blowg he wd oe mpora alerave case s ha of global moo moo of all pels sasfes oe commo equao usuall due o camera moo: pag roao zoomg zoom roao 34
35 mpora cases po a me warped o po a me + mpora global moos are raslao b uv roao b θ scalg b s s j θ uv s + v u ' ' θ θ θ θ cos s s cos ' ' s s ' '
36 Affe rasformaos hese are all specal cases of he affe rasformao moo of ere mage descrbed b Φ abcdef T ca accou for raslao roao scalg ad shear + f e d c b a ' ' raslao roao uform scale ouform scale shearg
37