Skip to content

Commit

Permalink
amend
Browse files Browse the repository at this point in the history
  • Loading branch information
matteobettini committed Oct 21, 2023
1 parent 27dd56a commit e933b2b
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions benchmarl/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,22 @@

import importlib

from benchmarl import (
algorithms,
benchmark,
environments,
eval_results,
experiment,
models,
utils,
)


_has_hydra = importlib.util.find_spec("hydra") is not None

if _has_hydra:

def load_hydra_schemas():
def _load_hydra_schemas():
from hydra.core.config_store import ConfigStore

from benchmarl.algorithms import algorithm_config_registry
Expand All @@ -28,4 +39,4 @@ def load_hydra_schemas():
for task_schema_name, task_schema in _task_class_registry.items():
cs.store(name=task_schema_name, group="task", node=task_schema)

load_hydra_schemas()
_load_hydra_schemas()

0 comments on commit e933b2b

Please sign in to comment.