Skip to content

Commit

Permalink
bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
노승은(Seungeun Rho) committed Jan 28, 2020
1 parent 1d44f13 commit 7095e0f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion REINFORCE.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,12 @@ def main():
pi = Policy()
score = 0.0
print_interval = 20
done = False


for n_epi in range(10000):
s = env.reset()
done = False

while not done: # CartPole-v1 forced to terminates at 500 step.
prob = pi(torch.from_numpy(s).float())
m = Categorical(prob)
Expand Down

0 comments on commit 7095e0f

Please sign in to comment.