mindspore-lab / mindnlp

Easy-to-use and high-performance NLP and LLM framework based on MindSpore, compatible with models and datasets of 🤗Huggingface.
https://mindnlp.cqu.ai/
Apache License 2.0
665 stars 172 forks source link

Error occured when multi-output model calls Trainer #108

Closed TTYee closed 1 year ago

TTYee commented 1 year ago

BiDAF Model will generate two outputs. Error occured when Trainer was called. Parts of the code: image Error information: viDZi7nhQy

TTYee commented 1 year ago

When the network model returns more than one value, loss function needed to be reconstructed before put into Trainer.