In [1]:
import sys
if "../" not in sys.path:
sys.path.append("../")
import matplotlib
%matplotlib inline
matplotlib.style.use('ggplot')
from envs.cliff_walking import CliffWalkingEnv
from utils import plotting
from double_q_learning import double_q_learning
# for auto-reloading external modules
# see http://stackoverflow.com/questions/1907993/autoreload-of-modules-in-ipython
%load_ext autoreload
%autoreload 2
In [2]:
env = CliffWalkingEnv()
In [3]:
Q1, Q2, stats = double_q_learning(env, 500)
In [4]:
plotting.plot_episode_stats(stats)
Out[4]:
In [ ]: