at 24.11-pre 1.2 kB view raw
1{ 2 buildPythonPackage, 3 lib, 4 fetchFromGitHub, 5 absl-py, 6 enum34, 7 future, 8 mock, 9 mpyq, 10 numpy, 11 portpicker, 12 protobuf, 13 pygame, 14 s2clientprotocol, 15 six, 16 websocket-client, 17 sc2-headless, 18}: 19 20buildPythonPackage { 21 pname = "pysc2"; 22 version = "1.2"; 23 24 src = fetchFromGitHub { 25 owner = "deepmind"; 26 repo = "pysc2"; 27 rev = "39f84b01d662eb58b3d95791f59208c210afd4e7"; 28 sha256 = "0dfbc2krd2rys1ji75ng2nl0ki8nhnylxljcp287bfb8qyz2m25p"; 29 }; 30 31 patches = [ 32 ./fix-setup-for-py3.patch 33 ./parameterize-runconfig-sc2path.patch 34 ]; 35 36 postPatch = '' 37 substituteInPlace "./pysc2/run_configs/platforms.py" \ 38 --subst-var-by 'sc2path' '${sc2-headless}' 39 ''; 40 41 propagatedBuildInputs = [ 42 absl-py 43 enum34 44 future 45 mock 46 mpyq 47 numpy 48 portpicker 49 protobuf 50 pygame 51 s2clientprotocol 52 six 53 websocket-client 54 sc2-headless 55 ]; 56 57 meta = { 58 description = "Starcraft II environment and library for training agents."; 59 homepage = "https://github.com/deepmind/pysc2"; 60 license = lib.licenses.asl20; 61 platforms = lib.platforms.linux; 62 maintainers = with lib.maintainers; [ ]; 63 }; 64}