hydrotoolbox 2.0.14__tar.gz → 2.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (139) hide show
  1. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.github/workflows/pypi-package.yml +2 -2
  2. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.github/workflows/tests.yml +22 -32
  3. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.pre-commit-config.yaml +9 -11
  4. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/CHANGELOG.md +12 -0
  5. {hydrotoolbox-2.0.14/src/hydrotoolbox.egg-info → hydrotoolbox-2.2.0}/PKG-INFO +10 -10
  6. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/README.rst +1 -1
  7. hydrotoolbox-2.2.0/VERSION +1 -0
  8. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/command_line.rst +6 -11
  9. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/function_summary.rst +2 -3
  10. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/index.rst +3 -3
  11. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/pyproject.toml +29 -33
  12. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/__init__.py +12 -11
  13. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/__init__.py +4 -4
  14. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/comparison.py +5 -0
  15. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/__init__.py +4 -4
  16. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/boughton.py +21 -0
  17. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/chapman.py +14 -0
  18. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/chapman_maxwell.py +14 -0
  19. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/eckhardt.py +22 -0
  20. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/ewma.py +4 -0
  21. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/five_day.py +4 -0
  22. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/fixed.py +5 -1
  23. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/furey.py +28 -0
  24. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/general_form.py +56 -0
  25. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/ihacres.py +9 -8
  26. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/local.py +5 -1
  27. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/lyne_hollick.py +14 -0
  28. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/slide.py +5 -1
  29. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/strict.py +5 -1
  30. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/methods/ukih.py +4 -0
  31. hydrotoolbox-2.2.0/src/hydrotoolbox/baseflow/methods/willems.py +22 -0
  32. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/param_estimate.py +7 -2
  33. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/separation.py +19 -24
  34. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow_sep.py +120 -53
  35. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/hydrotoolbox.py +1259 -1188
  36. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/indices/indices.py +1 -1
  37. hydrotoolbox-2.2.0/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers/__init__.py +0 -0
  38. hydrotoolbox-2.2.0/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers/plotgen.py +43 -0
  39. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers/wdm.py +9 -7
  40. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/tsutils.py +165 -185
  41. hydrotoolbox-2.2.0/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/utils.py +170 -0
  42. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_asbestfreq.py +12 -4
  43. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_period_timestamp.py +46 -27
  44. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_read.py +4 -3
  45. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_wdm.py +21 -3
  46. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0/src/hydrotoolbox.egg-info}/PKG-INFO +10 -10
  47. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox.egg-info/SOURCES.txt +7 -4
  48. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox.egg-info/requires.txt +1 -3
  49. hydrotoolbox-2.2.0/tests/data_baseflow_chapman.csv +7496 -0
  50. hydrotoolbox-2.2.0/tests/data_baseflow_chapman_maxwell.csv +7496 -0
  51. hydrotoolbox-2.2.0/tests/data_baseflow_eckhardt.csv +7496 -0
  52. hydrotoolbox-2.2.0/tests/data_baseflow_ewma.csv +7496 -0
  53. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_furey.csv +10 -10
  54. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_ihacres.csv +5 -5
  55. hydrotoolbox-2.2.0/tests/data_baseflow_lyne_hollick.csv +7496 -0
  56. hydrotoolbox-2.2.0/tests/data_baseflow_ukih.csv +7496 -0
  57. hydrotoolbox-2.2.0/tests/data_baseflow_usgs_hysep_local.csv +7496 -0
  58. hydrotoolbox-2.2.0/tests/data_baseflow_willems.csv +7496 -0
  59. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/run_test.sh +7 -7
  60. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_baseflow_sep.py +7 -8
  61. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_exceedance_time.py +7 -2
  62. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_flow_duration.py +0 -2
  63. hydrotoolbox-2.0.14/VERSION +0 -1
  64. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/boughton.py +0 -26
  65. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/chapman.py +0 -19
  66. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/cm.py +0 -24
  67. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/eckhardt.py +0 -27
  68. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/furey.py +0 -32
  69. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/lh.py +0 -27
  70. hydrotoolbox-2.0.14/src/hydrotoolbox/baseflow/methods/willems.py +0 -27
  71. hydrotoolbox-2.0.14/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers/plotgen.py +0 -55
  72. hydrotoolbox-2.0.14/tests/data_baseflow_chapman.csv +0 -7496
  73. hydrotoolbox-2.0.14/tests/data_baseflow_cm.csv +0 -7497
  74. hydrotoolbox-2.0.14/tests/data_baseflow_eckhardt.csv +0 -7496
  75. hydrotoolbox-2.0.14/tests/data_baseflow_ewma.csv +0 -7496
  76. hydrotoolbox-2.0.14/tests/data_baseflow_lh.csv +0 -7496
  77. hydrotoolbox-2.0.14/tests/data_baseflow_ukih.csv +0 -7496
  78. hydrotoolbox-2.0.14/tests/data_baseflow_usgs_hysep_local.csv +0 -7496
  79. hydrotoolbox-2.0.14/tests/data_baseflow_willems.csv +0 -7496
  80. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.deepsource.toml +0 -0
  81. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.github/dependabot.yml +0 -0
  82. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.github/workflows/clean-workflow-runs.yml +0 -0
  83. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.gitignore +0 -0
  84. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.gitmodules +0 -0
  85. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/.sourcery.yaml +0 -0
  86. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/AUTHORS.rst +0 -0
  87. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/BADGES.rst +0 -0
  88. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/CONTRIBUTING.rst +0 -0
  89. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/LICENSE.txt +0 -0
  90. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/Makefile +0 -0
  91. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/authors.rst +0 -0
  92. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/conf.py +0 -0
  93. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/contributing.rst +0 -0
  94. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/license.rst +0 -0
  95. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/make.bat +0 -0
  96. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/docs/readme.rst +0 -0
  97. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/pytest.ini +0 -0
  98. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/setup.cfg +0 -0
  99. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/example.csv +0 -0
  100. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/baseflow/utils.py +0 -0
  101. {hydrotoolbox-2.0.14/src/hydrotoolbox/toolbox_utils/src/toolbox_utils → hydrotoolbox-2.2.0/src/hydrotoolbox/indices}/__init__.py +0 -0
  102. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/docs/conf.py +0 -0
  103. {hydrotoolbox-2.0.14/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers → hydrotoolbox-2.2.0/src/hydrotoolbox/toolbox_utils/src/toolbox_utils}/__init__.py +0 -0
  104. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/src/toolbox_utils/readers/hbn.py +0 -0
  105. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_date_slice.py +0 -0
  106. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_dateparse.py +0 -0
  107. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_extract.py +0 -0
  108. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_hbn.py +0 -0
  109. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_make_list.py +0 -0
  110. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_plotgen.py +0 -0
  111. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/toolbox_utils/tests/test_range_to_numlist.py +0 -0
  112. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox/utils.py +0 -0
  113. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox.egg-info/dependency_links.txt +0 -0
  114. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox.egg-info/entry_points.txt +0 -0
  115. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/src/hydrotoolbox.egg-info/top_level.txt +0 -0
  116. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/BEC_test.sh +0 -0
  117. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/Q_BEC_BE_6500.csv +0 -0
  118. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/Q_BEC_BE_6500.ssf +0 -0
  119. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/black_earth_creek_05406500_flow.csv +0 -0
  120. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/black_earth_creek_05406500_test.sh +0 -0
  121. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data.csv +0 -0
  122. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_02239501.csv +0 -0
  123. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_boughton.csv +0 -0
  124. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_five_day.csv +0 -0
  125. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_strict.csv +0 -0
  126. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_usgs_hysep_fixed.csv +0 -0
  127. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_baseflow_usgs_hysep_slide.csv +0 -0
  128. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_percentile_test.csv +0 -0
  129. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_short.csv +0 -0
  130. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/data_test_storm_events.csv +0 -0
  131. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/gtable.out +0 -0
  132. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/gtable_1955.out +0 -0
  133. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/hydrotoolbox_indices.txt +0 -0
  134. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_indices.py +0 -0
  135. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_recession.py +0 -0
  136. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/test_storm_events.py +0 -0
  137. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/tsproc_hydrologic_indices.inp +0 -0
  138. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/tsproc_hydrologic_indices.rec +0 -0
  139. {hydrotoolbox-2.0.14 → hydrotoolbox-2.2.0}/tests/tsproc_hydrologic_indices_percentile_test.inp +0 -0
@@ -28,7 +28,7 @@ jobs:
28
28
 
29
29
  steps:
30
30
  - name: Checkout source
31
- uses: actions/checkout@v4
31
+ uses: actions/checkout@v6
32
32
  with:
33
33
  submodules: recursive
34
34
 
@@ -38,7 +38,7 @@ jobs:
38
38
  python -m build
39
39
 
40
40
  - name: Download artifact
41
- uses: actions/download-artifact@v4
41
+ uses: actions/download-artifact@v8
42
42
  with:
43
43
  path: dist
44
44
  merge-multiple: true
@@ -21,46 +21,34 @@ jobs:
21
21
  fail-fast: false
22
22
  matrix:
23
23
  os: [ubuntu-latest, macos-latest, windows-latest]
24
- python-versions: ['3.9', '3.10', '3.11', '3.12', '3.13']
25
- pandas-versions: [1.5.3, 2.0.0, 2.2.0, 2.2.3]
26
- toolchain:
27
- - {compiler: gcc, version: 13}
24
+ python-versions: ['3.10', '3.11', '3.12', '3.13', '3.14']
25
+ pandas-versions: [pandas<2.0.0, pandas>=2.0.0]
26
+ numpy-versions: [numpy<2.0.0, numpy>=2.0.0]
27
+
28
28
  exclude:
29
+ - python-versions: '3.12'
30
+ pandas-versions: pandas<2.0.0
29
31
  - python-versions: '3.13'
30
- pandas-versions: 1.5.3
31
- - python-versions: '3.13'
32
- pandas-versions: 2.0.0
32
+ pandas-versions: pandas<2.0.0
33
+ - python-versions: '3.14'
34
+ pandas-versions: pandas<2.0.0
35
+ - python-versions: '3.12'
36
+ numpy-versions: numpy<2.0.0
33
37
  - python-versions: '3.13'
34
- pandas-versions: 2.2.0
35
- - python-versions: '3.8'
36
- pandas-versions: 2.2.0
37
- - python-versions: '3.8'
38
- pandas-versions: 2.2.3
39
- - os: windows-latest
40
- python-versions: '3.8'
41
- - os: windows-latest
42
- python-versions: '3.9'
43
- pandas-versions: 2.2.0
44
- - os: windows-latest
45
- python-versions: '3.10'
46
- pandas-versions: 2.2.0
47
- - os: windows-latest
48
- python-versions: '3.11'
49
- pandas-versions: 2.2.0
50
- - os: windows-latest
51
- python-versions: '3.12'
52
- pandas-versions: 2.2.0
53
- - os: windows-latest
54
- python-versions: '3.13'
38
+ numpy-versions: numpy<2.0.0
39
+ - python-versions: '3.14'
40
+ numpy-versions: numpy<2.0.0
41
+ - pandas-versions: pandas<2.0.0
42
+ numpy-versions: numpy>=2.0.0
55
43
 
56
44
  steps:
57
45
  - name: Checkout repository
58
- uses: actions/checkout@v4
46
+ uses: actions/checkout@v6
59
47
  with:
60
48
  submodules: recursive
61
49
 
62
50
  - name: Set up Python ${{ matrix.python-versions }}
63
- uses: actions/setup-python@v5
51
+ uses: actions/setup-python@v6
64
52
  with:
65
53
  python-version: ${{ matrix.python-versions }}
66
54
 
@@ -74,10 +62,12 @@ jobs:
74
62
  version ${{ matrix.pandas-versions }}
75
63
  run: >
76
64
  python -m pip install
77
- pandas==${{ matrix.pandas-versions }} 'numpy<2' .
65
+ '${{ matrix.pandas-versions }}'
66
+ '${{ matrix.numpy-versions }}' .
78
67
 
79
68
  - name: Test with pytest
80
- run: python -m pytest --cov
69
+ run: |
70
+ python -m pytest --cov
81
71
 
82
72
  - name: Upload coverage data to coveralls.io
83
73
  uses: coverallsapp/github-action@v2
@@ -11,7 +11,7 @@ exclude: |
11
11
 
12
12
  repos:
13
13
  - repo: https://github.com/pre-commit/pre-commit-hooks
14
- rev: v5.0.0
14
+ rev: v6.0.0
15
15
  hooks:
16
16
  - id: check-case-conflict
17
17
  - id: check-docstring-first
@@ -23,15 +23,13 @@ repos:
23
23
  - id: check-xml
24
24
  - id: end-of-file-fixer
25
25
  exclude: notebooks/tstoolbox_plot_bash.sh
26
- - id: fix-encoding-pragma
27
- args: [--remove]
28
26
  - id: mixed-line-ending
29
27
  - id: trailing-whitespace
30
28
  exclude: notebooks/tstoolbox_plot_bash.sh
31
29
 
32
30
  - repo: https://github.com/astral-sh/ruff-pre-commit
33
31
  # Ruff version.
34
- rev: v0.12.0
32
+ rev: v0.15.6
35
33
  hooks:
36
34
  # Run the linter.
37
35
  - id: ruff
@@ -42,7 +40,7 @@ repos:
42
40
  types_or: [python, pyi, jupyter]
43
41
 
44
42
  - repo: https://github.com/pycqa/isort
45
- rev: 6.0.1
43
+ rev: 8.0.1
46
44
  hooks:
47
45
  - id: isort
48
46
  name: isort (python)
@@ -54,13 +52,13 @@ repos:
54
52
  types: [pyi]
55
53
 
56
54
  - repo: https://github.com/pappasam/toml-sort
57
- rev: v0.24.2
55
+ rev: v0.24.3
58
56
  hooks:
59
57
  - id: toml-sort-fix
60
58
  args: [--in-place, --spaces-indent-inline-array, '4']
61
59
 
62
60
  - repo: https://github.com/adrienverge/yamllint.git
63
- rev: v1.37.1
61
+ rev: v1.38.0
64
62
  hooks:
65
63
  - id: yamllint
66
64
  args: [--format, parsable, --strict]
@@ -77,23 +75,23 @@ repos:
77
75
  args: [-s, bash]
78
76
 
79
77
  - repo: https://github.com/lovesegfault/beautysh
80
- rev: v6.2.1
78
+ rev: v6.4.3
81
79
  hooks:
82
80
  - id: beautysh
83
81
  args: [--indent-size, '4']
84
82
 
85
83
  - repo: https://github.com/asottile/blacken-docs
86
- rev: 1.19.1
84
+ rev: 1.20.0
87
85
  hooks:
88
86
  - id: blacken-docs
89
87
 
90
88
  - repo: https://github.com/asottile/pyupgrade
91
- rev: v3.20.0
89
+ rev: v3.21.2
92
90
  hooks:
93
91
  - id: pyupgrade
94
92
 
95
93
  - repo: https://github.com/commitizen-tools/commitizen
96
- rev: v4.8.3
94
+ rev: v4.13.9
97
95
  hooks:
98
96
  - id: commitizen
99
97
  stages: [commit-msg]
@@ -1,3 +1,15 @@
1
+ ## v2.2.0 (2026-03-29)
2
+
3
+ ### Feat
4
+
5
+ - moved to using scipy lfilter for most baseflow_sep filters, better separation between API and CLI
6
+
7
+ ## v2.1.0 (2026-03-19)
8
+
9
+ ### Feat
10
+
11
+ - complete revamp of baseflow_sep using scipy.lfilter for most
12
+
1
13
  ## v2.0.14 (2025-06-29)
2
14
 
3
15
  ### Fix
@@ -1,36 +1,36 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: hydrotoolbox
3
- Version: 2.0.14
3
+ Version: 2.2.0
4
4
  Summary: Command line script and Python library for analysis of flow time-series.
5
5
  Author-email: Tim Cera <tim@cerazone.net>
6
6
  License: BSD-3-Clause
7
+ Project-URL: bitbucket, https://bitbucket.org/timcera/hydrotoolbox/src/main/
7
8
  Project-URL: documentation, https://timcera.bitbucket.io/hydrotoolbox/docs/index.html#hydrotoolbox-documentation
8
9
  Project-URL: github, https://github.com/timcera/hydrotoolbox
9
- Project-URL: bitbucket, https://bitbucket.org/timcera/hydrotoolbox/src/main/
10
- Keywords: time-series,cli-app,hydrology,baseflow,hydrograph-recession,hydrographic
10
+ Keywords: baseflow,cli-app,hydrograph-recession,hydrographic,hydrology,time-series
11
11
  Classifier: Development Status :: 5 - Production/Stable
12
- Classifier: Intended Audience :: Science/Research
13
- Classifier: Intended Audience :: End Users/Desktop
14
- Classifier: Intended Audience :: Developers
15
12
  Classifier: Environment :: Console
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Intended Audience :: End Users/Desktop
15
+ Classifier: Intended Audience :: Science/Research
16
16
  Classifier: License :: OSI Approved :: BSD License
17
17
  Classifier: Natural Language :: English
18
18
  Classifier: Operating System :: OS Independent
19
19
  Classifier: Programming Language :: Python :: 3 :: Only
20
- Classifier: Programming Language :: Python :: 3.9
21
20
  Classifier: Programming Language :: Python :: 3.10
22
21
  Classifier: Programming Language :: Python :: 3.11
23
22
  Classifier: Programming Language :: Python :: 3.12
24
23
  Classifier: Programming Language :: Python :: 3.13
24
+ Classifier: Programming Language :: Python :: 3.14
25
25
  Classifier: Topic :: Scientific/Engineering :: Information Analysis
26
26
  Classifier: Topic :: Scientific/Engineering
27
27
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
28
- Requires-Python: >=3.9
28
+ Requires-Python: >=3.10
29
29
  Description-Content-Type: text/x-rst
30
30
  License-File: LICENSE.txt
31
31
  Requires-Dist: cltoolbox>=1.0.0
32
32
  Requires-Dist: dateparser
33
- Requires-Dist: numpy<2.0; python_version == "3.9"
33
+ Requires-Dist: numpy
34
34
  Requires-Dist: pandas[excel]
35
35
  Requires-Dist: pint!=0.21.*
36
36
  Requires-Dist: pint-pandas
@@ -72,7 +72,7 @@ or numpy (http://numpy.scipy.org) for any heavy lifting.
72
72
 
73
73
  Requirements
74
74
  ------------
75
- * python 3.7 or higher
75
+ * python 3.10 or higher
76
76
 
77
77
  Installation
78
78
  ------------
@@ -31,7 +31,7 @@ or numpy (http://numpy.scipy.org) for any heavy lifting.
31
31
 
32
32
  Requirements
33
33
  ------------
34
- * python 3.7 or higher
34
+ * python 3.10 or higher
35
35
 
36
36
  Installation
37
37
  ------------
@@ -0,0 +1 @@
1
+ 2.2.0
@@ -27,9 +27,9 @@ baseflow_sep chapman
27
27
  .. program-output:: hydrotoolbox baseflow_sep chapman --help
28
28
  :prompt:
29
29
 
30
- baseflow_sep cm
31
- ---------------
32
- .. program-output:: hydrotoolbox baseflow_sep cm --help
30
+ baseflow_sep chapman_maxwell
31
+ ----------------------------
32
+ .. program-output:: hydrotoolbox baseflow_sep chapman_maxwell --help
33
33
  :prompt:
34
34
 
35
35
  baseflow_sep eckhardt
@@ -57,14 +57,9 @@ baseflow_sep ihacres
57
57
  .. program-output:: hydrotoolbox baseflow_sep ihacres --help
58
58
  :prompt:
59
59
 
60
- baseflow_sep lh
61
- ---------------
62
- .. program-output:: hydrotoolbox baseflow_sep lh --help
63
- :prompt:
64
-
65
- baseflow_sep strict
66
- -------------------
67
- .. program-output:: hydrotoolbox baseflow_sep strict --help
60
+ baseflow_sep lyne_hollick
61
+ -------------------------
62
+ .. program-output:: hydrotoolbox baseflow_sep lyne_hollick --help
68
63
  :prompt:
69
64
 
70
65
  baseflow_sep ukih
@@ -9,14 +9,13 @@ Python API Function Summary
9
9
  hydrotoolbox.about
10
10
  hydrotoolbox.baseflow_sep.boughton
11
11
  hydrotoolbox.baseflow_sep.chapman
12
- hydrotoolbox.baseflow_sep.cm
12
+ hydrotoolbox.baseflow_sep.chapman_maxwell
13
13
  hydrotoolbox.baseflow_sep.eckhardt
14
14
  hydrotoolbox.baseflow_sep.ewma
15
15
  hydrotoolbox.baseflow_sep.five_day
16
16
  hydrotoolbox.baseflow_sep.furey
17
17
  hydrotoolbox.baseflow_sep.ihacres
18
- hydrotoolbox.baseflow_sep.lh
19
- hydrotoolbox.baseflow_sep.strict
18
+ hydrotoolbox.baseflow_sep.lyne_hollick
20
19
  hydrotoolbox.baseflow_sep.ukih
21
20
  hydrotoolbox.baseflow_sep.usgs_hysep_fixed
22
21
  hydrotoolbox.baseflow_sep.usgs_hysep_local
@@ -5,10 +5,10 @@
5
5
  hydrotoolbox
6
6
  ============
7
7
 
8
- This is the home page for hydrotoolbox. hydrotoolbox is a command line program and
9
- Python library for hydrologic analysis.
8
+ This is the home page for hydrotoolbox. hydrotoolbox is a command line program
9
+ and Python library for hydrologic analysis.
10
10
 
11
- hydrotoolbox should work with Python 3.6+.
11
+ hydrotoolbox should work with Python 3.10+.
12
12
 
13
13
  Table of Contents
14
14
  -----------------
@@ -1,73 +1,71 @@
1
1
  [build-system]
2
2
  build-backend = "setuptools.build_meta"
3
3
  requires = [
4
- "setuptools>=45",
5
- "setuptools_scm[toml]>=6.2",
6
- "wheel"
4
+ "setuptools-scm[simple]>=8",
5
+ "setuptools>=80"
7
6
  ]
8
7
 
9
8
  [project]
10
- name = "hydrotoolbox"
11
- dynamic = ["version"]
12
- readme = "README.rst"
13
- description = "Command line script and Python library for analysis of flow time-series."
14
- dependencies = [
15
- "cltoolbox >= 1.0.0",
16
- "dateparser",
17
- "numpy <2.0; python_version == '3.9'",
18
- "pandas[excel]",
19
- "pint!=0.21.*",
20
- "pint-pandas",
21
- "pydantic",
22
- "scipy",
23
- "tabulate"
24
- ]
25
9
  authors = [
26
- {name = "Tim Cera", email = "tim@cerazone.net"}
10
+ {email = "tim@cerazone.net", name = "Tim Cera"}
27
11
  ]
28
12
  classifiers = [
29
13
  "Development Status :: 5 - Production/Stable",
30
- "Intended Audience :: Science/Research",
31
- "Intended Audience :: End Users/Desktop",
32
- "Intended Audience :: Developers",
33
14
  "Environment :: Console",
15
+ "Intended Audience :: Developers",
16
+ "Intended Audience :: End Users/Desktop",
17
+ "Intended Audience :: Science/Research",
34
18
  "License :: OSI Approved :: BSD License",
35
19
  "Natural Language :: English",
36
20
  "Operating System :: OS Independent",
37
21
  "Programming Language :: Python :: 3 :: Only",
38
- "Programming Language :: Python :: 3.9",
39
22
  "Programming Language :: Python :: 3.10",
40
23
  "Programming Language :: Python :: 3.11",
41
24
  "Programming Language :: Python :: 3.12",
42
25
  "Programming Language :: Python :: 3.13",
26
+ "Programming Language :: Python :: 3.14",
43
27
  "Topic :: Scientific/Engineering :: Information Analysis",
44
28
  "Topic :: Scientific/Engineering",
45
29
  "Topic :: Software Development :: Libraries :: Python Modules"
30
+ ] # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers
31
+ dependencies = [
32
+ "cltoolbox >= 1.0.0",
33
+ "dateparser",
34
+ "numpy",
35
+ "pandas[excel]",
36
+ "pint!=0.21.*",
37
+ "pint-pandas",
38
+ "pydantic",
39
+ "scipy",
40
+ "tabulate"
46
41
  ]
42
+ description = "Command line script and Python library for analysis of flow time-series."
43
+ dynamic = ["readme", "version"]
47
44
  keywords = [
48
- "time-series",
49
- "cli-app",
50
- "hydrology",
51
45
  "baseflow",
46
+ "cli-app",
52
47
  "hydrograph-recession",
53
- "hydrographic"
48
+ "hydrographic",
49
+ "hydrology",
50
+ "time-series"
54
51
  ]
55
52
  license = {text = "BSD-3-Clause"}
56
- requires-python = ">=3.9"
53
+ name = "hydrotoolbox"
54
+ requires-python = ">=3.10"
57
55
 
58
56
  [project.scripts]
59
57
  hydrotoolbox = "hydrotoolbox.hydrotoolbox:main"
60
58
 
61
59
  [project.urls]
60
+ bitbucket = "https://bitbucket.org/timcera/hydrotoolbox/src/main/"
62
61
  documentation = "https://timcera.bitbucket.io/hydrotoolbox/docs/index.html#hydrotoolbox-documentation"
63
62
  github = "https://github.com/timcera/hydrotoolbox"
64
- bitbucket = "https://bitbucket.org/timcera/hydrotoolbox/src/main/"
65
63
 
66
64
  [tool.commitizen]
67
65
  name = "cz_conventional_commits"
68
66
  tag_format = "v$version"
69
67
  update_changelog_on_bump = true
70
- version = "2.0.14"
68
+ version = "2.2.0"
71
69
  version_files = ["VERSION"]
72
70
 
73
71
  [tool.isort]
@@ -77,8 +75,8 @@ profile = "black"
77
75
  testpaths = ["tests"]
78
76
 
79
77
  [tool.setuptools]
80
- license-files = ["LICENSE.txt"]
81
78
  include-package-data = true
79
+ license-files = ["LICENSE.txt"]
82
80
 
83
81
  [tool.setuptools.dynamic]
84
82
  readme = {file = "README.rst"}
@@ -86,5 +84,3 @@ version = {file = "VERSION"}
86
84
 
87
85
  [tool.setuptools.packages.find]
88
86
  where = ["src"]
89
-
90
- [tool.setuptools_scm]
@@ -1,21 +1,22 @@
1
1
  """Define hydrotoolbox package."""
2
2
 
3
+ # Import main functions from hydrotoolbox module
4
+ from hydrotoolbox.hydrotoolbox import (
5
+ about,
6
+ exceedance_time,
7
+ flow_duration,
8
+ indices,
9
+ recession,
10
+ storm_events,
11
+ )
12
+
13
+ # Define __all__ list
3
14
  __all__ = [
15
+ # Main functions
4
16
  "about",
5
- "baseflow_sep",
6
17
  "exceedance_time",
7
18
  "flow_duration",
8
19
  "indices",
9
20
  "recession",
10
21
  "storm_events",
11
22
  ]
12
-
13
- from .hydrotoolbox import (
14
- about,
15
- baseflow_sep,
16
- exceedance_time,
17
- flow_duration,
18
- indices,
19
- recession,
20
- storm_events,
21
- )
@@ -3,14 +3,14 @@ import os
3
3
  __all__ = [
4
4
  "boughton",
5
5
  "chapman",
6
- "cm",
6
+ "chapman_maxwell",
7
7
  "eckhardt",
8
8
  "ewma",
9
9
  "five_day",
10
10
  "fixed",
11
11
  "furey",
12
12
  "ihacres",
13
- "lh",
13
+ "lyne_hollick",
14
14
  "local",
15
15
  "slide",
16
16
  "strict",
@@ -29,15 +29,15 @@ from .comparison import KGE, strict_baseflow
29
29
  from .methods import (
30
30
  boughton,
31
31
  chapman,
32
- cm,
32
+ chapman_maxwell,
33
33
  eckhardt,
34
34
  ewma,
35
35
  five_day,
36
36
  fixed,
37
37
  furey,
38
38
  ihacres,
39
- lh,
40
39
  local,
40
+ lyne_hollick,
41
41
  slide,
42
42
  strict,
43
43
  ukih,
@@ -1,3 +1,8 @@
1
+ __all__ = [
2
+ "KGE",
3
+ "strict_baseflow",
4
+ ]
5
+
1
6
  import numpy as np
2
7
 
3
8
 
@@ -1,14 +1,14 @@
1
1
  __all__ = [
2
2
  "boughton",
3
3
  "chapman",
4
- "cm",
4
+ "chapman_maxwell",
5
5
  "eckhardt",
6
6
  "ewma",
7
7
  "five_day",
8
8
  "fixed",
9
9
  "furey",
10
10
  "ihacres",
11
- "lh",
11
+ "lyne_hollick",
12
12
  "local",
13
13
  "slide",
14
14
  "strict",
@@ -22,15 +22,15 @@ __all__ = [
22
22
 
23
23
  from .boughton import boughton, f_Boughton
24
24
  from .chapman import chapman
25
- from .cm import cm
25
+ from .chapman_maxwell import chapman_maxwell
26
26
  from .eckhardt import eckhardt, f_Eckhardt
27
27
  from .ewma import ewma
28
28
  from .five_day import five_day
29
29
  from .fixed import fixed
30
30
  from .furey import f_Furey, furey
31
31
  from .ihacres import ihacres
32
- from .lh import lh
33
32
  from .local import local
33
+ from .lyne_hollick import lyne_hollick
34
34
  from .slide import slide
35
35
  from .strict import strict
36
36
  from .ukih import ukih
@@ -0,0 +1,21 @@
1
+ __all__ = [
2
+ "boughton",
3
+ ]
4
+
5
+ from hydrotoolbox.baseflow.methods.general_form import general_form_digital_filter
6
+
7
+
8
+ def boughton(flow, k, C):
9
+ """Boughton double-parameter filter (Boughton, 2004)"""
10
+ alpha = k / (1 + C)
11
+ beta = C / (1 + C)
12
+ gamma = 0.0
13
+
14
+ return general_form_digital_filter(flow, alpha, beta, gamma)
15
+
16
+
17
+ def f_Boughton(k):
18
+ def _Boughton(Q, C):
19
+ return boughton(Q, k, C)
20
+
21
+ return _Boughton
@@ -0,0 +1,14 @@
1
+ __all__ = [
2
+ "chapman",
3
+ ]
4
+
5
+ from hydrotoolbox.baseflow.methods.general_form import general_form_digital_filter
6
+
7
+
8
+ def chapman(flow, k):
9
+ """Chapman filter (Chapman, 1991)"""
10
+ alpha = (3 * k - 1) / (3 - k)
11
+ beta = (1 - k) / (3 - k)
12
+ gamma = 1.0
13
+
14
+ return general_form_digital_filter(flow, alpha, beta, gamma)
@@ -0,0 +1,14 @@
1
+ __all__ = [
2
+ "chapman_maxwell",
3
+ ]
4
+
5
+ from hydrotoolbox.baseflow.methods.general_form import general_form_digital_filter
6
+
7
+
8
+ def chapman_maxwell(flow, k):
9
+ """CM filter (Chapman & Maxwell, 1996)"""
10
+ alpha = k / (2 - k)
11
+ beta = (1 - k) / (2 - k)
12
+ gamma = 0
13
+
14
+ return general_form_digital_filter(flow, alpha, beta, gamma)
@@ -0,0 +1,22 @@
1
+ __all__ = [
2
+ "eckhardt",
3
+ ]
4
+
5
+ from hydrotoolbox.baseflow.methods.general_form import general_form_digital_filter
6
+
7
+
8
+ def eckhardt(flow, k, BFImax):
9
+ """Eckhardt filter (Eckhardt, 2005)"""
10
+ denom = 1 - k * BFImax
11
+ alpha = ((1 - BFImax) * k) / denom
12
+ beta = ((1 - k) * BFImax) / denom
13
+ gamma = 0
14
+
15
+ return general_form_digital_filter(flow, alpha, beta, gamma)
16
+
17
+
18
+ def f_Eckhardt(a):
19
+ def _Eckhardt(Q, b_LH, BFImax):
20
+ return eckhardt(Q, b_LH, a, BFImax)
21
+
22
+ return _Eckhardt
@@ -1,3 +1,7 @@
1
+ __all__ = [
2
+ "ewma",
3
+ ]
4
+
1
5
  import numpy as np
2
6
 
3
7
 
@@ -7,6 +7,10 @@ hydrotoolbox baseflow_sep eckhardt,sliding < daily.csv
7
7
 
8
8
  hydrotoolbox recession"""
9
9
 
10
+ __all__ = [
11
+ "five_day",
12
+ ]
13
+
10
14
  import pandas as pd
11
15
 
12
16
 
@@ -1,6 +1,10 @@
1
+ __all__ = [
2
+ "fixed",
3
+ ]
4
+
1
5
  import numpy as np
2
6
 
3
- from .local import hysep_interval
7
+ from hydrotoolbox.baseflow.methods.local import hysep_interval
4
8
 
5
9
 
6
10
  def fixed(Q, area=None, num_days=None):