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
Fix pickling of matrix_gfpn_dense #23411
Comments
Author: Simon King |
Commit: |
comment:3
Sorry, one commit is missing |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:5
Now it builds and tests are passing... |
comment:6
|
comment:7
Replying to @jdemeyer:
You also said I should split my original patchbomb into smaller parts. That's why I wanted to leave the transition from
OK. Just to be on the safe side: You do not say that I should imitate a pickle string that results from a machine where, say, |
comment:8
Replying to @simon-king-jena:
PS: Adding such patch would also imply to modify the lines where I import the |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:10
In the latest commit, I add a test that should demonstrate machine independence of pickling (provided that the patchbots provide a whole lot of different architectures, including little and big endian and different sizes of I am not really happy about doing part of the code cleanup here. Would you accept to do all cleanup on a separate ticket. If you do, then please consider this ticket as "needs review". |
comment:11
Setting it to "needs review" in order to allow the patchbots to test the ticket. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Reviewer: Jeroen Demeyer |
comment:61
As expected, this "machine dependent" doctest may fail depending on the machine:
|
comment:62
On a 32-bit system, this gives:
|
comment:63
Replying to @jdemeyer:
Thank you for testing on different architectures! So, what shall we do with that test?
I think I prefer the second way. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:65
Done! And I demonstrate that a deprecated pickle can be opened even if it was created on a silly machine with |
comment:66
Cool test! Now, we are still missing a doctest for the |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:68
Done! There is now one test where the number of bytes is not divisible by the number of rows and one test where the number is divisible but too small to contain a matrix of the given dimensions. Together with the existing tests, I think it covers all code paths. New commits:
|
Changed branch from u/SimonKing/fix_pickling_of_matrix_gfpn_dense to |
There currently are two problems related with pickling of
Matrix_gfpn_dense
:__init__
, it is interpreted as the name of a file from which data are read by some MeatAxe command. If the file doesn't exist, it was intended to have an uninitialised matrix (to be properly initialised later). But currently it crashes, which needs to be fixed.sizeof(long)
, which is machine dependent (at least in theory). Pickling should of course only involve the machine independent memory chunks, but currently it involves the machine dependent chunks.Component: packages: optional
Author: Simon King
Branch/Commit:
ba72aba
Reviewer: Jeroen Demeyer
Issue created by migration from https://trac.sagemath.org/ticket/23411
The text was updated successfully, but these errors were encountered: