游雁
2024-05-15 67733a2a92f54d9777a0b18ac4f1488b3bc41efc
funasr/models/sense_voice/whisper_lib/decoding.py
@@ -63,8 +63,8 @@
    else:
        x = x.to(mel.device)
    # FIX(funasr): sense vocie
    # logits = model.logits(x[:, :-1], mel)[:, -1]
    logits = model.logits(x[:, :], mel)[:, -1]
    logits = model.logits(x[:, :-1], mel)[:, -1]
    # logits = model.logits(x[:, :], mel)[:, -1]
    # collect detected languages; suppress all non-language tokens
    mask = torch.ones(logits.shape[-1], dtype=torch.bool)