Sephfox commited on
Commit
4d28102
1 Parent(s): 2f82330

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -61,7 +61,7 @@ class GeneticAlgorithm:
61
 
62
  def mutation(self):
63
  for net in self.population:
64
- if random.random() < 0.1:
65
  weights = net.get_weights()
66
  new_weights = [np.array(w) + np.random.randn(*w.shape) * 0.1 for w in weights]
67
  net.set_weights(new_weights)
 
61
 
62
  def mutation(self):
63
  for net in self.population:
64
+ if random.random() < 0.1:
65
  weights = net.get_weights()
66
  new_weights = [np.array(w) + np.random.randn(*w.shape) * 0.1 for w in weights]
67
  net.set_weights(new_weights)