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

Access the population during GA evolution #122

Open
ropinotex opened this issue Jun 9, 2023 · 1 comment
Open

Access the population during GA evolution #122

ropinotex opened this issue Jun 9, 2023 · 1 comment

Comments

@ropinotex
Copy link

Is it possible to access the current population at the end of each iteration, for example by using the callbacks (or any other feasible way)?

Say, I want to check the population at the end of each iteration, and adding new individuals if some conditions are satisfied.

@ropinotex ropinotex changed the title Access the population during evolution Access the population during GA evolution Jun 9, 2023
@jonathanfischer97
Copy link

Yes, but you would have define a trace! overload that saves a reference to your state.population in order to expose it to a callback for manipulation. The callback takes a trace record as input.

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

2 participants