예제 #1
0
    def conditional_precedence_reserving_mutation(problem, child, probability):
        new_child = Heuristics.mutation_operation(child, probability)
        new_child2 = Heuristics.mutation_machine(new_child, probability)

        return min([child, new_child, new_child2],
                   key=lambda x: Chromosome.compute_makespan(x, problem))
예제 #2
0
    def precedence_reserving_mutation(problem, child, probability):
        new_child = Heuristics.mutation_operation(child, probability)
        new_child2 = Heuristics.mutation_machine(new_child, probability)

        return new_child2