Handle the case of all dec-failures
This commit is contained in:
parent
68751c50cd
commit
daf9cc6071
@ -180,9 +180,12 @@ class Simulator:
|
|||||||
adj_num_iterations = self._curr_num_iterations - \
|
adj_num_iterations = self._curr_num_iterations - \
|
||||||
self._curr_num_dec_fails
|
self._curr_num_dec_fails
|
||||||
|
|
||||||
self._BERs[self._curr_decoder_index][self._curr_SNRs_index] \
|
if adj_num_iterations == 0:
|
||||||
= self._curr_num_bit_errors / (
|
self._BERs[self._curr_decoder_index][self._curr_SNRs_index] = 1
|
||||||
adj_num_iterations * self._n)
|
else:
|
||||||
|
self._BERs[self._curr_decoder_index][self._curr_SNRs_index] \
|
||||||
|
= self._curr_num_bit_errors / (
|
||||||
|
adj_num_iterations * self._n)
|
||||||
|
|
||||||
self._dec_fails[self._curr_decoder_index][self._curr_SNRs_index] \
|
self._dec_fails[self._curr_decoder_index][self._curr_SNRs_index] \
|
||||||
= self._curr_num_dec_fails
|
= self._curr_num_dec_fails
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user