diff --git a/__init__.py b/__init__.py index 71f207b9..316b67c5 100644 --- a/__init__.py +++ b/__init__.py @@ -1,3 +1,3 @@ from .pygad import * # Relative import. -__version__ = "3.0.0" +__version__ = "3.0.1" diff --git a/docs/source/Footer.rst b/docs/source/Footer.rst index 6de145e0..54814baf 100644 --- a/docs/source/Footer.rst +++ b/docs/source/Footer.rst @@ -1279,6 +1279,17 @@ Release Date 8 April 2023 operators roulette wheel and stochastic universal. https://github.com/ahmedfgad/GeneticAlgorithmPython/pull/168 +.. _pygad-301: + +PyGAD 3.0.1 +----------- + +Release Date 20 April 2023 + +1. Fix an issue with passing user-defined function/method for parent + selection. + https://github.com/ahmedfgad/GeneticAlgorithmPython/issues/179 + PyGAD Projects at GitHub ======================== diff --git a/docs/source/conf.py b/docs/source/conf.py index 0799f5e7..eca93138 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -22,7 +22,7 @@ author = 'Ahmed Fawzy Gad' # The full version, including alpha/beta/rc tags -release = '3.0.0' +release = '3.0.1' master_doc = 'index' diff --git a/pygad.py b/pygad.py index 9916a154..b63e6131 100644 --- a/pygad.py +++ b/pygad.py @@ -1747,9 +1747,9 @@ def run(self): # Selecting the best parents in the population for mating. if callable(self.parent_selection_type): - self.last_generation_parents, self.last_generation_parents_indices = self.select_parents(self, - self.last_generation_fitness, - self.num_parents_mating, self) + self.last_generation_parents, self.last_generation_parents_indices = self.select_parents(self.last_generation_fitness, + self.num_parents_mating, + self) if not type(self.last_generation_parents) is numpy.ndarray: self.logger.error("The type of the iterable holding the selected parents is expected to be (numpy.ndarray) but {last_generation_parents_type} found.".format(last_generation_parents_type=type(self.last_generation_parents))) raise TypeError("The type of the iterable holding the selected parents is expected to be (numpy.ndarray) but {last_generation_parents_type} found.".format(last_generation_parents_type=type(self.last_generation_parents)))