NeuralMMO / baselines

Baselines for Neural MMO -- new users should treat this repo as a starter project

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Import "rllib_wrapper" could not be resolved

NKwhz opened this issue · comments

In https://github.com/NeuralMMO/baselines/blob/v1.5.4/demos/training.py, line 11, import rllib_wrapper, I cannot find any package or component called "rllib_wrapper" containing a component "RLlibEnv", which is called in line 37 in the same file. Could someone please help me with this?

/workspace/project/MMO/nmmo-baselines# ./run_tests.sh
Did not find any active Ray processes.
======================================================================================= test session starts ========================================================================================
platform linux -- Python 3.9.7, pytest-7.1.2, pluggy-1.0.0
benchmark: 3.4.1 (defaults: timer=time.perf_counter disable_gc=False min_rounds=5 min_time=0.000005 max_time=1.0 calibration_precision=10 warmup=False warmup_iterations=100000)
rootdir: /workspace/project/MMO/nmmo-baselines
plugins: benchmark-3.4.1
collected 4 items / 2 errors

============================================================================================== ERRORS ==============================================================================================
_______________________________________________________________________________ ERROR collecting tests/test_rllib.py _______________________________________________________________________________
ImportError while importing test module '/workspace/project/MMO/nmmo-baselines/tests/test_rllib.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/opt/conda/envs/rl39/lib/python3.9/importlib/init.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
tests/test_rllib.py:6: in
import rllib_wrapper
E ModuleNotFoundError: No module named 'rllib_wrapper'
______________________________________________________________________________ ERROR collecting tests/test_wrapper.py ______________________________________________________________________________
ImportError while importing test module '/workspace/project/MMO/nmmo-baselines/tests/test_wrapper.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/opt/conda/envs/rl39/lib/python3.9/importlib/init.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
tests/test_wrapper.py:3: in
import rllib_wrapper
E ModuleNotFoundError: No module named 'rllib_wrapper'
===================================================================================== short test summary info ======================================================================================
ERROR tests/test_rllib.py
ERROR tests/test_wrapper.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 2 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

run test failed
how did you solve it

I just gave it up and started to write my own test programs.
It seems that, in this repository, a lot of codes in earlier versions are mistakenly left over, while their dependencies are removed. 'rllib_wrapper' is one of them.

/workspace/project/MMO/nmmo-baselines# ./run_tests.sh Did not find any active Ray processes. ======================================================================================= test session starts ======================================================================================== platform linux -- Python 3.9.7, pytest-7.1.2, pluggy-1.0.0 benchmark: 3.4.1 (defaults: timer=time.perf_counter disable_gc=False min_rounds=5 min_time=0.000005 max_time=1.0 calibration_precision=10 warmup=False warmup_iterations=100000) rootdir: /workspace/project/MMO/nmmo-baselines plugins: benchmark-3.4.1 collected 4 items / 2 errors

============================================================================================== ERRORS ============================================================================================== _______________________________________________________________________________ ERROR collecting tests/test_rllib.py _______________________________________________________________________________ ImportError while importing test module '/workspace/project/MMO/nmmo-baselines/tests/test_rllib.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: /opt/conda/envs/rl39/lib/python3.9/importlib/init.py:127: in import_module return _bootstrap._gcd_import(name[level:], package, level) tests/test_rllib.py:6: in import rllib_wrapper E ModuleNotFoundError: No module named 'rllib_wrapper' ______________________________________________________________________________ ERROR collecting tests/test_wrapper.py ______________________________________________________________________________ ImportError while importing test module '/workspace/project/MMO/nmmo-baselines/tests/test_wrapper.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: /opt/conda/envs/rl39/lib/python3.9/importlib/init.py:127: in import_module return _bootstrap._gcd_import(name[level:], package, level) tests/test_wrapper.py:3: in import rllib_wrapper E ModuleNotFoundError: No module named 'rllib_wrapper' ===================================================================================== short test summary info ====================================================================================== ERROR tests/test_rllib.py ERROR tests/test_wrapper.py !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 2 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

run test failed how did you solve it