Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / trainer / default.nix
blob848b970248f0243cdfff14399e5e4cfcb180fd52
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
5 , coqpit
6 , fsspec
7 , torch
8 , tensorboard
9 , protobuf
10 , psutil
12 , pytestCheckHook
13 , soundfile
14 , torchvision
17 let
18   pname = "trainer";
19   version = "0.0.36";
21 buildPythonPackage {
22   inherit pname version;
23   format = "pyproject";
25   src = fetchFromGitHub {
26     owner = "coqui-ai";
27     repo = "Trainer";
28     rev = "refs/tags/v${version}";
29     hash = "sha256-z6TOzWqE3NytkdG3nUzh9GpFVGQEXFyzSQ8gvdB4wiw=";
30   };
32   postPatch = ''
33     sed -i 's/^protobuf.*/protobuf/' requirements.txt
34   '';
36   propagatedBuildInputs = [
37     coqpit
38     fsspec
39     protobuf
40     psutil
41     soundfile
42     tensorboard
43     torch
44   ];
46   # only one test and that requires training data from the internet
47   doCheck = false;
49   nativeCheckInputs = [
50     pytestCheckHook
51     torchvision
52   ];
54   pythonImportsCheck = [
55     "trainer"
56   ];
58   meta = with lib; {
59     description = "A general purpose model trainer, as flexible as it gets";
60     homepage = "https://github.com/coqui-ai/Trainer";
61     changelog = "https://github.com/coqui-ai/Trainer/releases/tag/v${version}";
62     license = licenses.asl20;
63     maintainers = teams.tts.members;
64   };