2018-11-11 04:09:19 +00:00
|
|
|
{ lib
|
2021-04-29 09:12:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, numpy
|
|
|
|
, cloudpickle
|
2022-11-01 09:36:26 +00:00
|
|
|
, gym-notices
|
|
|
|
, importlib-metadata
|
|
|
|
, pythonOlder
|
2018-11-11 04:09:19 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "gym";
|
2022-11-01 09:36:26 +00:00
|
|
|
version = "0.26.2";
|
2018-11-11 04:09:19 +00:00
|
|
|
|
2021-04-29 09:12:52 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "openai";
|
|
|
|
repo = pname;
|
2023-01-03 21:30:06 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2022-11-01 09:36:26 +00:00
|
|
|
sha256 = "sha256-uJgm8l1SxIRC5PV6BIH/ht/1ucGT5UaUhkFMdusejgA=";
|
2018-11-11 04:09:19 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2021-04-29 09:12:52 +00:00
|
|
|
cloudpickle
|
|
|
|
numpy
|
2022-11-01 09:36:26 +00:00
|
|
|
gym-notices
|
|
|
|
] ++ lib.optionals (pythonOlder "3.10") [ importlib-metadata ];
|
2018-11-11 04:09:19 +00:00
|
|
|
|
|
|
|
# The test needs MuJoCo that is not free library.
|
|
|
|
doCheck = false;
|
|
|
|
|
2020-11-04 01:59:35 +00:00
|
|
|
pythonImportsCheck = [ "gym" ];
|
2020-09-23 20:37:37 +00:00
|
|
|
|
2018-11-11 04:09:19 +00:00
|
|
|
meta = with lib; {
|
2021-04-29 09:12:52 +00:00
|
|
|
description = "A toolkit for developing and comparing your reinforcement learning agents";
|
2020-03-03 03:24:58 +00:00
|
|
|
homepage = "https://gym.openai.com/";
|
2018-11-11 04:09:19 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ hyphon81 ];
|
|
|
|
};
|
|
|
|
}
|