From 6a82ce9338f31a62d6ab59b96eec5867ba69d647 Mon Sep 17 00:00:00 2001 From: raphaelDkhn Date: Sun, 22 Oct 2023 12:39:15 +0300 Subject: [PATCH] debbug --- .../fixed_point/implementations/fp16x16wide/math/core.cairo | 2 +- src/operators/tensor/math/exp.cairo | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/numbers/fixed_point/implementations/fp16x16wide/math/core.cairo b/src/numbers/fixed_point/implementations/fp16x16wide/math/core.cairo index 38db5b84d..9ab7fcc4c 100644 --- a/src/numbers/fixed_point/implementations/fp16x16wide/math/core.cairo +++ b/src/numbers/fixed_point/implementations/fp16x16wide/math/core.cairo @@ -61,7 +61,7 @@ fn eq(a: @FP16x16W, b: @FP16x16W) -> bool { // Calculates the natural exponent of x: e^x fn exp(a: FP16x16W) -> FP16x16W { - a.sign.print(); + // a.sign.print(); return exp2(FixedTrait::new(94548, false) * a); // log2(e) * 2^23 ≈ 12102203 } diff --git a/src/operators/tensor/math/exp.cairo b/src/operators/tensor/math/exp.cairo index 92b60e2ac..0b3889511 100644 --- a/src/operators/tensor/math/exp.cairo +++ b/src/operators/tensor/math/exp.cairo @@ -62,6 +62,8 @@ fn exp_upcast< loop { match self.data.pop_front() { Option::Some(item) => { + (TIntoW::into(*item)).print(); + result.append((TIntoW::into(*item)).exp()); }, Option::None(_) => {