return ctIn when n=1, batchSize=k*N

This commit is contained in:
lehugueni
2024-11-21 10:06:00 +01:00
parent 141c402c91
commit b67c72b7ba

View File

@@ -1515,6 +1515,13 @@ func (eval Evaluator) InnerSum(ctIn *rlwe.Ciphertext, batchSize, n int, opOut *r
l := n * batchSize
if l%N == 0 {
if n == 1 {
if ctIn != opOut {
opOut.Copy(ctIn)
}
return
}
if err = eval.Evaluator.InnerSum(ctIn, batchSize, n/2, opOut); err != nil {
return
}