-
Notifications
You must be signed in to change notification settings - Fork 761
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
Improve Unpack & Repack by reducing constant polynomials. #230
Comments
I am not 100% sure the math; if you have any idea please let me know. |
@fionser it will take me a little while to get to it. Is this something that you want integrated very soon, or is it okay if I look at it toward the end of the summer? |
@shaih No problem. It is not a hurry. Also, I found my PR actually is NOT optimal for performance. We can exchange the order of the inner-loop and outer-loop (a similar logic to the current extractDigits implementation); at the cost of increasing the number of multiplications. |
* Doxygen documentation for the Binary Arithmetic APIs * New API and function testing code into GTest * Example code on how to use the APIs
Motivation
It seems in the recryption procedure, the conversion time from coefficient format to DoubleCRT is quite large. I hope to reduce the number of necessary plaintext polynomials, especially in Unpack & Repack procedure.
Method
alpha_j = frobenius(alpha_0, j)
. As a result, we only need to store the first polyalpha_0
and to computealpha_j
on-fly.Example
Take the Unpack method defined in class
unpack_pa_impl
as an example.The
unpacksSlotEncoding
here followsunpackSlotEncoding[ j ] = Frobenus(unpackSlotEncoding[0], j)
. My refined version should work as followsunpack
function.alpha0
, and apply hoisting.The text was updated successfully, but these errors were encountered: