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

bug in reshape for bigint type #3870

Open
ajpotts opened this issue Oct 24, 2024 · 1 comment · May be fixed by #3907
Open

bug in reshape for bigint type #3870

ajpotts opened this issue Oct 24, 2024 · 1 comment · May be fixed by #3907
Assignees
Labels
bug Something isn't working

Comments

@ajpotts
Copy link
Contributor

ajpotts commented Oct 24, 2024

The reshape function gives the incorrect result for the bigint type, as shown in the following example:

In [3]: dtype = "bigint"

In [4]: size = 10

In [5]:         x = ak.arange(size, dtype=dtype).reshape((1, size, 1))

In [6]: x
Out[6]: array([array([array([0]) array([1]) array([2]) array([3]) array([4]) array([224251899497]) array([1919968626]) array([78401563153491]) array([127961796865894]) array([111052610564705])])])
@ajpotts ajpotts self-assigned this Oct 24, 2024
@ajpotts ajpotts changed the title bug in reshape for binint type bug in reshape for bigint type Nov 8, 2024
@ajpotts ajpotts added the bug Something isn't working label Nov 20, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 20, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 20, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 20, 2024
@ajpotts
Copy link
Contributor Author

ajpotts commented Nov 20, 2024

I believe the cause is this section the unflatten procedure:

            get(
              c_ptrTo(unflat[low]),
              getAddr(a[flatSlice.low]),
              locInStart,
              c_sizeof(t) * flatSlice.size
            );

I think the fact that BigInt does not have constant size, the data cannot be bulk copied using the address.

ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 21, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 21, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 21, 2024
ajpotts added a commit to ajpotts/arkouda that referenced this issue Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant