at 18.03-beta 1.2 kB view raw
1{ buildPythonPackage 2, lib 3, fetchFromGitHub 4, absl-py 5, enum34 6, future 7, futures 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 rec { 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; [ danharaj ]; 63 }; 64}