Fixed potential bug

This commit is contained in:
SimpleArt
2020-11-12 17:49:33 -05:00
parent 45316286c0
commit ae5fed1d71

View File

@ -9,7 +9,7 @@ class Initialization_Methods:
"""
# Using the chromosome_impl to set every index inside of the chromosome
if ga.chromosome_impl != None:
if ga.chromosome_impl is not None:
return ga.make_population([
ga.make_chromosome([
ga.make_gene(value)
@ -17,7 +17,7 @@ class Initialization_Methods:
for i in range(ga.population_size)])
# Using the gene_impl to set every gene to be the same
elif ga.gene_impl != None:
elif ga.gene_impl is not None:
return ga.make_population([
ga.make_chromosome([
ga.make_gene(ga.gene_impl())