Skip to content

Commit

Permalink
Made functions global
Browse files Browse the repository at this point in the history
Made randf and Experience global.
  • Loading branch information
c0d3rman committed Jan 25, 2015
1 parent 400eee5 commit 4adb4b1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions deepqlearn.moon
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Brain = {}

-- HELPER FUNCTIONS --

randf = (s, e) ->
export randf = (s, e) ->
return (math.random(0, (e - s) * 9999) / 10000) + s

-- new methods for table
Expand All @@ -35,8 +35,8 @@ table.length = (T) ->
-- state that resulted from the action. This is later used to train the network
-- Remember that the utility of an action is evaluated from the reward gained and
-- the utility of the state it led to (recursive definition)
Experience = (state0, action0, reward0, state1) ->
Experience =
export Experience = (state0, action0, reward0, state1) ->
state0: state0
action0: action0
reward0: reward0
Expand Down

0 comments on commit 4adb4b1

Please sign in to comment.