Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenDILab开源决策智能平台
DI-engine
提交
9e6de548
D
DI-engine
项目概览
OpenDILab开源决策智能平台
/
DI-engine
上一次同步 2 年多
通知
56
Star
321
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
1
Wiki
分析
仓库
DevOps
项目成员
Pages
D
DI-engine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
1
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
9e6de548
编写于
12月 22, 2021
作者:
P
puyuan1996
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
polish(pu):polish td3_vae config
上级
b65eb2d4
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
7 addition
and
7 deletion
+7
-7
ding/policy/td3_vae.py
ding/policy/td3_vae.py
+2
-2
dizoo/box2d/lunarlander/config/lunarlander_cont_td3_vae_config.py
...x2d/lunarlander/config/lunarlander_cont_td3_vae_config.py
+5
-5
未找到文件。
ding/policy/td3_vae.py
浏览文件 @
9e6de548
...
...
@@ -269,7 +269,7 @@ class TD3VAEPolicy(DDPGPolicy):
result
[
'original_action'
]
=
data
[
'action'
]
result
[
'true_residual'
]
=
data
[
'next_obs'
]
-
data
[
'obs'
]
vae_loss
=
self
.
_vae_model
.
loss_function
(
result
,
kld_weight
=
0.5
,
predict_weight
=
1
0
)
# TODO(pu):weight
vae_loss
=
self
.
_vae_model
.
loss_function
(
result
,
kld_weight
=
0.5
,
predict_weight
=
1
)
# TODO(pu):weight
# recons = args[0]
# prediction_residual = args[1]
# input_action = args[2]
...
...
@@ -338,7 +338,7 @@ class TD3VAEPolicy(DDPGPolicy):
# self.c_percentage_bound_lower = data['latent_action'].sort(dim=0)[0][int(result['recons_action'].shape[0] * 0.02), :] # values, indices
# self.c_percentage_bound_upper = data['latent_action'].sort(dim=0)[0][int(result['recons_action'].shape[0] * 0.98), :]
vae_loss
=
self
.
_vae_model
.
loss_function
(
result
,
kld_weight
=
0.5
,
predict_weight
=
1
0
)
# TODO(pu):weight
vae_loss
=
self
.
_vae_model
.
loss_function
(
result
,
kld_weight
=
0.5
,
predict_weight
=
1
)
# TODO(pu):weight
loss_dict
[
'vae_loss'
]
=
vae_loss
[
'loss'
]
loss_dict
[
'reconstruction_loss'
]
=
vae_loss
[
'reconstruction_loss'
]
...
...
dizoo/box2d/lunarlander/config/lunarlander_cont_td3_vae_config.py
浏览文件 @
9e6de548
...
...
@@ -3,7 +3,7 @@ from ding.entry import serial_pipeline_td3_vae
lunarlander_td3vae_config
=
dict
(
# exp_name='lunarlander_cont_ddpg_vae_lad6_wu1000_rlabelz_novaeupdatez_ns48_rvuc1000_upcr20_upcv1000_notargetnoise_collectoriginalnoise_rbs2e4_rsc',
exp_name
=
'lunarlander_cont_ddpg_vae_lad6_wu1000_rlabelz_novaeupdatez_ns48_rvuc100_upcr2
0_upcv10
0_notargetnoise_collectoriginalnoise_rbs2e4_rsc'
,
# TODO(pu) deubg
exp_name
=
'lunarlander_cont_ddpg_vae_lad6_wu1000_rlabelz_novaeupdatez_ns48_rvuc100_upcr2
_upcv
0_notargetnoise_collectoriginalnoise_rbs2e4_rsc'
,
# TODO(pu) deubg
# exp_name='lunarlander_cont_ddpg_vae_lad6_wu1000_rlabelz_novaeupdatez_ns48_rvuc100_upcr2_upcv100_notargetnoise_collectoriginalnoise_rbs2e4_rsc_lsc',# TODO(pu)
env
=
dict
(
...
...
@@ -40,13 +40,13 @@ lunarlander_td3vae_config = dict(
# rl_vae_update_circle=1,
# update_per_collect_rl=50,
update_per_collect_rl
=
20
,
#
update_per_collect_rl=2,
#
update_per_collect_rl=20,
update_per_collect_rl
=
2
,
update_per_collect_vae
=
100
,
#
update_per_collect_vae=100,
# update_per_collect_vae=20,
# update_per_collect_vae=1,
#
update_per_collect_vae=0,
update_per_collect_vae
=
0
,
batch_size
=
128
,
learning_rate_actor
=
1e-3
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录