2016-11-14 12:23:53 +01:00
|
|
|
{ stdenv
|
2018-06-23 15:27:58 +02:00
|
|
|
, fetchPypi
|
2016-11-14 12:23:53 +01:00
|
|
|
, buildPythonPackage
|
|
|
|
, sphinx
|
|
|
|
, pytestcov
|
|
|
|
, pytest
|
|
|
|
, Mako
|
|
|
|
, numpy
|
|
|
|
, funcsigs
|
|
|
|
, withCuda ? false, pycuda
|
|
|
|
, withOpenCL ? true, pyopencl
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "reikna";
|
2019-05-30 08:47:55 +02:00
|
|
|
version = "0.7.4";
|
2016-11-14 12:23:53 +01:00
|
|
|
|
2018-06-23 15:27:58 +02:00
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-05-30 08:47:55 +02:00
|
|
|
sha256 = "52bbce24fa1fd7bb950d38ce9b60f497dd00ac6b26688d80ab9bce709f063e71";
|
2016-11-14 12:23:53 +01:00
|
|
|
};
|
|
|
|
|
2018-06-23 15:27:58 +02:00
|
|
|
checkInputs = [ sphinx pytestcov pytest ];
|
2016-11-14 12:23:53 +01:00
|
|
|
|
|
|
|
propagatedBuildInputs = [ Mako numpy funcsigs ]
|
|
|
|
++ stdenv.lib.optional withCuda pycuda
|
|
|
|
++ stdenv.lib.optional withOpenCL pyopencl;
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
py.test
|
|
|
|
'';
|
|
|
|
|
|
|
|
# Requires device
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "GPGPU algorithms for PyCUDA and PyOpenCL";
|
2017-11-10 22:13:27 +01:00
|
|
|
homepage = https://github.com/fjarri/reikna;
|
2016-11-14 12:23:53 +01:00
|
|
|
license = stdenv.lib.licenses.mit;
|
2017-12-05 23:20:11 +01:00
|
|
|
maintainers = [ stdenv.lib.maintainers.fridh ];
|
2016-11-14 12:23:53 +01:00
|
|
|
|
|
|
|
};
|
|
|
|
|
2017-12-05 23:20:11 +01:00
|
|
|
}
|