MCPcopy Index your code
hub / github.com/OpenDriveLab/DriveAdapter / _get_init_kwargs

Method _get_init_kwargs

roach/models/ppo.py:249–268  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

247 return self
248
249 def _get_init_kwargs(self):
250 init_kwargs = dict(
251 learning_rate=self.learning_rate,
252 n_steps_total=self.n_steps_total,
253 batch_size=self.batch_size,
254 n_epochs=self.n_epochs,
255 gamma=self.gamma,
256 gae_lambda=self.gae_lambda,
257 clip_range=self.clip_range,
258 clip_range_vf=self.clip_range_vf,
259 ent_coef=self.ent_coef,
260 explore_coef=self.explore_coef,
261 vf_coef=self.vf_coef,
262 max_grad_norm=self.max_grad_norm,
263 target_kl=self.target_kl,
264 update_adv=self.update_adv,
265 lr_schedule_step=self.lr_schedule_step,
266 start_num_timesteps=self.num_timesteps,
267 )
268 return init_kwargs
269
270 def save(self, path: str) -> None:
271 th.save({'policy_state_dict': self.policy.state_dict(),

Callers 1

saveMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected