A Python library for Hyperdimensional Computing
Project description
PyHDC
A Python library for Hyperdimensional Computing (HDC) and Vector Symbolic Architectures (VSA).
Full documentation: https://pyhdc.readthedocs.io/en/latest/
Overview
PyHDC provides a unified interface for working with high-dimensional binary and continuous vectors used in HDC/VSA-based computing. It supports multiple encoding schemes, pluggable pseudorandom generators, and both NumPy and PyTorch backends.
Installation
pip install PyHDC
Quick Start
import pyhdc as hdc
# Create an encoding
enc = hdc.MAP_C(dimension=10_000)
# Generate hypervectors
v1 = enc.generate()
v2 = enc.generate()
# Core operations
bundled = v1.bundle(v2) # superposition
bound = v1.bind(v2) # association
sim = v1.similarity(v2) # similarity score
Features
- 14 encoding schemes: MAP-C, MAP-I, MAP-I Bits, MAP-B, HRR, HRR (no norm), HRR (const norm), FHRR, VTB, MBAT, BSC, BSDC-CDT, BSDC-S, BSDC-SEG
- 7 generator families: LCG, Fibonacci/Galois LFSR, DLFSR, LCA, PCG, Xorshift, Shifted Counter
- NumPy and PyTorch backends with optional GPU support
- Composable operations: bind, bundle, unbind, similarity, thinning
- Custom encodings: extend
Encodingwith your ownEncodingSpec - Type-annotated throughout
License
MIT LICENSE.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyhdc-1.1.0.tar.gz.
File metadata
- Download URL: pyhdc-1.1.0.tar.gz
- Upload date:
- Size: 64.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
82307901344dbf399663dab7611cb615bb3ef9c7b085a5a66c8ed7eed7531525
|
|
| MD5 |
bb9766f78d89e790dc215bc0862226b3
|
|
| BLAKE2b-256 |
7b4fe85f48b95f33356bf9f10ba8682e8ed956a7b6848c5aaea5fb7dcbb0ed83
|
Provenance
The following attestation bundles were made for pyhdc-1.1.0.tar.gz:
Publisher:
pypi.yml on GNPower/PyHDC
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyhdc-1.1.0.tar.gz -
Subject digest:
82307901344dbf399663dab7611cb615bb3ef9c7b085a5a66c8ed7eed7531525 - Sigstore transparency entry: 1627154992
- Sigstore integration time:
-
Permalink:
GNPower/PyHDC@9cd1feb1f84e99746059ea62d6b52ccd5d42b88a -
Branch / Tag:
refs/tags/v1.1.0 - Owner: https://github.com/GNPower
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@9cd1feb1f84e99746059ea62d6b52ccd5d42b88a -
Trigger Event:
release
-
Statement type:
File details
Details for the file pyhdc-1.1.0-py3-none-any.whl.
File metadata
- Download URL: pyhdc-1.1.0-py3-none-any.whl
- Upload date:
- Size: 71.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd880c631254dcb768a113aa0888185a7cbb32ffcc65ebabad0d73c4c102710c
|
|
| MD5 |
a7a945da5f159a2c92a6fddf2695a56a
|
|
| BLAKE2b-256 |
c8a9422892ba74ec4fd39dd246c26dc95d46e64529db6d522d3cfd27af785d1d
|
Provenance
The following attestation bundles were made for pyhdc-1.1.0-py3-none-any.whl:
Publisher:
pypi.yml on GNPower/PyHDC
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyhdc-1.1.0-py3-none-any.whl -
Subject digest:
dd880c631254dcb768a113aa0888185a7cbb32ffcc65ebabad0d73c4c102710c - Sigstore transparency entry: 1627155068
- Sigstore integration time:
-
Permalink:
GNPower/PyHDC@9cd1feb1f84e99746059ea62d6b52ccd5d42b88a -
Branch / Tag:
refs/tags/v1.1.0 - Owner: https://github.com/GNPower
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@9cd1feb1f84e99746059ea62d6b52ccd5d42b88a -
Trigger Event:
release
-
Statement type: