大家好,我目前正在进行情绪分析。
`从变压器进口管道
sent_pipeline=pipeline('情感分析')`
这是我的代码,它给我的错误是:
Failed to import transformers.models.gpt2.modeling_gpt2 because of the following error (look up to see its traceback): add_code_sample_docstrings() got an unexpected keyword argument 'real_checkpoint'
我试过安装/升级变压器,但还是不行
确保您使用的是与软件兼容的 python 版本!