seisgo.stacking
The stacking module provides a unified interface to multiple waveform stacking
algorithms, from simple linear averaging to advanced phase-weighted and cluster-based methods.
Function Summary
Stacking Methods Reference
All methods are accessible via the unified seisgo.stacking.stack() wrapper.
Method name |
Description |
Key parameter(s) |
|---|---|---|
|
Arithmetic mean along the stack axis. |
|
|
Phase-weighted stack. Applies a phase coherence weight in the time domain. |
|
|
Time-frequency phase-weighted stack using the Stockwell transform. |
|
|
TF-PWS using the discrete orthonormal Stockwell transform (DOST). |
|
|
Iterative robust stack (Pavlis & Vernon 2010). Downweights incoherent traces. |
|
|
Adaptive covariance filter (Nakata et al. 2015). Enhances coherent signal. |
|
|
N-th root stack. Enhances coherence at the cost of amplitude fidelity. |
|
|
Correlation-based selective stack. Only includes traces above a coherence threshold. |
|
|
Cluster-based stack. Groups traces by similarity and returns the dominant cluster. |
|
Usage Examples
Unified wrapper
from seisgo import stacking
import numpy as np
# d: 2-D array, shape (n_traces, n_samples)
linear = stacking.stack(d, method="linear")
pws = stacking.stack(d, method="pws", par={"p": 2})
robust = stacking.stack(d, method="robust", par={"epsilon": 1e-5, "maxstep": 10})
Selective stack with custom reference
ref = np.median(d, axis=0)
sel = stacking.stack(d, method="selective",
par={"cc_min": 0.6, "ref": ref, "win": [100, 400]})
Returning stacking statistics
newstack, weights, n_iter = stacking.robust(d, stat=True)