Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dok Slicing gives wrong output. #477

Closed
H4R5H1T-007 opened this issue May 17, 2021 · 1 comment · Fixed by #501
Closed

Dok Slicing gives wrong output. #477

H4R5H1T-007 opened this issue May 17, 2021 · 1 comment · Fixed by #501
Labels

Comments

@H4R5H1T-007
Copy link
Contributor

H4R5H1T-007 commented May 17, 2021

Describe the Bug
Dok Slicing gives wrong output for slice indices = (slice(1, None, -1), slice(None, None, 1))

To Reproduce

import numpy as np
import sparse
s_array = sparse.random((1,3), density=1/3, format='dok')
d_array = s_array.todense()
indices = (slice(1, None, -1), slice(None, None, 1))
print((s_array[indices].todense() == d_array[indices]).all())
# False

Expected behavior
It should print True.

System

  • OS and version: Pop Os 20.04
  • sparse version (0.12)
  • NumPy version (1.20.2)
  • Numba version (0.53.1)
@hameerabbasi
Copy link
Collaborator

This was fixed by #501.

@hameerabbasi hameerabbasi linked a pull request Jul 8, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants