2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools,
|
|
|
|
gym,
|
|
|
|
gymnasium,
|
|
|
|
torch,
|
|
|
|
tensorboard,
|
|
|
|
tqdm,
|
|
|
|
wandb,
|
|
|
|
packaging,
|
|
|
|
pytestCheckHook,
|
2022-10-30 15:09:59 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "skrl";
|
2024-02-29 20:09:43 +00:00
|
|
|
version = "1.1.0";
|
2023-11-16 04:20:00 +00:00
|
|
|
pyproject = true;
|
2022-10-30 15:09:59 +00:00
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Toni-SM";
|
|
|
|
repo = pname;
|
2023-03-15 16:39:30 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-02-29 20:09:43 +00:00
|
|
|
hash = "sha256-JsE8QQNOqvFQylrPuHEjejOTeQL652rM0EteAfLyeVI=";
|
2022-10-30 15:09:59 +00:00
|
|
|
};
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
nativeBuildInputs = [ setuptools ];
|
2023-05-24 13:37:59 +00:00
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
gym
|
2023-05-24 13:37:59 +00:00
|
|
|
gymnasium
|
2022-10-30 15:09:59 +00:00
|
|
|
torch
|
|
|
|
tensorboard
|
|
|
|
tqdm
|
2023-05-24 13:37:59 +00:00
|
|
|
wandb
|
2022-10-30 15:09:59 +00:00
|
|
|
packaging
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2022-10-30 15:09:59 +00:00
|
|
|
doCheck = torch.cudaSupport;
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"skrl"
|
|
|
|
"skrl.agents"
|
|
|
|
"skrl.agents.torch"
|
|
|
|
"skrl.envs"
|
|
|
|
"skrl.envs.torch"
|
|
|
|
"skrl.models"
|
|
|
|
"skrl.models.torch"
|
|
|
|
"skrl.resources"
|
|
|
|
"skrl.resources.noises"
|
|
|
|
"skrl.resources.noises.torch"
|
|
|
|
"skrl.resources.schedulers"
|
|
|
|
"skrl.resources.schedulers.torch"
|
|
|
|
"skrl.trainers"
|
|
|
|
"skrl.trainers.torch"
|
|
|
|
"skrl.utils"
|
|
|
|
"skrl.utils.model_instantiators"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Reinforcement learning library using PyTorch focusing on readability and simplicity";
|
|
|
|
homepage = "https://skrl.readthedocs.io";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ bcdarwin ];
|
|
|
|
};
|
|
|
|
}
|