1{ lib
2, buildPythonPackage
3, fetchPypi
4, numpy
5, pytestCheckHook
6, pythonOlder
7}:
8
9buildPythonPackage rec {
10 version = "3.3.0";
11 pname = "opt-einsum";
12 format = "setuptools";
13
14 disabled = pythonOlder "3.6";
15
16 src = fetchPypi {
17 pname = "opt_einsum";
18 inherit version;
19 hash = "sha256-WfZHX3e7w33PfNdIUZwOxgci6R5jyhFOaIIcDFSkZUk=";
20 };
21
22 propagatedBuildInputs = [
23 numpy
24 ];
25
26 nativeCheckInputs = [
27 pytestCheckHook
28 ];
29
30 pythonImportsCheck = [
31 "opt_einsum"
32 ];
33
34 meta = with lib; {
35 description = "Optimizing NumPy's einsum function with order optimization and GPU support";
36 homepage = "https://github.com/dgasmith/opt_einsum";
37 license = licenses.mit;
38 maintainers = with maintainers; [ teh ];
39 };
40}