Closed brandynlucca closed 5 months ago
A more in-depth review of the EchoPro
MATLAB code has informed the updated implementation of the kriging algorithm incorporated into PR #241. This uses the same algorithm as the original MATLAB code that is vectorized and utilizes the same adaptive search radius and extrapolation penalty.
This can be closed when PR #241 is merged.
In the updated working branch, kriging model parameters are stored within the
Survey
object when the*.xlsx
parameter file is initially loaded.https://github.com/uw-echospace/EchoPro/blob/2157de885498f6b6d951ccee85ed7a6dfb8818ba/EchoPro/survey.py#L174-L184
These values are combined with the configuration settings so they are stored in the same location. The configuration settings are assigned below, for reference.
https://github.com/uw-echospace/EchoPro/blob/2157de885498f6b6d951ccee85ed7a6dfb8818ba/config_files/initialization_config.yml#L46-L55
Once the semivariogram has been fully parameterized (related to #186), it is then incorporated into the kriging interpolation algorithm to compute the kriging/covariance matrix and calculating the theoretical variogram at specific lag distances depending on the number of values within the search radius. The actual kriging occurs within the
ordinary_kriging(...)
function; however, there are some modifications to the interpolation procedure that Chu explained to us during our meeting with him. This specifically concerns the adaptive search window that is built into the algorithm that maintains a set number of neighboring spatial points (defaults:kmin=3
,kmax=10
), and therefore lag distance values, that the theoretical semivariogram is calculated over (note that the model parameterization remains the same; it is only the distance lags it is computed over that changes).https://github.com/uw-echospace/EchoPro/blob/2157de885498f6b6d951ccee85ed7a6dfb8818ba/EchoPro/computation/kriging_methods.py#L117-L189
Other kriging models available in the Matlab Kriging library (i.e. universal kriging with linear drift, objective mapping) are not implemented here, so only this modified ordinary kriging algorithm has been incorporated.
Questions for FEAT
To Do
NumPy
function docstrings to models and related functionsscikit-gstat
) influence values [low priority -- consider for future implementation]