From 2528c4d18da824f025989402811d7ab996d2640f Mon Sep 17 00:00:00 2001
From: Vincent TEMPLIER <vincent.templier@cea.fr>
Date: Wed, 5 Jun 2024 06:48:43 +0000
Subject: [PATCH] Fix bad behiour of aidge fc hwc kernel

---
 .../_Aidge_Arm/kernels/FullyConnected/aidge_fc_float32.c        | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/aidge_export_arm_cortexm/_Aidge_Arm/kernels/FullyConnected/aidge_fc_float32.c b/aidge_export_arm_cortexm/_Aidge_Arm/kernels/FullyConnected/aidge_fc_float32.c
index 7f2a78a..a38efab 100644
--- a/aidge_export_arm_cortexm/_Aidge_Arm/kernels/FullyConnected/aidge_fc_float32.c
+++ b/aidge_export_arm_cortexm/_Aidge_Arm/kernels/FullyConnected/aidge_fc_float32.c
@@ -12,7 +12,7 @@ void aidge_fc_float32 (float* inputs,
         float accum = biases[out]; 
 
         for (unsigned int in = 0; in < nb_inputs; ++in) {
-            accum += inputs[in] * weights[in * nb_outputs + out];
+            accum += inputs[in] * weights[out * nb_inputs + in];
         }
 
         // Store result
-- 
GitLab