From d0e8613eaf2b14fc5a1dc19840f214d24c184ad4 Mon Sep 17 00:00:00 2001 From: Spyros Date: Fri, 23 Aug 2024 08:46:06 +0300 Subject: [PATCH 1/2] unfix_symbolic_all did not work previously --- kan/MultKAN.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kan/MultKAN.py b/kan/MultKAN.py index c615cc27..8c6c6c58 100644 --- a/kan/MultKAN.py +++ b/kan/MultKAN.py @@ -951,14 +951,14 @@ def unfix_symbolic(self, l, i, j, log_history=True): if log_history: self.log_history('unfix_symbolic') - def unfix_symbolic_all(self): + def unfix_symbolic_all(self, log_history=True): ''' unfix all activation functions. ''' for l in range(len(self.width) - 1): - for i in range(self.width[l]): - for j in range(self.width[l + 1]): - self.unfix_symbolic(l, i, j) + for i in range(self.width_in[l]): + for j in range(self.width_out[l + 1]): + self.unfix_symbolic(l, i, j, log_history=True) def get_range(self, l, i, j, verbose=True): ''' From 8a0bdafbdde9e160fb2e273b7d09c4fb10d00a0c Mon Sep 17 00:00:00 2001 From: Spyros Date: Fri, 23 Aug 2024 08:49:20 +0300 Subject: [PATCH 2/2] oops --- kan/MultKAN.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kan/MultKAN.py b/kan/MultKAN.py index 8c6c6c58..6074675f 100644 --- a/kan/MultKAN.py +++ b/kan/MultKAN.py @@ -958,7 +958,7 @@ def unfix_symbolic_all(self, log_history=True): for l in range(len(self.width) - 1): for i in range(self.width_in[l]): for j in range(self.width_out[l + 1]): - self.unfix_symbolic(l, i, j, log_history=True) + self.unfix_symbolic(l, i, j, log_history) def get_range(self, l, i, j, verbose=True): '''