User Manual

The User Manual explains why PyHDC works the way it does. It is understanding-oriented: you can read it without running any code, and it will deepen your intuition for HDC as a computational paradigm.

Contents

Overview

HDC Theory and Mathematics

The mathematics of hypervectors: near-orthogonality, capacity, and why the three primitives (bundle, bind, similarity) are sufficient for symbolic reasoning.

Encodings Overview

The Encoding base class and EncodingSpec design; a tour of all four encoding families (MAP, HRR/FHRR, Matrix, Binary/Sparse).

Binding Operations

Deep dive on every binding operation: element multiplication, circular convolution, XOR, shift, matrix transformation, and more.

Bundling Operations

Deep dive on every bundling operation: addition variants, normalisation, majority vote, bitwise OR, and thinned OR.

Similarity Metrics

Cosine, Hamming, Overlap, and Angle distance: formulas, output ranges, batched calling conventions, and remapping.

Random Number Generators

The seven generator families; LCG, LFSR, DLFSR, LCA, PCG, Xorshift, ShiftedCounter; with design rationale and a compatibility matrix.

Dual Backend Architecture

How PyHDC’s dual NumPy / PyTorch backend is implemented, when to use each, and how device placement works.

The components Submodule

The pyhdc.components submodule: building blocks for custom encodings and advanced post-processing pipelines.