2022-01-05 15:13:00 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2021-05-08 09:06:20 +01:00
|
|
|
, pythonOlder
|
2022-02-10 19:36:08 +00:00
|
|
|
, cython
|
2019-07-04 14:49:46 +01:00
|
|
|
, h5py
|
|
|
|
, matplotlib
|
|
|
|
, numpy
|
|
|
|
, phonopy
|
|
|
|
, pymatgen
|
|
|
|
, scipy
|
|
|
|
, seekpath
|
|
|
|
, spglib
|
2021-05-08 09:06:20 +01:00
|
|
|
, castepxbin
|
|
|
|
, pytestCheckHook
|
2019-07-04 14:49:46 +01:00
|
|
|
}:
|
2018-07-11 18:28:05 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "sumo";
|
2022-04-11 02:06:49 +01:00
|
|
|
version = "2.3.0";
|
2022-01-05 15:13:00 +00:00
|
|
|
format = "setuptools";
|
2021-05-08 09:06:20 +01:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2018-07-11 18:28:05 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "SMTG-UCL";
|
|
|
|
repo = "sumo";
|
2022-04-11 02:06:49 +01:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
sha256 = "sha256-apI5Qt7Wrr4FXKL48iqqIQJDX2BIf3PPz/qIgSO7nuo=";
|
2018-07-11 18:28:05 +01:00
|
|
|
};
|
|
|
|
|
2022-02-10 19:36:08 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cython
|
|
|
|
];
|
|
|
|
|
2021-05-08 09:06:20 +01:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
spglib
|
|
|
|
numpy
|
|
|
|
scipy
|
|
|
|
h5py
|
|
|
|
pymatgen
|
|
|
|
phonopy
|
|
|
|
matplotlib
|
|
|
|
seekpath
|
|
|
|
castepxbin
|
|
|
|
];
|
2019-07-04 14:49:46 +01:00
|
|
|
|
2022-01-05 15:13:00 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2022-02-10 19:36:08 +00:00
|
|
|
disabledTests = [
|
|
|
|
# slight disagreement between caastepxbin versions
|
|
|
|
"test_castep_phonon_read_bands"
|
|
|
|
];
|
|
|
|
|
2022-01-05 15:13:00 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace "castepxbin==0.1.0" "castepxbin>=0.1.0"
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"sumo"
|
|
|
|
];
|
2019-07-04 14:49:46 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-07-11 18:28:05 +01:00
|
|
|
description = "Toolkit for plotting and analysis of ab initio solid-state calculation data";
|
2019-07-04 14:49:46 +01:00
|
|
|
homepage = "https://github.com/SMTG-UCL/sumo";
|
2018-07-11 18:28:05 +01:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ psyanticy ];
|
|
|
|
};
|
|
|
|
}
|