-
-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Symbolic regression does not output equations #318
Comments
Also, using DataDrivenDiffEq
using SymbolicRegression
X = rand(2,10)
Y = rand(2,10)
opts = EQSearch([+, *, /, ^, cos, exp, log], maxdepth=15, progress = true, verbosity = 1)
prob = DirectDataDrivenProblem(X, Y)
res = solve(prob, opts, numprocs = 0, multithreading = false)
|
Also, using DataDrivenDiffEq
using SymbolicRegression
X = rand(2,10)
Y = rand(1,10)
opts = EQSearch([+, *, /, ^, cos, exp, log], maxdepth=15, progress = true, verbosity = 1)
prob = DirectDataDrivenProblem(X, Y)
res = solve(prob, opts, numprocs = 0, multithreading = false)
|
The output of the equations is expected, but I think I'll change this in an upcoming patch . The Also, the error with one dimensional outputs ( The errors on |
I also sometimes get errors like this when running the code multiple times: ERROR: LoadError: IOError: open("hall_of_fame.csv.out2.bkup", 769, 33206): permission denied (EACCES) |
This is related to the backup file and can be passed into the Options of SymbolicRegression. I am tagging @MilesCranmer here, since he might have some more insight on how to handle this ( and maybe thoughts on the uni- vs. multivariate results ). |
Sorry for late reply, was on holidays. using SymbolicRegression
X = rand(2, 10)
Y = rand(2, 10)
opts = Options(binary_operators = (+, *, /, ^), unary_operators = (cos, exp, log), maxdepth = 15, progress = true, verbosity = 1)
hof = EquationSearch(X, Y, numprocs = 0, multithreading = false, options = opts)
# First column:
dominating = calculateParetoFrontier(X, Y[1, :], hof[1], opts)
# Convert to SymbolicUtils:
eqns = [node_to_symbolic(eqn.tree, opts) for eqn in dominating] The output is a bunch of equations in SymbolicUtils format:
Note that @AlCap23 is this similar to what the current frontend is doing? |
Regarding the IOError, can you raise an issue at SymbolicRegression.jl's github if you still see it when running things directly? I can't reproduce it currently. |
Everything works fine when directly using SymbolicRegression.jl . All the issues are only through the use of DataDrivenDiffEq.jl . |
Hi Miles! Thanks for getting involved. No worries, I have been on vacation as well.
Yes, this is what is happening here. However, if I haven't been able to reproduce the |
I've fixed the recovery of the results within DataDriven. |
Oops, sorry for missing this! Yes, this solution looks good, nice work. |
The tutorial https://datadriven.sciml.ai/stable/examples/symbolic_regression/#symbolic_regression_tutorial on 1.7 does not output the equations, it only returns:
The text was updated successfully, but these errors were encountered: