Open awero-manaxiy opened 4 months ago
Same issue (maybe). When I try to get the the symbolic formula (model.symbolic_formula(var=input_features) I get 'ZeroDivisionError: integer division or modulo by zero'
criterion = F.mse_loss model_kan = KAN(width=[5, 10, 10, 10, 1], grid=50, k=3, seed=args.seed, device=device) print(model_kan.device) results = model_kan.train(temp_dataset, opt="LBFGS", steps=10, lamb=0.01, loss_fn=criterion, device=device, lamb_entropy=2.)
I met the same issue.
same issue with arcsin
Please specify an error in the except clause!
There is no 'arcsin' function in sympy, it's named 'asin'. auto_symbolic is fixing with arcsin, which causes the program to output 'make sure all activations need to be converted to symbolic formulas first!' even when every activation is symbolic.
Also ex_round is broken as well. With it, code reliably outputs ZeroDivisionError every time on my data. Ended up rewriting the function with torch.round which fixed the issue.