FEC & File Multicast

24
ECC Applications ECC Applications and Simulation and Simulation Multicast Methods Using Multicast Methods Using ECC ECC Yossi Cohen & Yitzhak Yossi Cohen & Yitzhak Aviv Aviv

description

Review on file multicast techniques using Forward Error Correcting codes

Transcript of FEC & File Multicast

Page 1: FEC & File Multicast

ECC Applications and ECC Applications and SimulationSimulation

Multicast Methods Using ECCMulticast Methods Using ECC

Yossi Cohen & Yitzhak AvivYossi Cohen & Yitzhak Aviv

Page 2: FEC & File Multicast

MotivationMotivationWhy look at applications?Why look at applications? We have already looks at the inner working of the We have already looks at the inner working of the

codes and the results of small scale simulations. codes and the results of small scale simulations. Looking at the application will help us broaden our Looking at the application will help us broaden our knowledge and review results of large scale knowledge and review results of large scale simulations.simulations.

Why look at Multicast file transfer?Why look at Multicast file transfer? The multicast scheme should be smart enough to The multicast scheme should be smart enough to

compensate not just for the characteristics of a single compensate not just for the characteristics of a single channel as is the case in classical communication, but channel as is the case in classical communication, but for characteristics of many channels that are varying for characteristics of many channels that are varying over time.over time.

Multicast file transfer application are gaining Multicast file transfer application are gaining popularity. They are used in many areas from popularity. They are used in many areas from software update to peer-to-peer networking.software update to peer-to-peer networking.

Page 3: FEC & File Multicast

What is multicast ?What is multicast ?When many users need the same info at the same time it is better to When many users need the same info at the same time it is better to duplicate the packets in the last router rather then send it separately to duplicate the packets in the last router rather then send it separately to each user.each user.Topics need to be considered:Topics need to be considered:

Group membership managementGroup membership management Routing management protocolsRouting management protocols Loss notificationLoss notification Loss HandlingLoss Handling

Page 4: FEC & File Multicast

TaxonomyTaxonomy Multicast

FEC

SomeCastSRM

RMTPDigital

Fountain

CyclicUDP

Feedback Hybrid

MFTP/EC

No Feedback No ECCNo Feedback No ECC Cyclic UDP Cyclic UDP

ECC without feedbackECC without feedback Reed-Solomon on the Reed-Solomon on the

entire fileentire file Reed-Solomon on Reed-Solomon on

BlocksBlocks tornado coding on the tornado coding on the

file (Digital fountain file (Digital fountain approach)approach)

Feedback without FECFeedback without FEC MFTPMFTP

Hybrid methods FEC & Hybrid methods FEC & feedbackfeedback

MFTP/ECMFTP/EC SomeCastSomeCast

Page 5: FEC & File Multicast

File Multicast Solution Requirements File Multicast Solution Requirements

ReliableReliable – Guarantee file delivery to all the receivers. – Guarantee file delivery to all the receivers. EfficientEfficient – The total number of packets that each client – The total number of packets that each client receives and the amount of processing needed to receives and the amount of processing needed to construct the file from these packets should be minimal.construct the file from these packets should be minimal.On-DemandOn-Demand – clients may initiate a download at their – clients may initiate a download at their discretion. The session may be interrupted several discretion. The session may be interrupted several times.times.VersatileVersatile – the protocol should tolerate a heterogeneous – the protocol should tolerate a heterogeneous population of receivers over a variety of connection population of receivers over a variety of connection types: wireless, satellite, wire-line with different packet types: wireless, satellite, wire-line with different packet loss statistics. loss statistics.

Page 6: FEC & File Multicast

Quality of the solutionQuality of the solution

The solution should have a minimum average time till The solution should have a minimum average time till the file can be in use at the user computer:the file can be in use at the user computer:

There is usually a tradeoff between fast decoding There is usually a tradeoff between fast decoding algorithms (such as tornado coding) and the algorithms (such as tornado coding) and the transmission overhead they cause.transmission overhead they cause.

total rec dect t t

Page 7: FEC & File Multicast

Why use FEC in multicast?Why use FEC in multicast?

The multicast group interface solved the problem of multiple packets The multicast group interface solved the problem of multiple packets that hold the same information from originating from the sender. that hold the same information from originating from the sender. However there is still a problem of too many NACKs or ACKs However there is still a problem of too many NACKs or ACKs originating from the receivers. This problem is known as originating from the receivers. This problem is known as “NACK “NACK implosion”implosion”

Several methods exist to solve this problem:Several methods exist to solve this problem: Creating local point of control that would handle the NACKs.Creating local point of control that would handle the NACKs. Back off NACK timing (SRM for example).Back off NACK timing (SRM for example). FECFEC

Advantages of FECAdvantages of FEC Enable reliable multicast when there is no back channel.Enable reliable multicast when there is no back channel. No processing overhead in control points.No processing overhead in control points. Very low ECC reception overhead (In tornado codes ~0.05)Very low ECC reception overhead (In tornado codes ~0.05)

Page 8: FEC & File Multicast

Erasure advantage over errorErasure advantage over error

In this type of computer communication we don’t consider In this type of computer communication we don’t consider errors, a packet is either received correctly or not received errors, a packet is either received correctly or not received – an erasure. Bad packets are removed on lower network – an erasure. Bad packets are removed on lower network layers by comparing them to the CRC.layers by comparing them to the CRC.Next we will explain the advantages of erasures over Next we will explain the advantages of erasures over errors. errors. Block Code: C (n ,k ,d)Block Code: C (n ,k ,d)Error correction capability:Error correction capability:Code Rate:Code Rate:““Singleton Bound” on minimum distance:Singleton Bound” on minimum distance:

d ≤ n-k+1d ≤ n-k+1MDS (maximum distance separable): Code that achieves MDS (maximum distance separable): Code that achieves the Singleton Bound.the Singleton Bound.

1

2

dt

R k n

Page 9: FEC & File Multicast

Reed-Solomon CodeReed-Solomon Code

Block code => cyclic code => BCH code => Block code => cyclic code => BCH code => reed-Solomon code.reed-Solomon code.Code Code RS(n,k)RS(n,k) is a MDS code: is a MDS code: d=n-k+1d=n-k+1

RS code is over q-ary alphabet, usually:RS code is over q-ary alphabet, usually: where m is the symbol size where m is the symbol size

Algebraic code – easy to implement.Algebraic code – easy to implement.Can decode erasures.Can decode erasures.

1

2 2RS

d n kt

2 1mn

2mq

Page 10: FEC & File Multicast

Performance Computation:Performance Computation:

For error and erasure situation: RS(n,k) can correct ‘r’ errors and ‘s’ erasures if:For error and erasure situation: RS(n,k) can correct ‘r’ errors and ‘s’ erasures if:

IDP

definitionsdefinitions - Pr {correct decode}- Pr {correct decode} - Pr {incorrect decode}- Pr {incorrect decode} - Pr {fail to decode}- Pr {fail to decode} - Pr {not correct decode}- Pr {not correct decode} - Pr {symbol error}- Pr {symbol error}

CDP

DFP1NCD CDP P

1CD ID DFP P P

NCDP

eP

1

1n n n ii

ii t

iPe

n

For errors only situation:For errors only situation:

2 r s d

Page 11: FEC & File Multicast

Decoder

1-epsilon

epsilon

1-epsilon

epsilon

'0''0'

'1''1'

'0'

'1' '1'

'0'

E

1-p-lamda

lamda

p

p

lamda

1-p-lamda

Decoder

Erasureflagger(lamda,phi)

Model I

Model II

Model ConversionModel Conversion

pp= = εε(1-(1- δ δ))=Pr{ error}*Pr{ no-erasure |error}=Pr{ error}*Pr{ no-erasure |error}

λλ= = εδεδ+(1-+(1-εε)) Φ Φ =Pr{error} * Pr {erasure|error} + Pr{ no-error} * =Pr{error} * Pr {erasure|error} + Pr{ no-error} *

Pr{erasure|no-error}Pr{erasure|no-error}

definitionsdefinitions δδ = Pr {detection} = Pr {detection} ΦΦ = Pr {false alarm} = Pr {false alarm} εε = Pr {symbol error before = Pr {symbol error before

decoding}decoding} λλ = Pr {erasure} = Pr {erasure}

Page 12: FEC & File Multicast

Performance ComputationPerformance Computation

,

!

! ! !

n

r s

n

r s n r s

2 1

,0 0

, , , 1t d r n n r sII I r s

r sr s

Pcd Pcd p p p

p=ε(1- δ)

λ= εδ+(1-ε) Φ

1NCD CDP P

Page 13: FEC & File Multicast

Burst and Random errors situationBurst and Random errors situation

= Pr {burst of m errors}.= Pr {burst of m errors}.

= Pr{ not-correct given m errors}.= Pr{ not-correct given m errors}.

The m-errors effectively reduce the code’s The m-errors effectively reduce the code’s minimum distance by 2m, hence:minimum distance by 2m, hence:

0

n

m

Pnc Pnc m Pm

2 2 2 1

,0 0

1mt d m r n n r sr s

r sr s

Pcd m p p

( )NCP m

( )P m

2

2 1

2m

d mt

Page 14: FEC & File Multicast

Burst and Random errors situation –cont’Burst and Random errors situation –cont’

With perfect detection (With perfect detection (δδ=1) =1) dd reduced just by reduced just by m, hence:m, hence:

We will now see howWe will now see howmulticast communicationmulticast communication

protocols use this protocols use this advantage.advantage.

2 1

,0 0

1mt d m r n n r sr s

r sr s

Pcd m p p

1

2m

d mt

Probability of not correct decoding for error Probability of not correct decoding for error only (blue) and erasure (red) decoding.only (blue) and erasure (red) decoding.

Page 15: FEC & File Multicast

Digital Fountain approach Digital Fountain approach

Tornado coding are based on XOR. Tornado coding are based on XOR. They are a class of They are a class of LDPC codes LDPC codes introduced in the last lecture. introduced in the last lecture. Why Tornado?Why Tornado?

Very fast decoding.Very fast decoding. Sometimes one received packet can Sometimes one received packet can

cause the decoding of a packet that cause the decoding of a packet that was needed to decode another was needed to decode another packet…this creates a packet…this creates a whirlwindwhirlwind of of decoded packets. Hence the name.decoded packets. Hence the name.

The method : The method : The file is divided to K packets. Unlike The file is divided to K packets. Unlike

Reed-Solomon that can reconstruct the Reed-Solomon that can reconstruct the file from any K packets, Tornado codes file from any K packets, Tornado codes needs an epsilon more (about 0.05).needs an epsilon more (about 0.05).

After approximately K + packets a After approximately K + packets a receiver would be able to reconstruct receiver would be able to reconstruct the file.the file.

LDPCLDPC

TornadoTornado

RSRS

OperationOperation XORXOR

++

FieldField

--

ComplexityComplexity Very lowVery low

++

HighHigh

--

Decoding Decoding timetime

Very fastVery fast

++

Relatively Relatively slowslow

--

Length (k/n)Length (k/n) K(1+eps)K(1+eps)

--

KK

++

Bipartitegraph

Bipartitegraph

Standardloss-resilient code

= message

= redundancy

Page 16: FEC & File Multicast

ECC methodsECC methods

Reed-Solomon on the entire fileReed-Solomon on the entire file TTrecrec is minimal since any k packets is minimal since any k packets

from a file of size k are enough to from a file of size k are enough to reconstruct the file. However for large reconstruct the file. However for large files tfiles tdecdec would be the largest would be the largest

Reed-Solomon on Blocks.Reed-Solomon on Blocks. In order to decrease tIn order to decrease tdecdec the files is the files is

divided to blocks and RS-Coding are divided to blocks and RS-Coding are applied on each block separately.applied on each block separately.

tornado coding on the file (Digital tornado coding on the file (Digital fountain approach)fountain approach)

tornado coding is done on the entire tornado coding is done on the entire file Tfile Trecrec is slightly larger than that of RS is slightly larger than that of RS however thowever tdecdec is much smaller. is much smaller.

Wasted packets

Epsilonpackets

Page 17: FEC & File Multicast

Simulation and resultsSimulation and results

Simulation were done using Simulation were done using backbone multicast traces that backbone multicast traces that were used with proprietary were used with proprietary software. software. RS Coding the entire file.RS Coding the entire file.

Advantage – any K packets can be Advantage – any K packets can be used to reconstruct a file with K used to reconstruct a file with K packets size.packets size.

Disadvantage – very long decoding Disadvantage – very long decoding time.time.

Reed – Solomon on blocksReed – Solomon on blocks Advantage –smaller decoding time Advantage –smaller decoding time

then previous optionthen previous option disadvantage – needs more then k disadvantage – needs more then k

packets to reconstruct a file with packets to reconstruct a file with this size.this size.

Speedup factor for Tornado Z

0

50

100

150

200

250

0.01 0.05 0.1 0.2 0.5

Erasure probabilities

Size

250KB

500KB

1MB

2MB

4MB

8MB

16MB

Comparison chartComparison chartBy forcing the same By forcing the same

reception time (receiving reception time (receiving and decoding)and decoding)

Page 18: FEC & File Multicast

Article analysisArticle analysis

Major hurdle for RS - Decoding time. However, Major hurdle for RS - Decoding time. However, decoding time is considered cheaper than bandwidth decoding time is considered cheaper than bandwidth (up to a limit). Since computing power is constantly (up to a limit). Since computing power is constantly rising (Moor’s law) the differences between tornado rising (Moor’s law) the differences between tornado and RS would get smaller and smaller. If the tests and RS would get smaller and smaller. If the tests were made today the results would have been less were made today the results would have been less conclusive.conclusive.

Page 19: FEC & File Multicast

Future trendsFuture trends

More articles for cellular devices multicast where More articles for cellular devices multicast where computing power is more scarce and channels are more computing power is more scarce and channels are more prone to errors.prone to errors.

Creating the basis for layered multicast analysisCreating the basis for layered multicast analysis

In this method the sender transmit the information in In this method the sender transmit the information in different layers each with its own multicast address. different layers each with its own multicast address. Each receivers choose the number of layers it will Each receivers choose the number of layers it will receive according to its bandwidth. This way enables receive according to its bandwidth. This way enables some measure of congestion control like in TCP.some measure of congestion control like in TCP.

This trend is followed by protocols like RMDP and Fine This trend is followed by protocols like RMDP and Fine grained layered multicast (by the same authors).grained layered multicast (by the same authors).

Page 20: FEC & File Multicast

MFTP - DescriptionMFTP - Description

Multicast File Transfer Protocol.Multicast File Transfer Protocol.Using hierarchical NACKs to ask for packets that Using hierarchical NACKs to ask for packets that were not received.were not received.After finishing the first transmission round the After finishing the first transmission round the server resends packets that were not received server resends packets that were not received again in rounds till all receivers received the file.again in rounds till all receivers received the file.MFTP/EC – uses Reed-Muller codes to send the MFTP/EC – uses Reed-Muller codes to send the packets that were not received.packets that were not received.As you would expect MFTP/EC was proven to As you would expect MFTP/EC was proven to be a lot better then MFTP.s.be a lot better then MFTP.s.

Page 21: FEC & File Multicast

Simulation and resultsSimulation and results

MFTP and MFTP/EC were MFTP and MFTP/EC were simulated using both the NS-2 simulated using both the NS-2 network simulator & MBone network simulator & MBone traces. Results were roughly traces. Results were roughly the same.the same.

The NS-2 enables simulations The NS-2 enables simulations of complex network protocols. of complex network protocols. Including multicast and Including multicast and wireless.wireless.

NS-2 enables programming of NS-2 enables programming of new protocols and behaviors. new protocols and behaviors. For example user roaming and For example user roaming and power decrease and error power decrease and error increase due to range from bts increase due to range from bts in wireless simulation. in wireless simulation.

C++

otcl

Page 22: FEC & File Multicast

Simulation and resultsSimulation and results

With the years a multitude of tools With the years a multitude of tools were added to the NS simulator, were added to the NS simulator, which include (among others):which include (among others):

NAM – the network animator, which NAM – the network animator, which draws the networks and the passing draws the networks and the passing packets.packets.

Tiers, Inet, gt-ITM – for network Tiers, Inet, gt-ITM – for network topology generation.topology generation.

Scenario Generator – for scenario Scenario Generator – for scenario generation.generation.

tcl8.0

otcl

tclcl

ns-2EventScheduler

Netw

orkC

omponent

Page 23: FEC & File Multicast

Criticism Criticism

If the idea of sending FEC is so good then why If the idea of sending FEC is so good then why isn’t it used from the start :isn’t it used from the start : Sending the packets as FEC from the start and save Sending the packets as FEC from the start and save

the NACK and overheadthe NACK and overhead

The results were compared to regular MFTP so The results were compared to regular MFTP so of course there would be an improvement.of course there would be an improvement.

Page 24: FEC & File Multicast

ReferencesReferences

[1] [1] Feasibility Study of Erasure Correction for Multicast File Distribution Feasibility Study of Erasure Correction for Multicast File Distribution using the Network Simulator ns-2 using the Network Simulator ns-2 (1998) Christoph Hänle (1998) Christoph Hänle [2] [2] RMDP: an FEC-based Reliable Multicast protocol for wireless enviroRMDP: an FEC-based Reliable Multicast protocol for wireless environments nments (1998) Luigi Rizzo Lorenzo Vicisano(1998) Luigi Rizzo Lorenzo Vicisano[3] [3] A Digital Fountain Approach to Reliable Distribution of Bulk DataA Digital Fountain Approach to Reliable Distribution of Bulk Data / / John W. Byers, Michael Luby, Michael Mitzenmacher, Ashutosh John W. Byers, Michael Luby, Michael Mitzenmacher, Ashutosh Rege Proceedings of ACM Sigcomm '98, Vancouver, Canada, Rege Proceedings of ACM Sigcomm '98, Vancouver, Canada, September 1998. September 1998. [4] [4] SomeCast A Paradigm for Real-Time Adaptive Reliable MulticastSomeCast A Paradigm for Real-Time Adaptive Reliable Multicast / Jaehee Yoon, Azer Bestavros, Ibrahim Matta, IEEE Real-Time / Jaehee Yoon, Azer Bestavros, Ibrahim Matta, IEEE Real-Time Technology and Applications Symposium (RTAS) 2000, Washington Technology and Applications Symposium (RTAS) 2000, Washington D.C., Jun. 2000.D.C., Jun. 2000.[5] [5] A Literature Review of Recent Developments in Reliable Multicast EA Literature Review of Recent Developments in Reliable Multicast Error Handlingrror Handling. Elf, Stefan; Parnes, Peter 2001. Elf, Stefan; Parnes, Peter 2001