QDpy
Loading...
Searching...
No Matches
qdpy.rl.smerl.SMERL Class Reference

Learn discrete latent skills with episode-return gating. More...

Inheritance diagram for qdpy.rl.smerl.SMERL:
qdpy.rl.sac.SAC

Public Member Functions

 train (self, max_env_steps)
 Collect at most max_env_steps interactions on a fresh environment.
Public Member Functions inherited from qdpy.rl.sac.SAC
 stats (self)

Detailed Description

Learn discrete latent skills with episode-return gating.

Train SAC with task reward and a gated discriminator bonus.

Sample one skill uniformly per episode. Open the gate for all of
its transitions if its undiscounted task return meets return_threshold.
The discriminator classifies successor observations from every
completed episode. Recompute bonuses with its current parameters
when sampling replay. The archive and behavioural descriptors are
only used in held-out evaluation.

:param env_factory: Callable creating a single numeric Box/Box environment.
:param return_threshold: Minimum complete-episode task return for the bonus.
:param policy: Optional PolicyConfig for the actor.
:param config: Optional SMERLConfig.
:param max_episode_steps: External time limit for complete episodes.
:param seed: Private seed for initialization, skill draws and rollouts.
:param device: Torch CPU or CUDA device.

Definition at line 178 of file smerl.py.

Member Function Documentation

◆ train()

qdpy.rl.smerl.SMERL.train ( self,
max_env_steps )

Collect at most max_env_steps interactions on a fresh environment.

Count partial episodes toward the budget and exclude them from replay.

Reimplemented from qdpy.rl.sac.SAC.

Definition at line 236 of file smerl.py.


The documentation for this class was generated from the following file: