Evolife
Evolife has been developed to study Genetic algorithms, Natural evolution and behavioural ecology.
Public Member Functions | Public Attributes | List of all members
Evolife.Ecology.Population.EvolifePopulation Class Reference

Population + reproduction + call to Scenario life_game. More...

Inheritance diagram for Evolife.Ecology.Population.EvolifePopulation:
Inheritance graph
[legend]
Collaboration diagram for Evolife.Ecology.Population.EvolifePopulation:
Collaboration graph
[legend]

Public Member Functions

def __init__ (self, Scenario, Evolife_Obs)
 Creation of groups. More...
 
def createGroup (self, ID=0, Size=0)
 This version of 'createGroup' calls the 'EvolifeGroup' class instead of the 'Group' class. More...
 
def reproduction (self)
 launches reproduction in groups More...
 
def life_game (self)
 Calls local 'life_game' in groups. More...
 
def one_year (self)
 Population's 'one_year' + calls to 'reproduction' and 'life_game'. More...
 
- Public Member Functions inherited from Evolife.Ecology.Population.Population
def __init__ (self, Scenario, Observer)
 Creation of the groups - calls createGroup. More...
 
def createGroup (self, ID=0, Size=0)
 Calls class 'Group'. More...
 
def selectIndividual (self)
 random selection of an individual in the population More...
 
def lottery (self)
 random selection of an individual by number in the population More...
 
def season (self)
 increments 'year' and calls Oberver's season and groups' season More...
 
def migration (self)
 migration between groups of some percentage of individuals More...
 
def group_splitting (self)
 groups that are too big are split in two, and groups that are too small are dispersed More...
 

Public Attributes

 popSize
 
- Public Attributes inherited from Evolife.Ecology.Population.Population
 Scenario
 
 popSize
 
 groupMaxSize
 
 groups
 
 year
 
 Observer
 
 best_score
 

Detailed Description

Population + reproduction + call to Scenario life_game.

Definition at line 221 of file Population.py.

Constructor & Destructor Documentation

◆ __init__()

def Evolife.Ecology.Population.EvolifePopulation.__init__ (   self,
  Scenario,
  Evolife_Obs 
)

Creation of groups.

Reimplemented from Evolife.Ecology.Population.Population.

Definition at line 224 of file Population.py.

Member Function Documentation

◆ createGroup()

def Evolife.Ecology.Population.EvolifePopulation.createGroup (   self,
  ID = 0,
  Size = 0 
)

This version of 'createGroup' calls the 'EvolifeGroup' class instead of the 'Group' class.

Reimplemented from Evolife.Ecology.Population.Population.

Reimplemented in Evolife.Scenarii.CustomScenario.Population.

Definition at line 239 of file Population.py.

◆ life_game()

def Evolife.Ecology.Population.EvolifePopulation.life_game (   self)

Calls local 'life_game' in groups.

Definition at line 251 of file Population.py.

◆ one_year()

def Evolife.Ecology.Population.EvolifePopulation.one_year (   self)

Population's 'one_year' + calls to 'reproduction' and 'life_game'.

Definition at line 257 of file Population.py.

◆ reproduction()

def Evolife.Ecology.Population.EvolifePopulation.reproduction (   self)

launches reproduction in groups

Definition at line 244 of file Population.py.

Member Data Documentation

◆ popSize

Evolife.Ecology.Population.EvolifePopulation.popSize

Definition at line 233 of file Population.py.


The documentation for this class was generated from the following file: