Skip to content

Commit

Permalink
Move TerminatedConvolutionalCode from block to convolutional module
Browse files Browse the repository at this point in the history
  • Loading branch information
rwnobrega committed Nov 29, 2024
1 parent bd34f6c commit 09e853a
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 7 deletions.
2 changes: 1 addition & 1 deletion site/toc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ Error control:
- BlockDecoder
Convolutional coding:
- ConvolutionalCode
- TerminatedConvolutionalCode
- ConvolutionalStreamEncoder
- ConvolutionalStreamDecoder
- TerminatedConvolutionalCode
Checksum:
- CyclicRedundancyCheck
Finite-state machines:
Expand Down
2 changes: 0 additions & 2 deletions src/komm/_error_control_block/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
from .SingleParityCheckCode import SingleParityCheckCode
from .SlepianArray import SlepianArray
from .SystematicBlockCode import SystematicBlockCode
from .TerminatedConvolutionalCode import TerminatedConvolutionalCode

__all__ = [
"BCHCode",
Expand All @@ -31,7 +30,6 @@
"SingleParityCheckCode",
"SlepianArray",
"SystematicBlockCode",
"TerminatedConvolutionalCode",
]

from .decoders import *
4 changes: 3 additions & 1 deletion src/komm/_error_control_block/decoders/bcjr.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import numpy as np
import numpy.typing as npt

from ..._error_control_convolutional.TerminatedConvolutionalCode import (
TerminatedConvolutionalCode,
)
from ..registry import RegistryBlockDecoder
from ..TerminatedConvolutionalCode import TerminatedConvolutionalCode


def decode_bcjr(
Expand Down
4 changes: 3 additions & 1 deletion src/komm/_error_control_block/decoders/viterbi.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
import numpy as np
import numpy.typing as npt

from ..._error_control_convolutional.TerminatedConvolutionalCode import (
TerminatedConvolutionalCode,
)
from ..._finite_state_machine.FiniteStateMachine import MetricFunction
from ..._util import unpack
from ..registry import RegistryBlockDecoder
from ..TerminatedConvolutionalCode import TerminatedConvolutionalCode


def decode_viterbi(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
from attrs import frozen
from numpy.linalg import matrix_power

from .._error_control_convolutional.ConvolutionalCode import ConvolutionalCode
from .._error_control_block.BlockCode import BlockCode
from .._types import ArrayIntLike
from .._util.bit_operations import binlist2int, int2binlist, pack, unpack
from .._util.matrices import pseudo_inverse
from .BlockCode import BlockCode
from .ConvolutionalCode import ConvolutionalCode


@frozen
Expand Down
2 changes: 2 additions & 0 deletions src/komm/_error_control_convolutional/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
from .ConvolutionalCode import ConvolutionalCode
from .ConvolutionalStreamDecoder import ConvolutionalStreamDecoder
from .ConvolutionalStreamEncoder import ConvolutionalStreamEncoder
from .TerminatedConvolutionalCode import TerminatedConvolutionalCode

__all__ = [
"ConvolutionalCode",
"TerminatedConvolutionalCode",
"ConvolutionalStreamDecoder",
"ConvolutionalStreamEncoder",
]

0 comments on commit 09e853a

Please sign in to comment.