Skip to content

Commit

Permalink
Try lower version of pytorch
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeheddes committed Sep 1, 2024
1 parent 33757c8 commit 3089e6f
Show file tree
Hide file tree
Showing 3 changed files with 194 additions and 194 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
url="https://github.com/hyperdimensional-computing/torchhd",
license="MIT",
install_requires=[
"torch>=1.9.0,<2.4",
"torch>=1.9.0,<2.3",
"scipy",
"pandas",
"numpy",
Expand Down
2 changes: 1 addition & 1 deletion torchhd/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def read(self, query: Tensor) -> VSATensor:
# sparse matrix-vector multiplication
r_indices, v_indices = is_active.nonzero().T
read = query.new_zeros(intermediate_shape)
read = read.index_add(0, r_indices, self.values[v_indices])
read.index_add_(0, r_indices, self.values[v_indices])
return read.view(out_shape)

@torch.no_grad()
Expand Down
Loading

0 comments on commit 3089e6f

Please sign in to comment.