2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
2021-05-03 20:48:10 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, numpy
|
|
|
|
, requests
|
|
|
|
, pyglet
|
|
|
|
, scipy
|
|
|
|
, pillow
|
|
|
|
, cloudpickle
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "gym";
|
2021-07-14 22:03:04 +00:00
|
|
|
version = "0.18.3";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-03 20:48:10 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "openai";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2021-07-14 22:03:04 +00:00
|
|
|
sha256 = "sha256-10KHUG6WacYzqna97vEhSQWDmJDvDmD5QxLhPW5NQSs=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2021-05-03 20:48:10 +00:00
|
|
|
cloudpickle
|
|
|
|
numpy
|
|
|
|
pillow
|
|
|
|
pyglet
|
|
|
|
requests
|
|
|
|
scipy
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace "Pillow<=8.2.0" "Pillow"
|
|
|
|
'';
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
# The test needs MuJoCo that is not free library.
|
|
|
|
doCheck = false;
|
|
|
|
|
2020-11-06 00:33:48 +00:00
|
|
|
pythonImportsCheck = [ "gym" ];
|
2020-10-07 09:15:18 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
2021-05-03 20:48:10 +00:00
|
|
|
description = "A toolkit for developing and comparing your reinforcement learning agents";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://gym.openai.com/";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ hyphon81 ];
|
|
|
|
};
|
|
|
|
}
|