mirror of
https://github.com/zama-ai/tfhe-rs.git
synced 2026-01-10 07:08:03 -05:00
fix(shortint): fix CompressedModulusSwitchNoiseReductionKey generation
- was using the wrong seeded encryption API resulting in garbage values when decompressing
This commit is contained in:
@@ -225,22 +225,22 @@ impl CompressedModulusSwitchNoiseReductionKey {
|
||||
|
||||
// Parallelism allowed
|
||||
#[cfg(any(not(feature = "__wasm_api"), feature = "parallel-wasm-api"))]
|
||||
par_encrypt_seeded_lwe_ciphertext_list_with_existing_generator(
|
||||
par_encrypt_seeded_lwe_ciphertext_list(
|
||||
secret_key,
|
||||
&mut modulus_switch_zeros,
|
||||
&plaintext_list,
|
||||
lwe_noise_distribution,
|
||||
&mut engine.encryption_generator,
|
||||
&mut engine.seeder,
|
||||
);
|
||||
|
||||
// No parallelism allowed
|
||||
#[cfg(all(feature = "__wasm_api", not(feature = "parallel-wasm-api")))]
|
||||
encrypt_seeded_lwe_ciphertext_list_with_existing_generator(
|
||||
encrypt_seeded_lwe_ciphertext_list(
|
||||
secret_key,
|
||||
&mut modulus_switch_zeros,
|
||||
&plaintext_list,
|
||||
lwe_noise_distribution,
|
||||
&mut engine.encryption_generator,
|
||||
&mut engine.seeder,
|
||||
);
|
||||
|
||||
Self {
|
||||
|
||||
Reference in New Issue
Block a user