Skip to content

EvolutionaryConfigsGenAlg

Samuel Gomes edited this page Dec 2, 2019 · 12 revisions

ConfigsGenAlg

This class is a child of ConfigsGenAlg. It uses an evolutionary algorithm to optimize the generation of group configurations. Note: still in development

Constructor and Attributes

Constructor

EvolutionaryConfigsGenAlg(numberOfConfigChoices, minNumberOfPlayersPerGroup, maxNumberOfPlayersPerGroup, preferredNumberOfPlayersPerGroup, fitnessWeights, qualityWeights: PlayerState, regAlg: RegressionAlg, numMutations: int, numFitSurvivors: int, probOfMutation: float)

Attributes

Name: expected type Default value Description
regAlg: RegressionAlg - The regression algorithm used to predict new states from the existing ones
qualityWeights: PlayerCharacteristics PlayerCharacteristics(ability=0.5, engagement=0.5) Weights to consider when calculating the quality of predicted group states

| numMutations: int | - | The number of allowed mutations whenever the mutation operator is selected | | numFitSurvivors: int | The number of allowed survivors between iterations | | probOfMutation: float | The probability of selecting the mutation operator |

Methods

initPopulation(): void

Description

Internal method used to initialize the population (create random group configurations and profiles).

fitnessSort(): void

Description

Internal method used to sort the individuals of the population (group configurations and their profiles).

Clone this wiki locally