fix dinn ... oops
@@ -76,7 +76,7 @@ pub fn main() {
////////////////////////////////////////////////////////////////////////////////
// tests
-fn test_arith_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize], secret_weights: bool) {{{{
+fn test_arith_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize], secret_weights: bool) { //{{{
println!("running plaintext accuracy evaluation");
println!("secret weights={}", secret_weights);
@@ -115,7 +115,7 @@ fn test_arith_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize],
println!("errors: {}/{}. accuracy: {}%", errors, NIMAGES, 100.0 * (1.0 - errors as f32 / NIMAGES as f32));
}
//}}}
-fn bench_arith_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) {{{{
+fn bench_arith_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) { // {{{
println!("running garble/eval benchmark");
println!("secret weights={}", secret_weights);
@@ -153,7 +153,7 @@ fn bench_arith_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) {{{
println!("size: {} ciphertexts", ev.size());
}
//}}}
-fn test_bool_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize], secret_weights: bool) {{{{
+fn test_bool_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize], secret_weights: bool) { //{{{
let nbits = BIT_WIDTH;
let circ = build_boolean_circuit(nbits, nn, secret_weights);
@@ -191,7 +191,7 @@ fn test_bool_circuit(nn: &NeuralNet, images: &Vec<Vec<i32>>, labels: &[usize], s
println!("errors: {}/{}. accuracy: {}%", errors, NIMAGES, 100.0 * (1.0 - errors as f32 / NIMAGES as f32));
}
//}}}
-fn bench_bool_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) {{{{
+fn bench_bool_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) { //{{{
println!("running garble/eval benchmark for boolean circuit");
println!("secret weights={}", secret_weights);
@@ -230,7 +230,7 @@ fn bench_bool_garbling(nn: &NeuralNet, image: &[i32], secret_weights: bool) {{{{
////////////////////////////////////////////////////////////////////////////////
// circuit creation
-fn build_circuit(q: u128, nn: &NeuralNet, secret_weights: bool) -> Bundler {{{{
+fn build_circuit(q: u128, nn: &NeuralNet, secret_weights: bool) -> Bundler { //{{{
let mut b = Bundler::new();
let nn_inputs = b.inputs(q, TOPOLOGY[0]);
@@ -280,7 +280,7 @@ fn build_circuit(q: u128, nn: &NeuralNet, secret_weights: bool) -> Bundler {{{{
b
}
//}}}
-fn build_boolean_circuit(nbits: usize, nn: &NeuralNet, secret_weights: bool) -> Circuit {{{{
+fn build_boolean_circuit(nbits: usize, nn: &NeuralNet, secret_weights: bool) -> Circuit { //{{{
let mut b = Builder::new();
// binary inputs with 0 representing -1
