Closed imtiyazuddin closed 5 years ago
What values are you using? You can use for example values from the paper https://eprint.iacr.org/2018/153.pdf.
sorry for the late reply, I tried to do bootstrapping for value 1000, but result was nowhere near 1000 when logQ was less before bootstrap (around 30). when I increased it to 40 result value after bootstrap was around 975. so can't we bootstrap a large value?? what parameters does it depend?? again sorry for late reply
If your value is 1000 (about 2^10), then it means that your inital logq should be at least logp + 10 (maybe it should be even bigger). I tried to bootstrap with parameters: logQ=1200, logN=16, bootstrapping parameters: logp = 23, logq=40, logQ = 1200, logT=2, logI=4, number of slots = 2^4.
Here is my code:
srand(time(NULL)); SetNumThreads(8); TimeUtils timeutils; Ring ring; SecretKey secretKey(ring); Scheme scheme(secretKey, ring);
timeutils.start("Key generating"); scheme.addBootKey(secretKey, logSlots, logq + logI); timeutils.stop("Key generated");
long slots = (1 << logSlots);
complex
Ciphertext cipher; scheme.encrypt(cipher, mvec, slots, logp, logq);
cout << "cipher logq before: " << cipher.logq << endl; scheme.bootstrapAndEqual(cipher, logq, logQ, logT, logI); cout << "cipher logq after: " << cipher.logq << endl;
complex
Thank you so much :)
I want to know till what value I can go for bootstrapping. I have seen that for values less than 100 the bootstrapping is working fine, but beyond that the values are wrapping around some number not sure why. I think the wraparound depends on logp and the value you want to bootstrap. Kindly help me to understand this.