diff --git a/src/lib.rs b/src/lib.rs index 34045a811..329ecd30b 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -317,7 +317,10 @@ pub struct RunArgs { #[cfg_attr(all(feature = "ezkl", not(target_arch = "wasm32")), arg(long, default_value = "2", value_hint = clap::ValueHint::Other))] /// the number of legs used for decompositions pub decomp_legs: usize, - #[cfg_attr(all(feature = "ezkl", not(target_arch = "wasm32")), arg(long, default_value = "false", value_hint = clap::ValueHint::Other))] + #[cfg_attr( + all(feature = "ezkl", not(target_arch = "wasm32")), + arg(long, default_value = "false") + )] /// use unbounded lookup for the log pub bounded_log_lookup: bool, } diff --git a/src/tensor/ops.rs b/src/tensor/ops.rs index c1bb99865..7a71557f8 100644 --- a/src/tensor/ops.rs +++ b/src/tensor/ops.rs @@ -1534,13 +1534,13 @@ pub mod nonlinearities { /// ``` /// use ezkl::tensor::Tensor; /// use ezkl::fieldutils::IntegerRep; - /// use ezkl::tensor::ops::nonlinearities::log2; + /// use ezkl::tensor::ops::nonlinearities::ilog2; /// let x = Tensor::::new( - /// Some(&[2, 15, 2, 1, 1, 0]), + /// Some(&[2, 15, 2, 1, 1, 2]), /// &[2, 3], /// ).unwrap(); - /// let result = log2(&x, 1.0); - /// let expected = Tensor::::new(Some(&[1, 3, 1, 0, 0, 0]), &[2, 3]).unwrap(); + /// let result = ilog2(&x, 1.0); + /// let expected = Tensor::::new(Some(&[1, 4, 1, 0, 0, 1]), &[2, 3]).unwrap(); /// assert_eq!(result, expected); /// ``` pub fn ilog2(a: &Tensor, scale_input: f64) -> Tensor { diff --git a/tests/assets/settings.json b/tests/assets/settings.json index a123fc99d..1fc77672e 100644 --- a/tests/assets/settings.json +++ b/tests/assets/settings.json @@ -27,7 +27,8 @@ "check_mode": "UNSAFE", "commitment": "KZG", "decomp_base": 128, - "decomp_legs": 2 + "decomp_legs": 2, + "bounded_log_lookup": false }, "num_rows": 46, "total_assignments": 92,