biopython v1.71.0 Bio.GA.Selection.Tournament.TournamentSelection

Implement tournament style selection.

Link to this section Summary

Functions

Initialize the tournament selector

Perform selection on the population using the Tournament model

Link to this section Functions

Initialize the tournament selector.

Arguments:

  • num_competitors - The number of individiuals that should be involved in a selection round. By default we just have two individuals (head to head!).

See AbstractSelection for a description of the arguments to the initializer.

Perform selection on the population using the Tournament model.

Arguments:

  • population - A population of organisms on which we will perform selection. The individuals are assumed to have fitness values which are due to their current genome (ie. the fitness is up to date).