-
-
Notifications
You must be signed in to change notification settings - Fork 482
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
Linear Code's covering_radius method forces the use of optional package Guava #19913
Comments
Branch: u/dlucas/covering_radius |
comment:2
I pushed the patch, this is now open for review. New commits:
|
Commit: |
Author: David Lucas |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:4
As computing the covering radius is quite slow, I made this method a cached method. |
comment:5
Could you only nest inside of the try/except what needs to be, i.e. the 'load_package' command? As it is, any 'RuntimError' raised by another line would be interpreted as a missing package, though it may well have another cause. Thanks, Nathann |
comment:6
Alternatively, there is this trick that Dima used somewhere else:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:8
Hello, Thanks for your remark! I picked Dima's trick and fixed my code. David |
comment:10
It actually seems that
calls an error message which invites the user to install Guava if it's not installed. Anyway, I went back to a (proper) |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:12
I updated this ticket to the latest beta and fixed merge conflict. |
comment:13
Hi this is incredibly slow, up to the point of being not usable. Yet the code is correct, works on very small instances, and tests are passed. I send the status to positive review. Daniel |
comment:14
Reviewer name is missing |
comment:15
Before setting to |
comment:16
You might also look at this implementation: u/ylchapuy/coset_leaders |
comment:17
We don't really need Guava, there's all we need in gap. I provide a sample implementation but it's buggy (try it with the code The branch up there could also be used in #21339 , and in the method This branch is quite efficient and computes the 177147 coset_leaders of a random linear code [30, 19] over GF(3) in less than 4 seconds, and the covering radius (5 in my example) in 3 seconds. |
The method
covering_radius
for linear codes (inlinear_code.py
), uses optional package Guava for Gap by default.If this package is not installed, the method crashes without a proper error message.
This ticket proposes a reimplementation of
covering_radius
, with a generic algorithm written in Python. If Guava is not installed on the user's system, it uses the generic algorithm, else it uses the Guava one.Component: coding theory
Author: David Lucas
Branch/Commit: u/dlucas/covering_radius @
15a108c
Issue created by migration from https://trac.sagemath.org/ticket/19913
The text was updated successfully, but these errors were encountered: