2020-04-17 06:55:38 +02:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, isPy27
|
|
|
|
, numpy
|
|
|
|
, scipy
|
|
|
|
, pytestCheckHook
|
|
|
|
, pytestcov
|
|
|
|
, pytest-timeout
|
|
|
|
, h5py
|
|
|
|
, matplotlib
|
|
|
|
, nibabel
|
|
|
|
, pandas
|
2021-05-14 20:46:36 +02:00
|
|
|
, scikit-learn
|
2020-04-17 06:55:38 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "mne-python";
|
2021-03-24 18:41:51 +01:00
|
|
|
version = "0.22.0";
|
2020-04-17 06:55:38 +02:00
|
|
|
|
|
|
|
disabled = isPy27;
|
|
|
|
|
|
|
|
# PyPI dist insufficient to run tests
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mne-tools";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-03-24 18:41:51 +01:00
|
|
|
sha256 = "1s9pshrl40gkcsdwf4qdga3hjfmdbrvbgjcz0cfx3kl796x3im11";
|
2020-04-17 06:55:38 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ numpy scipy ];
|
|
|
|
|
|
|
|
# all tests pass, but Pytest hangs afterwards - probably some thread hasn't terminated
|
|
|
|
doCheck = false;
|
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
pytestcov
|
|
|
|
pytest-timeout
|
|
|
|
h5py
|
|
|
|
matplotlib
|
|
|
|
nibabel
|
|
|
|
pandas
|
2021-05-14 20:46:36 +02:00
|
|
|
scikit-learn
|
2020-04-17 06:55:38 +02:00
|
|
|
];
|
|
|
|
preCheck = ''
|
|
|
|
export HOME=$TMP
|
|
|
|
export MNE_SKIP_TESTING_DATASET_TESTS=true
|
|
|
|
export MNE_SKIP_NETWORK_TESTS=1
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "mne" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://mne.tools";
|
|
|
|
description = "Magnetoencephelography and electroencephalography in Python";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ bcdarwin ];
|
|
|
|
};
|
|
|
|
}
|