From 815dc2a5c3a81164fbc397b0f1d7dfba760381fe Mon Sep 17 00:00:00 2001 From: SimpleArt <71458112+SimpleArt@users.noreply.github.com> Date: Sat, 21 Nov 2020 16:14:10 -0500 Subject: [PATCH] Potentially faster list --- src/mutation/mutation_methods.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mutation/mutation_methods.py b/src/mutation/mutation_methods.py index d39b9e2..7af68f2 100644 --- a/src/mutation/mutation_methods.py +++ b/src/mutation/mutation_methods.py @@ -12,7 +12,7 @@ def loop_selections(selection_method): def loop_mutations(mutation_method): """Runs the mutation method until enough genes are mutated.""" def helper(ga, old_chromosome): - chromosome = ga.make_chromosome(list(old_chromosome)) + chromosome = ga.make_chromosome(old_chromosome.gene_list) for n in range(ceil(len(chromosome)*ga.gene_mutation_rate)): mutation_method(ga, chromosome)