-
Notifications
You must be signed in to change notification settings - Fork 62
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
enable sub-solutions #95
Conversation
malb
commented
Aug 4, 2017
•
edited
Loading
edited
- add sub-solution support
- make API consistent between sub-solutions and full solutions/fplll
enumerate swapped norm and vector compared to fplll and subsolutions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
`` Code that isn't tested is broken... ''
Maybe I missed it, but I can't find any dedicated test for sub-solutions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tested it in the wild, seems to work except from a few aberrant solution length once in a while (looks like unallocated memory). I have tough time making it reproducible though.
The interface is convenient.
>>> pruning = Pruning.run(M.get_r(0, 0), 2**40, M.r()[:30], 0.2) | ||
>>> enum = Enumeration(M, strategy=EvaluatorStrategy.BEST_N_SOLUTIONS, sub_solutions=True) | ||
>>> _ = enum.enumerate(0, 30, 0.999*M.get_r(0, 0), 0, pruning=pruning.coefficients) | ||
>>> [int(a) for a,b in enum.sub_solutions[:5]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tests are here, could check for more mathematical properties, though
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ta.
We should wait with merging until the possible unallocated memory issue is resolved. |
Its actually not such a huge bug. It is just a rather awkward behaviour. When nothing is found two things can happen: So I guess initialized memory is involved in case 2, yet nothing too deep I'd guess. Not sure if this should be fixed in fplll or fpylll. |
For any practical purpose, the attached pickle files contains a triple |