ml4gw.augmentations
Classes
|
Takes a tensor of timeseries of arbitrary dimension and randomly inverts i.e. \(h(t) \rightarrow -h(t)\) each timeseries with probability |
|
Takes a tensor of timeseries of arbitrary dimension and randomly reverses i.e., \(h(t) \rightarrow h(-t)\). |
- class ml4gw.augmentations.SignalInverter(prob=0.5)
Bases:
Module
Takes a tensor of timeseries of arbitrary dimension and randomly inverts i.e. \(h(t) \rightarrow -h(t)\) each timeseries with probability
prob
.- Parameters:
prob (
float
) -- Probability that a timeseries is inverted
- forward(X)
- Return type:
Float[Tensor, '*batch time']
- Parameters:
X (Float[Tensor, '*batch time'])
- class ml4gw.augmentations.SignalReverser(prob=0.5)
Bases:
Module
Takes a tensor of timeseries of arbitrary dimension and randomly reverses i.e., \(h(t) \rightarrow h(-t)\). each timeseries with probability
prob
.- Parameters:
prob (
float
) -- Probability that a kernel is reversed
- forward(X)
- Return type:
Float[Tensor, '*batch time']
- Parameters:
X (Float[Tensor, '*batch time'])