Skip to content

Commit 2ea5328

Browse files
authored
Update Continuous MountainCar Actor Critic Solution.ipynb
it seems in tensorflow 1.o+, `sample_n` method doesn't exist. changed to `_sample_n`. And `sample` is fine too.
1 parent 7ba6649 commit 2ea5328

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

PolicyGradient/Continuous MountainCar Actor Critic Solution.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@
152152
" self.sigma = tf.squeeze(self.sigma)\n",
153153
" self.sigma = tf.nn.softplus(self.sigma) + 1e-5\n",
154154
" self.normal_dist = tf.contrib.distributions.Normal(self.mu, self.sigma)\n",
155-
" self.action = self.normal_dist.sample_n(1)\n",
155+
" self.action = self.normal_dist._sample_n(1)\n",
156156
" self.action = tf.clip_by_value(self.action, env.action_space.low[0], env.action_space.high[0])\n",
157157
"\n",
158158
" # Loss and train op\n",

0 commit comments

Comments
 (0)