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

Dian xt ms #29

Open
wants to merge 27 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
modify ppo
  • Loading branch information
AmiyaSX committed May 9, 2023
commit 30f3af232d0825b93d6af33d0b590dea10e9321e
File renamed without changes.
2 changes: 1 addition & 1 deletion xt/model/ppo/ppo_ms.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def __init__(self, model_info):

super().__init__(model_info)
self.predict_net = self.PPOPredictPolicy(self.model, self.dist)
adam = Adam(params=self.predict_net.trainable_params(), learning_rate=0.0005)
adam = Adam(params=self.predict_net.trainable_params(), learning_rate=self._lr, use_amsgrad=False, use_locking=True)
loss_fn = WithLossCell(self.critic_loss_coef, self.clip_ratio, self.ent_coef, self.vf_clip)
forward_fn = NetWithLoss(self.model, loss_fn, self.dist)
self.train_net = MyTrainOneStepCell(forward_fn, optimizer=adam, max_grad_norm=self._max_grad_norm)
Expand Down