nixpkgs/pkgs/development/python-modules/einops/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

75 lines
1.3 KiB
Nix
Raw Normal View History

2021-09-12 12:03:22 +00:00
{ lib
, buildPythonPackage
, chainer
, fetchFromGitHub
, jupyter
, keras
#, mxnet
, nbconvert
, nbformat
, nose
, numpy
, parameterized
, pytestCheckHook
, pythonOlder
2021-09-12 12:03:22 +00:00
}:
buildPythonPackage rec {
pname = "einops";
2022-03-29 22:13:22 +00:00
version = "0.4.1";
format = "setuptools";
disabled = pythonOlder "3.7";
2021-09-12 12:03:22 +00:00
src = fetchFromGitHub {
owner = "arogozhnikov";
repo = pname;
rev = "v${version}";
2022-03-29 22:13:22 +00:00
hash = "sha256-n4R4lcRimuOncisCTs2zJWPlqZ+W2yPkvkWAnx4R91s=";
2021-09-12 12:03:22 +00:00
};
checkInputs = [
chainer
jupyter
keras
# mxnet (has issues with some CPUs, segfault)
nbconvert
nbformat
2021-09-12 12:03:22 +00:00
nose
numpy
2022-03-29 22:13:22 +00:00
parameterized
pytestCheckHook
2021-09-12 12:03:22 +00:00
];
# No CUDA in sandbox
EINOPS_SKIP_CUPY = 1;
preCheck = ''
export HOME=$(mktemp -d);
'';
2021-12-30 17:17:41 +00:00
pythonImportsCheck = [
"einops"
];
2021-12-30 17:17:41 +00:00
disabledTests = [
# Tests are failing as mxnet is not pulled-in
# https://github.com/NixOS/nixpkgs/issues/174872
"test_all_notebooks"
"test_dl_notebook_with_all_backends"
"test_backends_installed"
];
disabledTestPaths = [
"tests/test_layers.py"
];
2021-09-12 12:03:22 +00:00
meta = with lib; {
2021-09-12 12:03:22 +00:00
description = "Flexible and powerful tensor operations for readable and reliable code";
homepage = "https://github.com/arogozhnikov/einops";
license = licenses.mit;
maintainers = with maintainers; [ yl3dy ];
2021-09-12 12:03:22 +00:00
};
}