hyperdimensional-computing / torchhd

Torchhd is a Python library for Hyperdimensional Computing and Vector Symbolic Architectures
https://torchhd.readthedocs.io
MIT License
229 stars 24 forks source link

Wrong Example #100

Closed lakshya-4gp closed 1 year ago

lakshya-4gp commented 1 year ago

def hard_quantize(input: Tensor): """Applies binary quantization to all elements of the input tensor. Args: input (Tensor): input tensor Shapes:

The example given is wrong, since ( input > 0 ) is used the output of functional.hard_quantize(y) will be [-1, -1, -1]

mikeheddes commented 1 year ago

Thank you @lakshya-4gp for reporting this issue. I will look into it in the coming days.