You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replicate function signatures in inherited classes (MCRTensor and
CGRTensor) from their parent class (BaseMCRTensor) to let sphinx
print the documentation of each parent function.
Copy file name to clipboardExpand all lines: torchhd/tensors/cgr.py
+88-1Lines changed: 88 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -35,6 +35,71 @@ class CGRTensor(BaseMCRTensor):
35
35
First introduced in `Modular Composite Representation <https://link.springer.com/article/10.1007/s12559-013-9243-y>`_ and then better elaborated in `Understanding hyperdimensional computing for parallel single-pass learning <https://proceedings.neurips.cc/paper_files/paper/2022/file/080be5eb7e887319ff30c792c2cbc28c-Paper-Conference.pdf>`_, this model works with modular integer vectors. It works similar to the MCR class, but uses a bundling based on element-wise mode instead of addition of complex numbers.
r"""Bundle the hypervector with majority voting. Ties might be broken at random. However, the expected result is that the tie representing the lowest value wins.
Copy file name to clipboardExpand all lines: torchhd/tensors/mcr.py
+86Lines changed: 86 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -36,6 +36,70 @@ class MCRTensor(BaseMCRTensor):
36
36
Proposed in `Modular Composite Representation <https://link.springer.com/article/10.1007/s12559-013-9243-y>`_, this model works with modular integer vectors.
0 commit comments