pyldpc.decode

pyldpc.decode(H, y, snr, maxiter=1000)[source]

Decode a Gaussian noise corrupted n bits message using BP algorithm.

Decoding is performed in parallel if multiple codewords are passed in y.

Parameters
H: array (n_equations, n_code). Decoding matrix H.
y: array (n_code, n_messages) or (n_code,). Received message(s) in the

codeword space.

maxiter: int. Maximum number of iterations of the BP algorithm.
Returns
x: array (n_code,) or (n_code, n_messages) the solutions in the

codeword space.