1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 numpy,
7 pmdarima,
8 scikit-learn,
9 scipy,
10 pytestCheckHook,
11}:
12
13buildPythonPackage rec {
14 pname = "tbats";
15 version = "1.1.3";
16 pyproject = true;
17
18 src = fetchFromGitHub {
19 owner = "intive-DataScience";
20 repo = "tbats";
21 rev = version;
22 hash = "sha256-f6QqDq/ffbnFBZRAT6KQRlqvZZSE+Pff2/o+htVabZI=";
23 };
24
25 nativeBuildInputs = [ setuptools ];
26
27 propagatedBuildInputs = [
28 numpy
29 pmdarima
30 scikit-learn
31 scipy
32 ];
33
34 nativeCheckInputs = [ pytestCheckHook ];
35
36 enabledTestPaths = [
37 # test_R folder is just for comparison of results with R lib
38 # we need only test folder
39 "test/"
40 ];
41
42 # several tests has same name, so we use --deselect instead of disableTests
43 dilsabledTestPaths = [
44 # Test execution is too long > 15 min
45 "test/tbats/TBATS_test.py::TestTBATS::test_fit_predict_trigonometric_seasonal"
46 ];
47
48 pythonImportsCheck = [ "tbats" ];
49
50 meta = with lib; {
51 description = "BATS and TBATS forecasting methods";
52 homepage = "https://github.com/intive-DataScience/tbats";
53 changelog = "https://github.com/intive-DataScience/tbats/releases/tag/${src.rev}";
54 license = licenses.mit;
55 maintainers = with maintainers; [ mbalatsko ];
56 };
57}