python3Packages.pytorch-lightning: Fix build
This commit is contained in:
parent
2daf31d0aa
commit
9ecd6c4c2d
@ -1,47 +1,65 @@
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, isPy27
|
||||
, future
|
||||
, pythonOlder
|
||||
, fsspec
|
||||
, lightning-utilities
|
||||
, numpy
|
||||
, packaging
|
||||
, pytestCheckHook
|
||||
, torch
|
||||
, pyyaml
|
||||
, tensorboard
|
||||
, tensorboardx
|
||||
, torch
|
||||
, torchmetrics
|
||||
, tqdm }:
|
||||
, tqdm
|
||||
, traitlets
|
||||
|
||||
# tests
|
||||
, psutil
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pytorch-lightning";
|
||||
version = "1.8.6";
|
||||
|
||||
disabled = isPy27;
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "PyTorchLightning";
|
||||
repo = pname;
|
||||
owner = "Lightning-AI";
|
||||
repo = "pytorch-lightning";
|
||||
rev = "refs/tags/${version}";
|
||||
hash = "sha256-5AyOCeRFiV7rdmoBPx03Xju6eTR/3jiE+HQBiEmdzmo=";
|
||||
};
|
||||
|
||||
preConfigure = ''
|
||||
export PACKAGE_NAME=pytorch
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
packaging
|
||||
future
|
||||
fsspec
|
||||
torch
|
||||
numpy
|
||||
packaging
|
||||
pyyaml
|
||||
tensorboard
|
||||
tensorboardx
|
||||
torch
|
||||
lightning-utilities
|
||||
torchmetrics
|
||||
tqdm
|
||||
traitlets
|
||||
]
|
||||
++ fsspec.optional-dependencies.http;
|
||||
|
||||
checkInputs = [
|
||||
psutil
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
checkInputs = [ pytestCheckHook ];
|
||||
# Some packages are not in NixPkgs; other tests try to build distributed
|
||||
# models, which doesn't work in the sandbox.
|
||||
doCheck = false;
|
||||
|
||||
pythonImportsCheck = [ "pytorch_lightning" ];
|
||||
pythonImportsCheck = [
|
||||
"pytorch_lightning"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Lightweight PyTorch wrapper for machine learning researchers";
|
||||
|
Loading…
Reference in New Issue
Block a user