My personal project and infrastructure archive
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nomicon/pkgs/development/python-modules/pymc3/default.nix

72 lines
1.4 KiB

{ lib
, fetchPypi
, buildPythonPackage
, pythonOlder
, theano-pymc
, pandas
, patsy
, joblib
, cachetools
, tqdm
, six
, h5py
, arviz
, packaging
, pytest
, nose
, parameterized
, fastprogress
, typing-extensions
, dill
, semver
}:
buildPythonPackage rec {
pname = "pymc3";
version = "3.11.5";
disabled = pythonOlder "3.5";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-M0HLvZYpCROLfV6+TtfP7in0Cy/nyt64iLOda7wXE4w=";
};
# No need for coverage stats in Nix builds
postPatch = ''
substituteInPlace setup.py --replace ", 'pytest-cov'" ""
'';
propagatedBuildInputs = [
pandas
patsy
joblib
tqdm
six
h5py
arviz
packaging
fastprogress
typing-extensions
dill
theano-pymc
cachetools
semver
];
# The test suite is computationally intensive and test failures are not
# indicative for package usability hence tests are disabled by default.
doCheck = false;
pythonImportsCheck = [ "pymc3" ];
# For some reason tests are run as a part of the *install* phase if enabled.
# Theano writes compiled code to ~/.theano hence we set $HOME.
preInstall = "export HOME=$(mktemp -d)";
postInstall = "rm -rf $HOME";
meta = {
description = "Bayesian estimation, particularly using Markov chain Monte Carlo (MCMC)";
homepage = "https://github.com/pymc-devs/pymc3";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ nidabdella ];
};
}