2019-03-27 21:27:22 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2019-06-28 22:23:38 +01:00
|
|
|
, fetchFromGitHub
|
2019-03-27 21:27:22 +00:00
|
|
|
, pytest
|
|
|
|
, gym
|
|
|
|
, scipy
|
|
|
|
, tqdm
|
|
|
|
, joblib
|
|
|
|
, dill
|
|
|
|
, progressbar2
|
|
|
|
, cloudpickle
|
|
|
|
, click
|
|
|
|
, pyzmq
|
|
|
|
, tensorflow
|
|
|
|
, mpi4py
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "baselines";
|
2019-06-28 22:23:38 +01:00
|
|
|
version = "0.1.6"; # remember to manually adjust the rev
|
2019-03-27 21:27:22 +00:00
|
|
|
|
2019-06-28 22:23:38 +01:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "openai";
|
|
|
|
repo = "baselines";
|
|
|
|
# Unfortunately releases are not tagged. This commit bumps the version in setup.py
|
|
|
|
rev = "2bca7901f51c88cdef3ca0666c6a87c454a4dbe8";
|
|
|
|
sha256 = "0j2ck7rsrcyny9qbmrw9aqvzfhv70nbign8iva2dsisa2x24gbcl";
|
2019-03-27 21:27:22 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
gym
|
|
|
|
scipy
|
|
|
|
tqdm
|
|
|
|
joblib
|
|
|
|
pyzmq
|
|
|
|
dill
|
|
|
|
progressbar2
|
|
|
|
mpi4py
|
|
|
|
cloudpickle
|
|
|
|
tensorflow
|
|
|
|
click
|
|
|
|
];
|
|
|
|
|
2019-06-28 22:23:38 +01:00
|
|
|
postPatch = ''
|
|
|
|
# Needed for the atari wrapper, but the gym-atari package is not supported
|
|
|
|
# in nixos anyways. Since opencv-python is not currently packaged, we
|
|
|
|
# disable it.
|
|
|
|
sed -ie '/opencv-python/d' setup.py
|
|
|
|
'';
|
|
|
|
|
2019-03-27 21:27:22 +00:00
|
|
|
# fails to create a daemon, probably because of sandboxing
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "High-quality implementations of reinforcement learning algorithms";
|
|
|
|
homepage = https://github.com/openai/baselines;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ timokau ];
|
|
|
|
};
|
|
|
|
}
|