1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, isPy27
5, future
6, pytestCheckHook
7, pytorch
8, pyyaml
9, tensorflow-tensorboard
10, tqdm }:
11
12buildPythonPackage rec {
13 pname = "pytorch-lightning";
14 version = "0.8.5";
15
16 disabled = isPy27;
17
18 src = fetchFromGitHub {
19 owner = "PyTorchLightning";
20 repo = pname;
21 rev = version;
22 sha256 = "12zhq4pnfcwbgcx7cs99c751gp3w0ysaf5ykv2lv8f4i360w3r5a";
23 };
24
25 propagatedBuildInputs = [
26 future
27 pytorch
28 pyyaml
29 tensorflow-tensorboard
30 tqdm
31 ];
32
33 checkInputs = [ pytestCheckHook ];
34 # Some packages are not in NixPkgs; other tests try to build distributed
35 # models, which doesn't work in the sandbox.
36 doCheck = false;
37
38 pythonImportsCheck = [ "pytorch_lightning" ];
39
40 meta = with lib; {
41 description = "Lightweight PyTorch wrapper for machine learning researchers";
42 homepage = "https://pytorch-lightning.readthedocs.io";
43 license = licenses.asl20;
44 maintainers = with maintainers; [ tbenst ];
45 };
46}