zhifu gao
2024-02-29 c456abaf33023038be686f18df6a1178367d3894
funasr/models/llm_asr_nar/model.py
@@ -315,7 +315,10 @@
        model_outputs = self.llm(inputs_embeds=inputs_embeds, attention_mask=attention_mask, labels=None)
        preds = torch.argmax(model_outputs.logits, -1)
        text = tokenizer.batch_decode(preds, add_special_tokens=False, skip_special_tokens=True)
        text = text[0].split(': \n')[-1]
        text = text[0].split(': ')[-1]
        text = text.strip()
        # preds = torch.argmax(model_outputs.logits, -1)
        
        ibest_writer = None