游雁
2024-02-19 94de39dde2e616a01683c518023d0fab72b4e103
funasr/models/specaug/specaug.py
@@ -7,9 +7,11 @@
from funasr.models.specaug.mask_along_axis import MaskAlongAxisVariableMaxWidth
from funasr.models.specaug.mask_along_axis import MaskAlongAxisLFR
from funasr.models.specaug.time_warp import TimeWarp
from funasr.register import tables
import torch.nn as nn
@tables.register("specaug_classes", "SpecAug")
class SpecAug(nn.Module):
    """Implementation of SpecAug.
@@ -99,7 +101,8 @@
            x, x_lengths = self.time_mask(x, x_lengths)
        return x, x_lengths
class SpecAugLFR(AbsSpecAug):
@tables.register("specaug_classes", "SpecAugLFR")
class SpecAugLFR(nn.Module):
    """Implementation of SpecAug.
    lfr_rate:low frame rate
    """