Skip to content

Commit

Permalink
chore(shortint): update compression parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
nsarlin-zama committed Jan 6, 2025
1 parent 71fb6c5 commit 3667154
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tfhe/src/shortint/parameters/list_compression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,17 @@ pub struct CompressionParameters {
}

pub const COMP_PARAM_MESSAGE_2_CARRY_2_KS_PBS_TUNIFORM_2M64: CompressionParameters =
V0_11_COMP_PARAM_MESSAGE_2_CARRY_2_KS_PBS_TUNIFORM_2M64;

pub const V0_11_COMP_PARAM_MESSAGE_2_CARRY_2_KS_PBS_TUNIFORM_2M64: CompressionParameters =
CompressionParameters {
br_level: DecompositionLevelCount(1),
br_base_log: DecompositionBaseLog(23),
packing_ks_level: DecompositionLevelCount(4),
packing_ks_base_log: DecompositionBaseLog(4),
packing_ks_level: DecompositionLevelCount(2),
packing_ks_base_log: DecompositionBaseLog(6),
packing_ks_polynomial_size: PolynomialSize(256),
packing_ks_glwe_dimension: GlweDimension(4),
lwe_per_glwe: LweCiphertextCount(256),
storage_log_modulus: CiphertextModulusLog(12),
packing_ks_key_noise_distribution: DynamicDistribution::new_t_uniform(42),
packing_ks_key_noise_distribution: DynamicDistribution::new_t_uniform(43),
};
18 changes: 18 additions & 0 deletions tfhe/src/shortint/parameters/v0_10/list_compression.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
use crate::core_crypto::prelude::{CiphertextModulusLog, LweCiphertextCount};
use crate::shortint::parameters::{
CompressionParameters, DecompositionBaseLog, DecompositionLevelCount, DynamicDistribution,
GlweDimension, PolynomialSize,
};

pub const V0_10_COMP_PARAM_MESSAGE_2_CARRY_2_KS_PBS_TUNIFORM_2M64: CompressionParameters =
CompressionParameters {
br_level: DecompositionLevelCount(1),
br_base_log: DecompositionBaseLog(23),
packing_ks_level: DecompositionLevelCount(4),
packing_ks_base_log: DecompositionBaseLog(4),
packing_ks_polynomial_size: PolynomialSize(256),
packing_ks_glwe_dimension: GlweDimension(4),
lwe_per_glwe: LweCiphertextCount(256),
storage_log_modulus: CiphertextModulusLog(12),
packing_ks_key_noise_distribution: DynamicDistribution::new_t_uniform(42),
};
1 change: 1 addition & 0 deletions tfhe/src/shortint/parameters/v0_10/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
pub mod classic;
pub mod compact_public_key_only;
pub mod key_switching;
pub mod list_compression;
pub mod multi_bit;

0 comments on commit 3667154

Please sign in to comment.