본문 바로가기
Programming/문제 해결

Gym-Carla 설치시 pygame version 안맞다고 하는 오류

by 꿈꾸는 띵땅근 2021. 6. 2.

https://github.com/cjy1992/gym-carla

 

cjy1992/gym-carla

An OpenAI gym wrapper for CARLA simulator. Contribute to cjy1992/gym-carla development by creating an account on GitHub.

github.com

 

(jeong) mkjeong0@mkjeong0-GP62-7RE:~/sacv3/gym-carla$ pip install -r requirements.txt
Collecting gym==0.12.5
  Using cached gym-0.12.5.tar.gz (1.5 MB)
Collecting pygame==1.9.6
  Using cached pygame-1.9.6.tar.gz (3.2 MB)
    ERROR: Command errored out with exit status 1:
     command: /home/mkjeong0/anaconda3/envs/jeong/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-a1vb3ei7/pygame_cbed02efb00643be9f8daeb52f19d73c/setup.py'"'"'; __file__='"'"'/tmp/pip-install-a1vb3ei7/pygame_cbed02efb00643be9f8daeb52f19d73c/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-sklaohls
         cwd: /tmp/pip-install-a1vb3ei7/pygame_cbed02efb00643be9f8daeb52f19d73c/
    Complete output (13 lines):
    
    
    WARNING, No "Setup" File Exists, Running "buildconfig/config.py"
    Using UNIX configuration...
    
    /bin/sh: 1: sdl-config: not found
    /bin/sh: 1: sdl-config: not found
    /bin/sh: 1: sdl-config: not found
    Unable to run "sdl-config". Please make sure a development version of SDL is installed.
    
    Hunting dependencies...
    WARNING: "sdl-config" failed!
    WARNING: "pkg-config freetype2" failed!
    ----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/0f/9c/78626be04e193c0624842090fe5555b3805c050dfaa81c8094d6441db2be/pygame-1.9.6.tar.gz#sha256=301c6428c0880ecd4a9e3951b80e539c33863b6ff356a443db1758de4f297957 (from https://pypi.org/simple/pygame/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
ERROR: Could not find a version that satisfies the requirement pygame==1.9.6 (from versions: 1.9.2rc1, 1.9.2, 1.9.3, 1.9.4.dev0, 1.9.4rc1, 1.9.4, 1.9.5rc1, 1.9.5rc2, 1.9.5, 1.9.6rc1, 1.9.6rc2, 1.9.6, 2.0.0.dev1, 2.0.0.dev2, 2.0.0.dev3, 2.0.0.dev4, 2.0.0.dev6, 2.0.0.dev8, 2.0.0.dev10, 2.0.0.dev12, 2.0.0.dev14, 2.0.0.dev16, 2.0.0.dev18, 2.0.0.dev20, 2.0.0.dev22, 2.0.0.dev24, 2.0.0, 2.0.1.dev1, 2.0.1)
ERROR: No matching distribution found for pygame==1.9.6

 

 

 

해결

pip install -e .

 

저기 위에 링크에도 나와있는데, requirement 다음줄에 이거 있다. 

그리고 웬만하면 pip install이 아니라, conda install로 해야한다. 

conda list 하면 깔려있는거 쭉 나오는데, 거기에 pygame 있는지, 버전은 어떻게 되는지, 그리고 requirement에서 필요한거 안깔린건 뭔지 이런걸 확인할 수 있다. 

댓글