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 initial population with a specified solution #50

Open
yasser9372 opened this issue Jun 27, 2019 · 0 comments
Open

How to initial population with a specified solution #50

yasser9372 opened this issue Jun 27, 2019 · 0 comments

Comments

@yasser9372
Copy link

Hi.
I want to add an specific solution in first population.
for example in this population:

# Define population.
indv_template = BinaryIndividual(ranges=[(-2, 2), (-2, 2)], eps=0.001)
population = Population(indv_template=indv_template, size=50).init()

i want to add a solution like [-1, 1] in first population.
I tried this but i got error:

def init(self, chromsome=None, solution=None):

how can i do this??
thanks

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