Skip to content

Commit

Permalink
Merge pull request #163 from zuoxingdong/add_ddpg2
Browse files Browse the repository at this point in the history
minor update
  • Loading branch information
zuoxingdong committed May 6, 2019
2 parents ebea0eb + 4a712e6 commit 39c6738
Show file tree
Hide file tree
Showing 109 changed files with 36 additions and 237 deletions.
2 changes: 1 addition & 1 deletion baselines/cem/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
from lagom.envs.wrappers import VecStandardizeObservation

from lagom import CEM
from .agent import Agent
from baselines.cem.agent import Agent


config = Config(
Expand Down
2 changes: 1 addition & 1 deletion baselines/cmaes/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
from lagom.envs.wrappers import VecStandardizeObservation

from lagom import CMAES
from .agent import Agent
from baselines.cmaes.agent import Agent


config = Config(
Expand Down
9 changes: 3 additions & 6 deletions baselines/ddpg/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,9 @@
from lagom.envs.wrappers import ClipAction
from lagom.envs.wrappers import VecMonitor

from .agent import Agent
from .engine import Engine
from .replay_buffer import ReplayBuffer
# Test for obs/reward normalization
#from new_engine import Engine
#from new_replay_buffer import ReplayBuffer
from baselines.ddpg.agent import Agent
from baselines.ddpg.engine import Engine
from baselines.ddpg.replay_buffer import ReplayBuffer


config = Config(
Expand Down
113 changes: 0 additions & 113 deletions baselines/ddpg/new_engine.py

This file was deleted.

74 changes: 0 additions & 74 deletions baselines/ddpg/new_replay_buffer.py

This file was deleted.

4 changes: 2 additions & 2 deletions baselines/openaies/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
from lagom.envs.wrappers import VecMonitor
from lagom.envs.wrappers import VecStandardizeObservation

from .openaies import OpenAIES
from .agent import Agent
from baselines.openaies.openaies import OpenAIES
from baselines.openaies.agent import Agent


config = Config(
Expand Down
2 changes: 1 addition & 1 deletion baselines/ppo/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
from lagom.transform import describe

from torch.utils.data import DataLoader
from .dataset import Dataset
from baselines.ppo.dataset import Dataset


class MLP(Module):
Expand Down
4 changes: 2 additions & 2 deletions baselines/ppo/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
from lagom.envs.wrappers import VecStandardizeReward
from lagom.runner import EpisodeRunner

from .agent import Agent
from .engine import Engine
from baselines.ppo.agent import Agent
from baselines.ppo.engine import Engine


config = Config(
Expand Down
6 changes: 3 additions & 3 deletions baselines/td3/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
from lagom.envs.wrappers import ClipAction
from lagom.envs.wrappers import VecMonitor

from .agent import Agent
from .engine import Engine
from .replay_buffer import ReplayBuffer
from baselines.td3.agent import Agent
from baselines.td3.engine import Engine
from baselines.td3.replay_buffer import ReplayBuffer


config = Config(
Expand Down
6 changes: 3 additions & 3 deletions baselines/vpg/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
from lagom.envs.wrappers import VecStandardizeReward
from lagom.runner import EpisodeRunner

from .agent import Agent
from .engine import Engine
from baselines.vpg.agent import Agent
from baselines.vpg.engine import Engine


config = Config(
Expand All @@ -46,7 +46,7 @@

# only for continuous control
'env.clip_action': True, # clip action within valid bound before step()
'agent.std0': 0.5, # initial std
'agent.std0': 0.6, # initial std

'train.timestep': int(1e6), # total number of training (environmental) timesteps
'train.timestep_per_iter': 1000, # number of timesteps per iteration
Expand Down
Binary file removed baselines/vpg/logs/default/0/1500925526/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/0/1770966829/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/0/2054191100/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions baselines/vpg/logs/default/0/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ID: 0
cuda: true
cuda: false
log.dir: logs/default
log.freq: 10
checkpoint.num: 3
Expand All @@ -17,7 +17,7 @@ agent.max_grad_norm: 0.5
agent.entropy_coef: 0.01
agent.value_coef: 0.5
env.clip_action: true
agent.std0: 0.5
agent.std0: 0.6
train.timestep: 1000000
train.timestep_per_iter: 1000
env.id: HalfCheetah-v3
Binary file removed baselines/vpg/logs/default/1/1500925526/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.

This file was deleted.

This file was deleted.

This file was deleted.

Binary file not shown.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/1/1770966829/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/1/2054191100/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions baselines/vpg/logs/default/1/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ID: 1
cuda: true
cuda: false
log.dir: logs/default
log.freq: 10
checkpoint.num: 3
Expand All @@ -17,7 +17,7 @@ agent.max_grad_norm: 0.5
agent.entropy_coef: 0.01
agent.value_coef: 0.5
env.clip_action: true
agent.std0: 0.5
agent.std0: 0.6
train.timestep: 1000000
train.timestep_per_iter: 1000
env.id: Hopper-v3
Binary file removed baselines/vpg/logs/default/2/1500925526/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/2/1770966829/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/2/2054191100/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions baselines/vpg/logs/default/2/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ID: 2
cuda: true
cuda: false
log.dir: logs/default
log.freq: 10
checkpoint.num: 3
Expand All @@ -17,7 +17,7 @@ agent.max_grad_norm: 0.5
agent.entropy_coef: 0.01
agent.value_coef: 0.5
env.clip_action: true
agent.std0: 0.5
agent.std0: 0.6
train.timestep: 1000000
train.timestep_per_iter: 1000
env.id: Walker2d-v3
Binary file removed baselines/vpg/logs/default/3/1500925526/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/3/1770966829/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed baselines/vpg/logs/default/3/2054191100/agent_1.pth
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions baselines/vpg/logs/default/3/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ID: 3
cuda: true
cuda: false
log.dir: logs/default
log.freq: 10
checkpoint.num: 3
Expand All @@ -17,7 +17,7 @@ agent.max_grad_norm: 0.5
agent.entropy_coef: 0.01
agent.value_coef: 0.5
env.clip_action: true
agent.std0: 0.5
agent.std0: 0.6
train.timestep: 1000000
train.timestep_per_iter: 1000
env.id: Swimmer-v3
Binary file modified baselines/vpg/logs/default/configs.pkl
Binary file not shown.
Binary file removed baselines/vpg/logs/default/result.png
Binary file not shown.
8 changes: 4 additions & 4 deletions baselines/vpg/logs/default/source_files/experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@
from lagom.envs.wrappers import VecStandardizeReward
from lagom.runner import EpisodeRunner

from agent import Agent
from engine import Engine
from baselines.vpg.agent import Agent
from baselines.vpg.engine import Engine


config = Config(
{'cuda': True,
{'cuda': False,############True,
'log.dir': 'logs/default',
'log.freq': 10,
'checkpoint.num': 3,
Expand All @@ -46,7 +46,7 @@

# only for continuous control
'env.clip_action': True, # clip action within valid bound before step()
'agent.std0': 0.5, # initial std
'agent.std0': 0.6, # initial std

'train.timestep': int(1e6), # total number of training (environmental) timesteps
'train.timestep_per_iter': 1000, # number of timesteps per iteration
Expand Down

0 comments on commit 39c6738

Please sign in to comment.