Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated Epsilon in main_dqn for testing without changing parameter value #11

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion DDQN/main_ddqn.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@
best_score = -np.inf
load_checkpoint = False
n_games = 100
agent = DDQNAgent(gamma=0.99, epsilon=1.0, lr=0.0001,

eps = 1
if load_checkpoint:
eps=0.1
agent = DDQNAgent(gamma=0.99, epsilon=eps, lr=0.0001,
input_dims=(env.observation_space.shape),
n_actions=env.action_space.n, mem_size=50000, eps_min=0.1,
batch_size=32, replace=10000, eps_dec=1e-5,
Expand Down
6 changes: 5 additions & 1 deletion DQN/main_dqn.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,11 @@
load_checkpoint = False
n_games = 250

agent = DQNAgent(gamma=0.99, epsilon=1, lr=0.0001,
eps = 1
if load_checkpoint:
eps=0.1

agent = DQNAgent(gamma=0.99, epsilon=eps, lr=0.0001,
input_dims=(env.observation_space.shape),
n_actions=env.action_space.n, mem_size=50000, eps_min=0.1,
batch_size=32, replace=1000, eps_dec=1e-5,
Expand Down
5 changes: 4 additions & 1 deletion DuelingDDQN/main_dueling_ddqn.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
best_score = -np.inf
load_checkpoint = False
n_games = 20
agent = DuelingDDQNAgent(gamma=0.99, epsilon=1.0, lr=0.0001,
eps = 1
if load_checkpoint:
eps=0.1
agent = DuelingDDQNAgent(gamma=0.99, epsilon=eps, lr=0.0001,
input_dims=(env.observation_space.shape),
n_actions=env.action_space.n, mem_size=50000, eps_min=0.1,
batch_size=32, replace=10000, eps_dec=1e-5,
Expand Down
5 changes: 4 additions & 1 deletion DuelingDQN/main_dueling_dqn.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@
best_score = -np.inf
load_checkpoint = False
n_games = 20
agent = DuelingDQNAgent(gamma=0.99, epsilon=1.0, lr=0.0001,
eps = 1
if load_checkpoint:
eps=0.1
agent = DuelingDQNAgent(gamma=0.99, epsilon=eps, lr=0.0001,
input_dims=(env.observation_space.shape),
n_actions=env.action_space.n, mem_size=50000, eps_min=0.1,
batch_size=32, replace=10000, eps_dec=1e-5,
Expand Down