pykan
pykan copied to clipboard
UnboundLocalError: local variable 'alpha_mask' referenced before assignment
When executing self.model.plot(), an error occurs: UnboundLocalError: local variable 'alpha_mask' referenced before assignment.
Upon inspection of the code, it indicates that when the necessary conditions are not met, the alpha_mask remains undefined.
Hi, what is the value of symbol_mask
and numerical_mask
in your case?
Hi, we have finally reproduced the error. We run 30 steps and call the plot function after each training step. The error occurs during the process: when the training error suddenly becomes NaN, the next step is to plot, and then the error occurs. At this point, both the values of symbol_mask
and numerical_mask
are NaN.
I see, the nan loss seems like the real bug. Please open another issue for the nan loss if you still have the problem.