Skip to content

Commit

Permalink
Merge pull request #16 from zama-ai/petar/update-tfhe-rs
Browse files Browse the repository at this point in the history
Update tfhe-rs to 0.3.1
  • Loading branch information
dartdart26 authored Aug 23, 2023
2 parents 7fd4b41 + 5c928de commit 576fee8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ publish = false
bincode = "1.3.3"
clap = { version = "3.1.18", features = ["derive"] }
serde = "1.0"
tfhe = { git = "https://github.com/zama-ai/tfhe-rs.git", rev = "0.3.0-beta.0", features = ["boolean", "experimental-force_fft_algo_dif4", "shortint", "integer"] }
tfhe = { git = "https://github.com/zama-ai/tfhe-rs.git", rev = "0.3.1", features = ["boolean", "experimental-force_fft_algo_dif4", "shortint", "integer"] }
7 changes: 4 additions & 3 deletions src/gen_keys.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,14 @@
// All rights reserved.

use tfhe::{
generate_keys, shortint::parameters::PARAM_SMALL_MESSAGE_2_CARRY_2_COMPACT_PK, ClientKey,
CompactPublicKey, ConfigBuilder, ServerKey,
generate_keys,
shortint::parameters::parameters_compact_pk::PARAM_MESSAGE_2_CARRY_2_COMPACT_PK_PBS_KS,
ClientKey, CompactPublicKey, ConfigBuilder, ServerKey,
};

pub fn gen_keys() -> (ClientKey, ServerKey, CompactPublicKey) {
let config = ConfigBuilder::all_disabled()
.enable_custom_integers(PARAM_SMALL_MESSAGE_2_CARRY_2_COMPACT_PK, None)
.enable_custom_integers(PARAM_MESSAGE_2_CARRY_2_COMPACT_PK_PBS_KS, None)
.build();
let (cks, sks) = generate_keys(config);
let pks = CompactPublicKey::new(&cks);
Expand Down

0 comments on commit 576fee8

Please sign in to comment.