These are chat archives for drvinceknight/agent-based-learn

12th
Aug 2015
cesaresparza
@cesaresparza
Aug 12 2015 15:57
Hi
Vince Knight
@drvinceknight
Aug 12 2015 15:57
Hi @cesaresparza
cesaresparza
@cesaresparza
Aug 12 2015 15:58
In the morning I updated some files, I am having trouble with assigning the strategies at the beginning of the "simulation"
Vince Knight
@drvinceknight
Aug 12 2015 15:59
I can’t say I know exactly what you mean but it would be something like the code we looked at on Monday. You had a function to assign strategies (which looked like it was never being used), you just need to call that somewhere (towards the beginning of the simulation (perhaps at the end of the init of the simulation).
cesaresparza
@cesaresparza
Aug 12 2015 16:05
Ok. I have this at the end of the init
ga = ablearn.algorithms.genetic.Genetic(generations=100, rounds_per_generation=5, death_rate=0.5, mutation_rate=0.1, exploitation_rate=0.1, initial_strategy_distribution=False)
ga.assign_strategies(env.row_agents, env.row_strategies)
ga.assign_strategies(env.col_agents, env.col_strategies)
self.row_history = [[] for r in range(len(env.row_strategies))]
self.col_history = [[] for c in range(len(env.col_strategies))]
something like that is what you mean, right?
Vince Knight
@drvinceknight
Aug 12 2015 16:41
Yes something like that.
cesaresparza
@cesaresparza
Aug 12 2015 16:42
ok, thank you