fplll / g6k

The General Sieve Kernel
GNU General Public License v2.0
102 stars 31 forks source link

(Random) issues while running svp_exact.py #51

Closed nguyen-tuonghuy closed 3 years ago

nguyen-tuonghuy commented 3 years ago

While trying out what is written in the readme file, I found random issues I don't understand during runs of svp_exact.py with the option "--sieve enum" (after running svp_exact_find_norm.py).

For example, running :

python ./svp_exact.py 68 --sieve enum

can fail (it does not always fail !), resulting in errors like :

Traceback (most recent call last): File "./svp_exact.py", line 144, in svp() File "./svp_exact.py", line 121, in svp stats = run_all(svp_kernel, list(all_params.values()), File "/home/g6k/g6k/utils/cli.py", line 113, in run_all res = f(copy.deepcopy(job)) File "./svp_exact.py", line 91, in svp_kernel flast = workout(g6k, tracer, 0, n, goal_r0=goal_r0, pump_params=pump_params, workout_params) File "/home/g6k/g6k/algorithms/workout.py", line 57, in workout pump(g6k, tracer, kappa, blocksize, f, goal_r0=goal_r0, pump_params) File "/home/g6k/g6k/algorithms/pump.py", line 132, in pump if not wrapped_sieve(pump): File "/home/g6k/g6k/algorithms/pump.py", line 34, in wrapped_sieve pump.g6k(alg=alg, tracer=pump.tracer) File "g6k/siever.pyx", line 1281, in g6k.siever.Siever.call raise NotImplementedError("Algorithm %s of type %s not recognized"%(alg, type(alg))) NotImplementedError: Algorithm enum of type <class 'str'> not recognized

Or sometimes (less common), like :

Traceback (most recent call last): File "./svp_exact.py", line 144, in svp() File "./svp_exact.py", line 121, in svp stats = run_all(svp_kernel, list(all_params.values()), File "/home/g6k/g6k/utils/cli.py", line 113, in run_all res = f(copy.deepcopy(job)) File "./svp_exact.py", line 99, in svp_kernel raise ValueError('Found a vector shorter than the goal for n=%d s=%d.'%(n, challenge_seed)) ValueError: Found a vector shorter than the goal for n=68 s=0.

These errors only happen (when it does happen) when the --sieve option is specified as "enum". Other --sieve options do not trigger these errors. Also, it seems that in lower dimension, say < 66, these errors do not happen.

lducas commented 3 years ago

Dear @nguyen-tuonghuy,

thanks for the ticket.

The README documentation was incorrect. The svp_exact.py allows to use FPLLL enumeration for comparison purposes, but this is done vial `--svp/alg enum'.

Fixing in PR fix_51.

lducas commented 3 years ago

fixed by #53