Skip to content
This repository has been archived by the owner on May 21, 2022. It is now read-only.

Episode iterator #2

Open
tbreloff opened this issue Apr 30, 2016 · 0 comments
Open

Episode iterator #2

tbreloff opened this issue Apr 30, 2016 · 0 comments

Comments

@tbreloff
Copy link
Member

Something like:

type Episode
    steps_remaining::Int
end
# iteration methods... decrement steps_remaining and get the state

env = Env(....)
for state in Episode(env, maxsteps = 100)
    # pick an action
    act(env, action)
end

note: Env should store the next action to apply so it can be applied (by calling step) in the iterator

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant