Skip to content

Commit

Permalink
Remove unnecessary white space from algorithms.py
Browse files Browse the repository at this point in the history
  • Loading branch information
gkhayes committed Nov 3, 2019
1 parent 04438d0 commit bc81793
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mlrose/algorithms.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,14 +87,14 @@ def hill_climb(problem, max_iters=np.inf, restarts=0, init_state=None,
problem.find_neighbors()
next_state = problem.best_neighbor()
next_fitness = problem.eval_fitness(next_state)

# If best neighbor is an improvement, move to that state
if next_fitness > problem.get_fitness():
problem.set_state(next_state)

else:
break

if curve:
fitness_curve.append(problem.get_fitness())

Expand Down

0 comments on commit bc81793

Please sign in to comment.