from utils import hf_login, data, compute_wer from dataset import Dataset from model import Model hf_login() def run_tests (dataset_choice:str, model:str): MoDeL = Model() MoDeL.select(model) MoDeL.load() DaTaSeT = Dataset(100) DaTaSeT.load(dataset_choice) references, predictions = MoDeL.process(DaTaSeT) wer = compute_wer(references=references, predictions=predictions) return wer print("WER:", run_tests(dataset_choice="GigaSpeech", model="facebook/s2t-medium-librispeech-asr"))