Transformer
RBFTransformer
A custom transformer to apply Radial Basis Functions (RBFs) to time series data.
Quickstart
python
from sktime.transformations.basisfunction import RBFTransformer
estimator = RBFTransformer(centers=None, gamma=1.0, rbf_type='gaussian', apply_to='index', use_torch=False)Parameters(5)
- centersarray-like, shape (n_centers,), optional (default=None)
- The centers \(c_k\) of the RBFs. These define the points against which the distances from the input data are measured. If None, the centers will be evenly spaced over the range of the input data.
- gammafloat, optional (default=1.0)
- The spread or scaling factor \(\gamma\) that controls the influence range of each RBF center. Larger values of \(\gamma\) make the RBF sharper (smaller spread), while smaller values make the RBF smoother.
- rbf_type{“gaussian”, “multiquadric”, “inverse_multiquadric”},
optional (default=”gaussian”)
The type of radial basis function to apply:
“gaussian”: \(\exp(-\gamma (t - c)^2)\)
“multiquadric”: \(\sqrt{1 + \gamma (t - c)^2}\)
“inverse_multiquadric”: \(\frac{1}{\sqrt{1 + \gamma (t - c)^2}}\)
- apply_to{“index”, “values”}, optional (default=”index”)
Determines whether the RBFs are applied to the time index or to the values of the time series.
“index”: Apply the RBFs to the time index.
“values”: Apply the RBFs to the values of the time series.
- use_torchbool, optional (default=False)
- Whether to use torch for the RBF calculations. If True, the transformer will use PyTorch for the RBF calculations, if present. If not, will fall back to NumPy. If False, it will use NumPy.