inverse

torchhd.inverse(input: VSATensor) VSATensor[source]

Inverse for the binding operation.

See bind().

Parameters:

input (VSATensor) – input hypervector

Shapes:
  • Input: \((*)\)

  • Output: \((*)\)

Examples:

>>> a = torchhd.random(1, 6, "FHRR")
>>> a
tensor([[ 0.879-0.476j,  0.995-0.090j, -0.279+0.960j, -0.752-0.658j, -0.874+0.485j, -0.527-0.849j]])
>>> torchhd.inverse(a)
tensor([[ 0.879+0.476j,  0.995+0.090j, -0.279-0.960j, -0.752+0.658j, -0.874-0.485j, -0.527+0.849j]])