GithubHelp home page GithubHelp logo

reed-solomon-workspace's Introduction

Reed-Solomon Workspace

Workspace to play with Reed-Solomon.

This code contains a partial port of the Backblaze/JavaReedSolomon library.

For an introduction on erasure coding, see the post on the Backblaze blog.

simple-gf2-times-demo.rb Output

# Original data.
    # 583ef0ac
    [[65, 66, 67, 68],
     [69, 70, 71, 72],
     [73, 74, 75, 76],
     [77, 78, 79, 80]]

# Magic matrix to create 2 parity blocks.
    # 7e2a5356
    [[1, 0, 0, 0],
     [0, 1, 0, 0],
     [0, 0, 1, 0],
     [0, 0, 0, 1],
     [27, 28, 18, 20],
     [28, 27, 20, 18]]

# Magic matrix to repair up to 2 missing blocks.
    # da17d55d
    [[1, 0, 0, 0],
     [0, 1, 0, 0],
     [0, 0, 1, 0],
     [0, 0, 0, 1],
     [141, 246, 123, 1],
     [246, 141, 1, 123]]

# Original data with 2 parity blocks appended.
    # 81870e91
    [[65, 66, 67, 68],
     [69, 70, 71, 72],
     [73, 74, 75, 76],
     [77, 78, 79, 80],
     [81, 82, 83, 73],
     [85, 86, 87, 37]]

# Damaged data with 2 parity blocks appended and 2 data blocks missing.
    # 88afae54
    [[65, 66, 67, 68],
     [69, 70, 71, 72],
     [81, 82, 83, 73],
     [85, 86, 87, 37]]

# Magic matrix to repair damage (corresponding rows to the damaged blocks have been removed).
    # e550822e
    [[1, 0, 0, 0],
     [0, 1, 0, 0],
     [141, 246, 123, 1],
     [246, 141, 1, 123]]

# Repaired data.
    # 583ef0ac
    [[65, 66, 67, 68],
     [69, 70, 71, 72],
     [73, 74, 75, 76],
     [77, 78, 79, 80]]

Original data marshaled matrix crc32: 583ef0ac
Repaired data marshaled matrix crc32: 583ef0ac

reed-solomon-workspace's People

Contributors

werekraken avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.