Description
I've noticed that the FHRR class does not normalize after bundling. While some papers [1,2] adopt the approach as is in TorchHD, it is not in accordance with the definition in [3, 4], as there is no norm after superposition. Similarly, the same happens for the HRR class, which could be normalized [2, 4].
I'm aware that the documentation states that the FHRR model is implemented based on "Holographic Reduced Representation: Distributed Representation for Cognitive Structures," but I don't have access to the book to know how FHRR is defined there.
In any case, I believe some improvements to TorchHD would be a nice touch to the library:
- If no normalization is what was intended by the authors, please state in the documentation that FHRR and HRR do not normalize after superposition.
- Consider adding a small function to the API to normalize FHRR and HRR. I believe this would be equivalent to what "hard_quantize" is for the MAP class, as it allows the user to easily bipolarize MAP vectors without using Pytorch directly.
[1] Neuromorphic visual scene understanding with resonator networks
[2] A Survey on Hyperdimensional Computing aka Vector Symbolic Architectures, Part I: Models and Data Transformations
[3] Distributed representations and nested compositional structure
[4] Overview of different HD Computing/VSA models