HumanCompatibleAI / imitation

Clean PyTorch implementations of imitation and reward learning algorithms
https://imitation.readthedocs.io/
MIT License
1.32k stars 246 forks source link

KeyError: 'Ingredient for named config "environment.fast" not found' #733

Closed kierad closed 1 year ago

kierad commented 1 year ago

Bug description

Seeing this error when running quickstart scripts: KeyError: 'Ingredient for named config "environment.fast" not found'

Steps to reproduce

  1. conda create -n imitation1 python=3.8

  2. conda activate imitation1

  3. git clone -b v0.3.1 https://github.com/HumanCompatibleAI/imitation.git

  4. cd imitation

  5. pip install -e ".[dev]" (which results in a very long stack trace ending in:

    File "/Users/kierad/miniconda3/envs/imitation1/lib/python3.8/site-packages/setuptools/_distutils/unixccompiler.py", line 187, in _compile
          raise CompileError(msg)
      distutils.errors.CompileError: command '/usr/bin/gcc' failed with exit code 1
    
      [end of output]
    
    note: This error originates from a subprocess, and is likely not a problem with pip.
    ERROR: Failed building wheel for grpcio
    Running setup.py clean for grpcio
    Successfully built imitation
    Failed to build grpcio
    ERROR: Could not build wheels for grpcio, which is required to install pyproject.toml-based projects

    but it does say that imitation was built successfully.)

  6. python -m imitation.scripts.train_rl with pendulum environment.fast policy_evaluation.fast rl.fast fast logging.log_dir=quickstart/rl/ which produces the error:

    Exception originated from within Sacred.
    Traceback (most recent calls):
    File "/Users/kierad/miniconda3/envs/imitation1/lib/python3.8/site-packages/sacred/initialize.py", line 387, in get_scaffolding_and_config_name
    raise KeyError(
    KeyError: 'Ingredient for named config "environment.fast" not found'

Environment

ernestum commented 1 year ago

Hi @kierad. Thanks for reporting this bug. It occurs in the v0.3.1 version which is from July last year. The current master does not have this issue so I recommend trying that one. We will hopefully have a new release soon with the bugfix (see the milestone here)!