how to built list-decoder ?
refer to this page: I'm not allowed to put a link. just google : Decoders sagemath
I'm trying to specify the type of the decoder to be list-decoder: The decoder outputs a list of likely codewords, instead of just a single codeword. I'm not sure how to pass it.
D = C.decoder()
D.decoder_type() # output: {'complete', 'hard-decision', 'might-error'}
==== I tried this, gives me no error but it did not return list of codewords
D = C.decoder()
D.decoder_type = {'list-decoder'}
print (D). # output : Syndrome decoder for [16, 4] Goppa code over GF(2) handling errors of weight up to 6
when I tried to check its type, it gives me error
D.decoder_type() # TypeError: 'set' object is not callable
Edited for legibility.
Note : in Python/Sage, a comment is introduced by
#
, not\\
; I edited suitably...Please provide a complete code example.
The error itself is easy to explain. By making assignment
D.decoder_type = {'list-decoder'}
, you overwrite the method value ofD.decoder_type
with the set value. Hence, callingD.decoder_type()
is impossible after such an assignment.