Skip to content
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

How to optimize constants in a model? #697

Open
wangsy15 opened this issue May 17, 2023 · 0 comments
Open

How to optimize constants in a model? #697

wangsy15 opened this issue May 17, 2023 · 0 comments

Comments

@wangsy15
Copy link

wangsy15 commented May 17, 2023

How to incorporate a local optimizater into GP symbolic formula dedicated to constant number optimization, or use other techniques. For example, i have a formula
d(v1)/dt=add(v1, add(add(v2, 5.426), mul(v1, 3.266))),
it is difficult to learn its coefficient because it is not an integer.


How to check all the constants contained in each formula tree, namely count their number and record their position in the tree?
I used GP in DEAP to solve the symbolic regression problem, specifically trying to fit the data with the most accurate symbolic formula. I would like to ask how to find all the constants contained in each tree if the best formula obtained is represented as a binary tree, i.e. calculate their number n and record their position in the tree. For example, if the best formula is
d(v1)/dt=add(v1, add(add(v2, 5.426), mul(v1, 3.266))),
is it possible to find 5.426 and 3.266 and give their positions in the tree. Is there a function in deap that can implement this requirement?
Or I would like to ask how to optimise the parameters in the equations during genetic programming. Something like expressing the equation in the form Y=FP, with F being the matrix containing the operators and P being the parameter matrix. How can P be optimised while keeping the structure of the equation constant (i.e. F is constant).

@wangsy15 wangsy15 changed the title How to check all the constants contained in each formula tree, namely count their number and record their position in the tree. How to optimize constants in a model? May 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant