Skip to content

Commit

Permalink
Update to examples, adding cost_fn_args to cost functions
Browse files Browse the repository at this point in the history
  • Loading branch information
tjkessler committed Sep 13, 2018
1 parent 2f40e48 commit bf6fddc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/example_maximize_integers.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

# Cost function; finds the sum of integers in feed_dict
# (fitness score = sum)
def sum_of_integers(feed_dict):
def sum_of_integers(feed_dict, cost_fn_args=None):
sum = 0
for integer in feed_dict:
sum += feed_dict[integer]
Expand Down
2 changes: 1 addition & 1 deletion examples/example_minimize_integers.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

# Cost function; finds the sum of integers in feed_dict
# (fitness score = sum)
def sum_of_integers(feed_dict):
def sum_of_integers(feed_dict, cost_fn_args=None):
sum = 0
for integer in feed_dict:
sum += feed_dict[integer]
Expand Down

0 comments on commit bf6fddc

Please sign in to comment.