module moplayground.envs.create


function create_environment

create_environment(config, for_training=False, **env_kwargs)

Instantiate a MO-Playground environment from a config.

Dispatches on config['env'] to construct one of the registered multi-objective environments (MOCheetah, MOHopper, MOAnt, MOWalker, MOHumanoid, NaviGait).

Args:

  • config: Config dict (typically loaded from a YAML file in config/) with at least env (str) and env_config (dict) entries. backend is read when for_training is False.
  • for_training: If True, force the JAX ('jnp') backend regardless of config['backend']. Set this when building the environment for GPU training; leave False for evaluation/rollout.
  • **env_kwargs: Extra keyword arguments forwarded to the environment constructor. Currently only consumed by NaviGait (Bruce).

Returns: Tuple (env, env_params) where env is the constructed environment instance and env_params is the resolved ConfigDict of environment parameters.

Raises:

  • Exception: If config['env'] does not match a registered environment name.

This site uses Just the Docs, a documentation theme for Jekyll.