mirror of
https://github.com/saymrwulf/stable-baselines3.git
synced 2026-09-17 22:30:59 +00:00
Fix PPO logging of clip_fractions (#150)
* bugfix for PPO logging of clip_fractions * Update changelog.rst Co-authored-by: Antonin RAFFIN <antonin.raffin@ensta.org>
This commit is contained in:
parent
f8c25d3b71
commit
4fd408bec2
2 changed files with 3 additions and 1 deletions
|
|
@ -18,6 +18,7 @@ New Features:
|
||||||
Bug Fixes:
|
Bug Fixes:
|
||||||
^^^^^^^^^^
|
^^^^^^^^^^
|
||||||
- Fixed a bug where the environment was reset twice when using ``evaluate_policy``
|
- Fixed a bug where the environment was reset twice when using ``evaluate_policy``
|
||||||
|
- Fix logging of ``clip_fraction`` in PPO (@diditforlulz273)
|
||||||
|
|
||||||
Deprecations:
|
Deprecations:
|
||||||
^^^^^^^^^^^^^
|
^^^^^^^^^^^^^
|
||||||
|
|
@ -398,3 +399,4 @@ And all the contributors:
|
||||||
@MarvineGothic @jdossgollin @SyllogismRXS @rusu24edward @jbulow @Antymon @seheevic @justinkterry @edbeeching
|
@MarvineGothic @jdossgollin @SyllogismRXS @rusu24edward @jbulow @Antymon @seheevic @justinkterry @edbeeching
|
||||||
@flodorner @KuKuXia @NeoExtended @PartiallyTyped @mmcenta @richardwu @kinalmehta @rolandgvc @tkelestemur @mloo3
|
@flodorner @KuKuXia @NeoExtended @PartiallyTyped @mmcenta @richardwu @kinalmehta @rolandgvc @tkelestemur @mloo3
|
||||||
@tirafesi @blurLake @koulakis @joeljosephjin @shwang @rk37 @andyshih12 @RaphaelWag @xicocaio
|
@tirafesi @blurLake @koulakis @joeljosephjin @shwang @rk37 @andyshih12 @RaphaelWag @xicocaio
|
||||||
|
@diditforlulz273
|
||||||
|
|
|
||||||
|
|
@ -228,7 +228,7 @@ class PPO(OnPolicyAlgorithm):
|
||||||
logger.record("train/policy_gradient_loss", np.mean(pg_losses))
|
logger.record("train/policy_gradient_loss", np.mean(pg_losses))
|
||||||
logger.record("train/value_loss", np.mean(value_losses))
|
logger.record("train/value_loss", np.mean(value_losses))
|
||||||
logger.record("train/approx_kl", np.mean(approx_kl_divs))
|
logger.record("train/approx_kl", np.mean(approx_kl_divs))
|
||||||
logger.record("train/clip_fraction", np.mean(clip_fraction))
|
logger.record("train/clip_fraction", np.mean(clip_fractions))
|
||||||
logger.record("train/loss", loss.item())
|
logger.record("train/loss", loss.item())
|
||||||
logger.record("train/explained_variance", explained_var)
|
logger.record("train/explained_variance", explained_var)
|
||||||
if hasattr(self.policy, "log_std"):
|
if hasattr(self.policy, "log_std"):
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue