1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 pytestCheckHook,
7 numpy,
8 scipy,
9 statsmodels,
10}:
11
12buildPythonPackage {
13 pname = "changefinder";
14 version = "unstable-2024-03-24";
15 pyproject = true;
16
17 src = fetchFromGitHub {
18 owner = "shunsukeaihara";
19 repo = "changefinder";
20 rev = "58c8c32f127b9e46f9823f36221f194bdb6f3f8b";
21 hash = "sha256-1If0gIsMU8673fKSSHVMvDgR1UnYgM/4HiyvZJ9T6VM=";
22 };
23
24 patches = [ ./fix_test_invocation.patch ];
25
26 build-system = [ setuptools ];
27
28 pythonRemoveDeps = [ "nose" ];
29
30 dependencies = [
31 numpy
32 scipy
33 statsmodels
34 ];
35
36 nativeCheckInputs = [ pytestCheckHook ];
37 enabledTestPaths = [ "test/test.py" ];
38
39 pythonImportsCheck = [ "changefinder" ];
40
41 meta = with lib; {
42 description = "Online Change-Point Detection library based on ChangeFinder algorithm";
43 homepage = "https://github.com/shunsukeaihara/changefinder";
44 license = licenses.mit;
45 maintainers = with maintainers; [ raitobezarius ];
46 };
47}