Skip to content

Commit d3bf5f9

Browse files
committed
flattened the hierarchy, because we really don't need subfolders for each module when each isn't so big
1 parent 0107452 commit d3bf5f9

19 files changed

Lines changed: 20 additions & 51 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ PyNumDiff is a Python package that implements various methods for computing nume
3434
6. generalized Kalman smoothing
3535
7. local approximation with linear model
3636

37-
For a full list, see `pynumdiff/__init__.py`, or explore modules in the [Sphinx documentation](https://pynumdiff.readthedocs.io/master/).
37+
For a full list, explore modules in the [Sphinx documentation](https://pynumdiff.readthedocs.io/master/).
3838

3939
Most of these methods have multiple parameters, so we take a principled approach and propose a multi-objective optimization framework for choosing parameters that minimize a loss function to balance the faithfulness and smoothness of the derivative estimate. For more details, refer to [this paper](https://doi.org/10.1109/ACCESS.2020.3034077).
4040

@@ -75,7 +75,7 @@ params, val = optimize(somethingdiff, x, dt, tvgamma=tvgamma, # smoothness hyper
7575
print('Optimal parameters: ', params)
7676
x_hat, dxdt_hat = somethingdiff(x, dt, **params)
7777
```
78-
If no `search_space_updates` is given, a default search space is used. See the top of `_optimize.py`.
78+
If no `search_space_updates` is given, a default search space is used. See the top of `optimize.py`.
7979

8080
The following heuristic works well for choosing `tvgamma`, where `cutoff_frequency` is the highest frequency content of the signal in your data, and `dt` is the timestep: `tvgamma=np.exp(-1.6*np.log(cutoff_frequency)-0.71*np.log(dt)-5.1)`. Larger values of `tvgamma` produce smoother derivatives. The value of `tvgamma` is largely universal across methods, making it easy to compare method results. Be aware the optimization is a fairly heavy process.
8181

docs/source/total_variation_regularization.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,4 @@ total_variation_regularization
99
.. autofunction:: pynumdiff.total_variation_regularization.acceleration
1010
.. autofunction:: pynumdiff.total_variation_regularization.jerk
1111
.. autofunction:: pynumdiff.total_variation_regularization.iterative_velocity
12-
.. autofunction:: pynumdiff.total_variation_regularization.smooth_acceleration
13-
.. autofunction:: pynumdiff.total_variation_regularization.jerk_sliding
12+
.. autofunction:: pynumdiff.total_variation_regularization.smooth_acceleration
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
"""Methods based on fitting basis functions to data"""
12
import numpy as np
23
from warnings import warn
34
from scipy import sparse

pynumdiff/basis_fit/__init__.py

Lines changed: 0 additions & 5 deletions
This file was deleted.

pynumdiff/finite_difference/_finite_difference.py renamed to pynumdiff/finite_difference.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
"""This is handy for this module https://web.media.mit.edu/~crtaylor/calculator.html"""
1+
"""This module implements some common finite difference schemes.
2+
This is handy for this module https://web.media.mit.edu/~crtaylor/calculator.html"""
23
import numpy as np
34
from pynumdiff.utils import utility
45
from warnings import warn

pynumdiff/finite_difference/__init__.py

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
"""This module implements constant-derivative model-based smoothers based on Kalman filtering and its generalization."""
12
import numpy as np
23
from warnings import warn
34
from scipy.linalg import expm, sqrtm

pynumdiff/kalman_smooth/__init__.py

Lines changed: 0 additions & 3 deletions
This file was deleted.

pynumdiff/linear_model/__init__.py

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)