1{ lib
2, blas
3, buildPythonPackage
4, cffi
5, fetchFromGitHub
6, liblapack
7, nose
8, numpy
9, openblas
10, useOpenblas ? true
11}:
12
13buildPythonPackage {
14 pname = "prox-tv";
15 version = "3.3.0";
16
17 src = fetchFromGitHub {
18 owner = "albarji";
19 repo = "proxTV";
20 rev = "e621585d5aaa7983fbee68583f7deae995d3bafb";
21 sha256 = "0mlrjbb5rw78dgijkr3bspmsskk6jqs9y7xpsgs35i46dvb327q5";
22 };
23
24 patches = lib.optional useOpenblas ./use-openblas.patch;
25
26 checkInputs = [
27 nose
28 ];
29
30 propagatedBuildInputs = [
31 numpy
32 cffi
33 ];
34
35 buildInputs = (
36 if useOpenblas then
37 [ openblas ]
38 else
39 [ blas liblapack ]
40 );
41
42 enableParallelBuilding = true;
43
44 meta = with lib; {
45 homepage = https://github.com/albarji/proxTV;
46 description = "A toolbox for fast Total Variation proximity operators";
47 license = licenses.bsd2;
48 maintainers = with maintainers; [ multun ];
49 };
50}