nemo_rl.utils.prefetch_venvs#

Module Contents#

Functions#

prefetch_venvs

Prefetch all virtual environments that will be used by workers.

create_frozen_environment_symlinks

Create python-{ClassName} wrapper scripts in /usr/local/bin for frozen environment support.

API#

nemo_rl.utils.prefetch_venvs.prefetch_venvs(filters=None)#

Prefetch all virtual environments that will be used by workers.

Parameters:

filters – List of strings to match against actor FQNs. If provided, only actors whose FQN contains at least one of the filter strings will be prefetched. If None, all venvs are prefetched.

Returns:

The FQNs whose venv failed to build. Empty when everything succeeded. Callers are expected to treat a non-empty list as a failure – see the main block, which exits 1.

Create python-{ClassName} wrapper scripts in /usr/local/bin for frozen environment support.

Only runs in container (when NRL_CONTAINER=1 is set).

Parameters:

venv_configs – Dictionary mapping py_executable to list of actor FQNs