Skip to content

Commit

Permalink
fix postprocessing
Browse files Browse the repository at this point in the history
  • Loading branch information
malb committed Jul 12, 2017
1 parent 35db82d commit 139c205
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/fpylll/algorithms/bkz.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,19 @@ def svp_postprocessing(self, kappa, block_size, solution, tracer):
if solution is None:
return True

# d = self.M.d
# self.M.create_row()

# with self.M.row_ops(d, d+1):
# for i in range(block_size):
# self.M.row_addmul(d, kappa + i, solution[i])

# self.M.move_row(d, kappa)
# with tracer.context("lll"):
# self.lll_obj(kappa, kappa, kappa + block_size + 1)
# self.M.move_row(kappa + block_size, d)
# self.M.remove_last_row()

j_nz = None

for i in range(block_size):
Expand Down Expand Up @@ -240,6 +253,9 @@ def svp_postprocessing(self, kappa, block_size, solution, tracer):

self.M.move_row(kappa + block_size - 1, kappa)

# TODO the C++ version doesn't seem to require this call
self.lll_obj.size_reduction(kappa, kappa+block_size, kappa)

return False

def svp_reduction(self, kappa, block_size, params, tracer=dummy_tracer):
Expand Down

0 comments on commit 139c205

Please sign in to comment.