|
from easydict import EasyDict |
|
|
|
bipedalwalker_impala_config = dict( |
|
exp_name='bipedalwalker_impala_seed0', |
|
env=dict( |
|
env_id='BipedalWalker-v3', |
|
collector_env_num=8, |
|
evaluator_env_num=8, |
|
|
|
act_scale=True, |
|
n_evaluator_episode=8, |
|
stop_value=300, |
|
rew_clip=True, |
|
|
|
|
|
), |
|
policy=dict( |
|
cuda=True, |
|
|
|
unroll_len=32, |
|
random_collect_size=256, |
|
|
|
action_space='continuous', |
|
model=dict( |
|
action_space='continuous', |
|
obs_shape=24, |
|
action_shape=4, |
|
), |
|
learn=dict( |
|
|
|
|
|
update_per_collect=3, |
|
|
|
batch_size=64, |
|
grad_clip_type='clip_norm', |
|
clip_value=5, |
|
learning_rate=0.0003, |
|
|
|
value_weight=0.5, |
|
|
|
entropy_weight=0.01, |
|
|
|
discount_factor=0.99, |
|
|
|
lambda_=0.99, |
|
), |
|
collect=dict( |
|
|
|
n_sample=32, |
|
collector=dict(collect_print_freq=1000, ), |
|
), |
|
eval=dict(evaluator=dict(eval_freq=100, )), |
|
other=dict(replay_buffer=dict(replay_buffer_size=10000, ), ), |
|
), |
|
) |
|
bipedalwalker_impala_config = EasyDict(bipedalwalker_impala_config) |
|
main_config = bipedalwalker_impala_config |
|
bipedalwalker_impala_create_config = dict( |
|
env=dict( |
|
type='bipedalwalker', |
|
import_names=['dizoo.box2d.bipedalwalker.envs.bipedalwalker_env'], |
|
), |
|
env_manager=dict(type='subprocess'), |
|
policy=dict(type='impala'), |
|
replay_buffer=dict(type='naive'), |
|
) |
|
bipedalwalker_impala_create_config = EasyDict(bipedalwalker_impala_create_config) |
|
create_config = bipedalwalker_impala_create_config |
|
|
|
if __name__ == "__main__": |
|
|
|
from ding.entry import serial_pipeline |
|
serial_pipeline([main_config, create_config], seed=0) |
|
|