regenerating - stanford...

11
C 52501 EE 387 - LECTURE 17 - RS codes as Regenerating codes - AGENT . TODAYSTERMITETIDBITG.tw#a:aionmfnoi:ei..aeitg : disabled storage / : ?÷÷÷mIi÷!÷:÷÷Iz÷ :& : :/ RS codes area bad idea for distributed storage , are made mostly out of poop ) are RS codes are a great idea for distributed storage . great fertilizer ! ÷÷÷÷f÷÷¥÷ COURSE RECAP - µ i÷!;;÷Y÷ , " APPLICATION ( ? ) of LOCALITY So far , were seen LCC 's , which have the following property : i t ene , codeword c e fraction of aedvmergan.at h?fo * This seems like it should come in handy in the following DISTRIBUTED STORAGE setting : encode with (F) = ( x , , . . . , Xk ) E ttgk cc , .cz , . . , cut C- IF n I STORE on n different nodes I . . FIFI I each node also holds some other stuff , say encodings of other files in the system . . . but let 's just focus on one file . )

Upload: others

Post on 10-Mar-2020

4 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

C52501 EE 387 - LECTURE 17 - RS codes as

Regeneratingcodes

-

AGENT .

TODAYSTERMITETIDBITG.tw#a:aionmfnoi:ei..aeitg: disabled storage

/ :?÷÷÷mIi÷!÷:÷÷Iz÷:&:

:/

① RS codes area bad idea for distributed storage,

are made mostly out of poop) are

③ RS codes are a greatidea for distributed storage . great fertilizer ! ÷÷÷÷f÷÷¥÷

'

④ COURSE RECAP-

µ i÷!;;÷Y÷ ,

"

⑧ APPLICATION ( ? ) of LOCALITY.

So far,

were seen LCC 's,

which have the following property :

i

tene ,

← codeword c

e fraction

ofaedvmergan.at

h?fo

*

This seems like it should come in handy in the following DISTRIBUTED STORAGE

setting :

encodewith

(F) = ( x, , . . .

, Xk) E ttgk 1¥ cc, .cz ,

. . .

, cut C- IFn

I STORE on n different nodes

I . . FIFIIeach node also holds some other stuff , say encodings of other

files in the system . . . but let 's just focus on one file .)

Page 2: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

Nowsuppose that a server fails

,

and lid like to repair it to maintain the system .

I . . . FIFI[this

guyis down

.

OPTION 1 : Download all the -

-(say furlong enough that

Survivingblocks and we don't want to wait

correct the error.

fvitlowme backup ) .

I . . - FIFI/

:* .

/

TX

-

0¥ : LOCALLY Correct the error,

and download just the blocks youneed to do that

.

FIFI . i FI| ¥t÷EnTF /

-

It hems out that communication is EXPENSIVE land is a bottleneck in distributedstorage systems

so this is a win.

Page 3: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

① What's the model here ?

LOCALITY seems useful.But are Kcs the

righttool for the job ?

ANSWER : Not really .

yay}The right model is ERASURES

,not ERRORS

.

* Based on a study98% of the time

't

, onlyONE server is down

. of the Facebook

Warehouse cluster.

Instead what do we want ?

(1) Best trade-off between RATE and DISTANCE possible - aka an MDS code.

• We want to handle asmany

failures as possible in the worst case .T

Recall this

Means

(2) Every symbol can be obtained from not - too -

manyother symbols .

n - htt .

- d

. When there is only 1 failure ,we'd like to repair it with

minimal communication.

② RS CODES area BAD IDEA for DISTRIBUTED STORAGE.

Sam(1) MDS Code y

•121 Every symbol can be obtained by not - toomany

other symbols •121 doesn't hold :

. Suppose fete Cx ],degffkk .

• I NEED k evaluation pts flat , . . .

,flak ) to say ANYTHING atall about fldkti )

eg , supposef (X ) is a quadratic and goes through

these 2 points :

/

what is flag ) ? COULD BE ANYTHING. •

#d, da b

Page 4: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

-

CLAIM : Given any k - I symbolsof

an RS codeword c,

ahe "

symbol could be anything in Fg .*Pbypiue :

k

-1a,a,

'. . . a

,

k - I fo

f,

I d a'

:

µ¥:÷¥¥t¥¥::: :: : :: :

.

/

(RS generator matrix

I

Now this kxk matrix µ is full rank,

so for ANY value of D?,

I

#

there is some Cfo,

. . .

,fu

. , ) that is consistent.

So D? could beanything .

-

What does this mean for RS codes ?

We need toquery

k symbols just to get one - but k is

enoughto recover the whole

message!

So that's really wasteful .

Page 5: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

So can we find some other code satisfying (1) and (2) ?

NO !Actually that argument works for any MDS code

,not just RS codes . So :

forIf (1) MDS Code y

then KI Every symbol can be obtained by not - too .

manyother symbols Ahh•

TWO WAYS around this :

WAY I : Give up on MDS.

← This is really interesting andthe buzzword

WAY 2 : Rephrase (2) C is"

Locally Recoverable Code .

" We won't

talk about it.I

We will talk about this.

We will instead shoot for :

(1) MDS Code

KI Every symbol can be obtained by not - too -

ManyBITS from other symbols .

Inpictures the model is this :

/

"÷:* :*

'O?;w .

£

.o

in'

÷÷÷:÷÷÷÷i÷l

T#

Page 6: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

Such a code is called a REGENERATING CODE.

There's tons of super cool work on these that I won't talk about .

But for today . . .

-

TH Reed-Solomon Codes ARE good regeneratingcodes-

③ RS CODES are a GREAT IDEA for distributed storage!

For simplicity let 's focus on k -

- n k, n=q , q=2t .

So a codeword of Rsg ( Fg , q ,9k ) looks like :

€tE¥F-

for a primitive It 8 .

✓Works with any

node,

Say f(O) fails .

but for concreteness sayit's fCO ) .

-

(which we will show )

|rHecispysfibYbdownload0NEBttfomfHilbri⇒..,qaa

Notice this is g-I BITS Hal

,while the naive scheme would download

k-

- 812 whole symbols , each are lglq) bits - so that's giggled .

So the CLAIM is BETTER than the naive scheme !

-

CLAIM Cwhich we will not show )

TThisisoplimalt.tt#*8::nliiggrssYomee

:

Page 7: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

Toprove

the first CLAIM,we will need the following algebra

facts :

-

FACT : Fat is a vector space over ft .

So we can think of a c- HIT as a vector I e HIT if we want .

( of course,this is for the additive structure

only)

.

FACI.LetPN-XTX.tl/4t---tXat?-TheTp : Azt → Ez is HE - linear

.

Ca)

aka, Platelet de Eze

,

and Plhtpt Platt Plp)

(b) All Az - linear As y : HI. → E have the form 41×1 = Ply . X ) for some geftzt .

µ

µ ,

many.

we ,µµµµ , , p , , p , a , , , ,p , qq.pe#a,

.

y

- \In fact

,there always

exists I basis so

( PIX) is usually called the"

field truce ! ) that if I is a

written out wlrlt this

I basis, then

"

Pf' ' of FACT la) : Pla .pl -

- LI, B >

-

To see Ratp ) = Platt Plp),

recall ( atp )2=x2tp2 in tze.

= Eitidipsi

|

toseeplxk-fz.no/iaPlN2=PlN.whichisonlytruefor0an#

Page 8: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

Now that wehave these facts

,we can prove

the CLAIM.

Recallg-Lt

.

-

By RS duality ,RS

,f Fg , g. E)

t= Rsg fAT , g. E)

So for all f.ge HTCX ] w/ degree < he 812,

O = I Haigh )t Efg

Hot go ) -

- E'

f-

HIGHLE HIKO )

-

forany fete ,

letgy ( X )

-

- PlS = gt X t Xs txt . . . + xd"

- I

.

Then deglgg ) = 2" '

- I = I - I -

- k - 1.

#

So we may plugin g ,for

gabove :

t fetfqfx ] st. degtfkaok :

Hot.gg/0l--&fqyogfHtggkl Plugin ggfrg

Ho ) . y =

§÷qq ,flat . PILI Def of gg

Pfffotg ) = P ( €qµ ,

flat - PII ) Take PH on both sides

Pl Holy ) -

-

1¥,

Pl flat . PILI ) Phish . linear

--

( Hot,5) =£qw ( flat , PILI ) Pla .

p) - CI ,pT, morally

(Hot , 5) = Imo Ptsd) ( HII . PGH EE, so

its just a scalar.

Page 9: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

So for all g e Fat,we

have

Alot is > = Imo PGH SHI .

Recall the goal is to find f lol.

So the algorithm is :

fThis isasonpenbimtia

node

'

H"""t""h"€"• The node holding flat returns b.

= ( HI,

E Fa

| . We compute Lei ,

HOT > =

affronts "i b

.t IF

top! !!! ! !:÷⇐*;. Let Ho) -

- ( Kei,

HID,Lei

,

Hot >, .

. .

,Lei

,

HOT >)-

That's it ! This feels a bit magical , but actually it generalizes to some other parameter regimes

and also turns out to be optimal !

See [ Guru swami , W .

'16 ]

,[ Dau

,Milenkovic ' 173

,[Tano . Ye -

Barg' 17 ] for more .

-

The point :#

finis:*:÷÷÷÷:÷::÷a÷:÷÷÷ : :S :c:* :*:* :: " . I

• Also,

this is kind of a neat fact about polynomial interpolation .

-

Page 10: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

④ COURSE RECAP.

This is the last lecture . . . WHAT HAVE WE LEARNED ?

-

WHATHA-VEWELEN-RNED.rs

• Fundamental trade - offs between RATE and DISTANCE. The " correct " trade -

off for binary codes is stillopen ,

but over large alphabets

it is attained by . . .

• REED - SOLOMON CODES and"

LOW - DEGREE POLYS DON 'T

- OMG the BEST code ! HAVE TOO MANY ROOTS.

"

• How to decode RS codes,

and how to use this to get efficientlydead able binary codes .

• Reed - Muller,

BCH,

concatenation,

ohmy!

I

:÷:÷÷÷÷÷i÷÷÷:÷÷:÷÷÷÷÷i:÷:÷÷÷÷÷÷÷

:

::÷÷÷::÷:÷÷÷

:L

' We talked about RM codes and locality !

. Plus,local - list - decoding

,and just now regenerating

codes !

'

Along the way ,APPLICATIONS !

.

Crypto , Compressed Sensing ,Group testing , Heavy Hitters , Learning theory ,

Storage , ( communication,OR codes

,hat puzzles

,. . .

)

-

Page 11: Regenerating - Stanford Universityweb.stanford.edu/~marykw/classes/CS250_W19/lectureNotes/Lecture17... · Sucha code iscalled a REGENERATING CODE There'stonsof super coolwork on thesethat

-

THE MORAL Is) of the STORY :

HI Low - degree polynomials don't have too manyroots

.

÷÷÷÷÷÷:÷÷÷÷÷÷i÷m

QUESTIONto PONDER

What can error correctingcodes do for

you?