Utility functions for SRSF Manipulations
moduleauthor:: Derek Tucker <dtucker@stat.fsu.edu>
calculates the srsf of warping functions with corresponding shooting vectors
| Parameters: | gam – numpy ndarray of shape (M,N) of M warping functions with N samples |
|---|---|
| Return type: | 2 numpy ndarray and vector |
| Return mu: | Karcher mean psi function |
| Return gam_mu: | vector of dim N which is the Karcher mean warping function |
| Return psi: | numpy ndarray of shape (M,N) of M SRSF of the warping functions |
| Return vec: | numpy ndarray of shape (M,N) of M shooting vectors |
finds the inverse of the mean of the set of the diffeomorphisms gamma
| Parameters: | gam – numpy ndarray of shape (M,N) of M warping functions with N samples |
|---|---|
| Return type: | vector |
| Return gamI: | inverse of gam |
cummulative trapzodial numerical integration taken from midpoint
| Parameters: |
|
|---|---|
| Return type: | vector |
| Return fa: | cummulative integration |
” calculates the distnaces between function, where f1 is aligned to f2. In other words caluclates the elastic distances
| Parameters: |
|
|---|---|
| Return type: | scalar |
| Return Dy: | amplitude distance |
| Return Dx: | phase distance |
converts f to a square-root slope function (SRSF)
| Parameters: |
|
|---|---|
| Return type: | vector |
| Return q: | srsf of f |
This function takes the gradient of f using b-spline smoothing
| Parameters: |
|
|---|---|
| Return type: | tuple of numpy ndarray |
| Return f0: | smoothed functions functions |
| Return g: | first derivative of each function |
| Return g2: | second derivative of each function |
finds the inverse of the diffeomorphism gamma
| Parameters: | gam – vector describing the warping function |
|---|---|
| Return type: | vector |
| Return gamI: | inverse of gam |
calculates the warping to align srsf q2 to q1
| Parameters: |
|
|---|---|
| Return type: | vector |
| Return gam: | describing the warping function used to align q2 with q1 |
calculates outlier’s using geodesci distnaces of the SRSFs from the median
| Parameters: |
|
|---|---|
| Returns: | q_outlier: outlier functions |
Generates random warping functions
| Parameters: |
|
|---|---|
| Returns: | gam: numpy ndarray of warping functions |
This function smooths a collection of functions using a box filter
| Parameters: |
|
|---|---|
| Return type: | numpy ndarray |
| Return f: | smoothed functions functions |