Skip to content

Instantly share code, notes, and snippets.

@Shaashwat05 Shaashwat05/evolution.py
Last active May 23, 2020

Embed
What would you like to do?
evolution
def evolve(individuals, losses):
sorted_y_idx_list = sorted(range(len(losses)),key=lambda x:losses[x])
individuals = [individuals[i] for i in sorted_y_idx_list ]
new_individuals = crossover(individuals)
return new_individuals
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.