How-To Guides

How-to guides solve specific, practical problems. They assume you already know the basics. If you are new to PyHDC, start with the Five-Minute Quickstart and Tutorials first.

Guide

Problem solved

How to Choose the Right Encoding

Which encoding should I use for my task?

How to Bundle Hypervectors

How do I bundle multiple hypervectors?

How to Bind and Unbind Key-Value Pairs

How do I store and retrieve key-value pairs?

How to Compute Similarity

How do I compare hypervectors, including in batch?

How to Switch Between Backends and Devices

How do I move between NumPy and PyTorch / GPU?

How to Make Experiments Reproducible

How do I make my experiments reproducible?

How to Remap Similarity Output to [0, 1]

How do I remap similarity output to [0, 1]?

How to Control Density in Sparse Binary Encodings

How do I keep sparse binary vectors from becoming dense?

How to Handle PyHDC Exceptions

How do I handle PyHDC errors gracefully?

How to Wrap Existing Arrays as Hypervectors

How do I wrap an existing NumPy array as a Hypervector?