CoolFace
Modelpublic

MIT-SLS/USAD-Small

sourceHugging Facecc-by-nc-sa-4.0updated 4mo agoView on Hugging Face
0likes11downloads
modeling_usad.py20 linesDownload Raw Back to root
1# modeling_usad.py2 3from transformers import PreTrainedModel4from .configuration_usad import USADConfig5from .usad_model import UsadModel as model6 7 8class USADModel(PreTrainedModel):9    config_class = USADConfig10 11    def __init__(self, config: USADConfig):12        super().__init__(config)13        self.model = model(config)14 15    def forward(self, *args, **kwargs):16        return self.model(*args, **kwargs)17 18    def load_audio(self, audio_path):19        return self.model.load_audio(audio_path)20