Skip to content

Commit

Permalink
Merge pull request #18 from minimada/init_engine_with_fitness
Browse files Browse the repository at this point in the history
fix init engine with fitness is not working
  • Loading branch information
PytLab authored May 10, 2018
2 parents b34efcf + c5093f3 commit 2cb33b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gaft/engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def __init__(self, population, selection, crossover, mutation,
self._ori_fmax, self._ori_fmin, self._ori_fmean = None, None, None

# Default fitness functions.
self.ori_fitness, self.fitness = None, None
self.ori_fitness = None if self.fitness is None else self.fitness

# Store current generation number.
self.current_generation = -1 # Starts from 0.
Expand Down

0 comments on commit 2cb33b1

Please sign in to comment.