diff --git a/pkgs/development/python-modules/bayespy/default.nix b/pkgs/development/python-modules/bayespy/default.nix new file mode 100644 index 000000000000..9f99708b0714 --- /dev/null +++ b/pkgs/development/python-modules/bayespy/default.nix @@ -0,0 +1,32 @@ +{ stdenv, buildPythonPackage, fetchPypi, pythonOlder +, pytest, glibcLocales +, numpy, scipy, matplotlib, h5py }: + +buildPythonPackage rec { + pname = "bayespy"; + version = "0.5.10"; + name = "${pname}-${version}"; + + # Python 2 not supported and not some old Python 3 because MPL doesn't support + # them properly. + disabled = pythonOlder "3.4"; + + src = fetchPypi { + inherit pname version; + sha256 = "01cwd88ri29zy6qpvnqzljkgc44n7a17yijizr73blcnh4dz5n1w"; + }; + + checkInputs = [ pytest glibcLocales ]; + propagatedBuildInputs = [ numpy scipy matplotlib h5py ]; + + checkPhase = '' + LC_ALL=en_US.utf-8 pytest -k 'not test_message_to_parents' + ''; + + meta = with stdenv.lib; { + homepage = http://www.bayespy.org; + description = "Variational Bayesian inference tools for Python"; + license = licenses.mit; + maintainers = with maintainers; [ jluttine ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5ef570bc5e02..fc3faa099efd 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -135,6 +135,8 @@ in { bap = pkgs.ocamlPackages_4_02.bap; }; + bayespy = callPackage ../development/python-modules/bayespy { }; + bitcoin-price-api = callPackage ../development/python-modules/bitcoin-price-api { }; blivet = callPackage ../development/python-modules/blivet { };