[Bug]: information_extraction输出空
软件环境
- paddlepaddle:
- paddlepaddle-gpu:
- paddlenlp:
重复问题
- [X] I have searched the existing issues
错误描述
information_extraction输出空
稳定复现步骤 & 代码
Python 3.7.4 (default, Aug 13 2019, 20:35:49) [GCC 7.3.0] :: Anaconda, Inc. on linux Type "help", "copyright", "credits" or "license" for more information.
from paddlenlp import Taskflow from pprint import pprint schema = ['时间', '选手', '赛事名称'] ie = Taskflow('information_extraction', schema=schema) [2023-09-14 11:20:42,175] [ INFO] - We are using <class 'paddlenlp.transformers.ernie.tokenizer.ErnieTokenizer'> to load '/home/bml/.paddlenlp/taskflow/information_extraction/uie-base'. pprint(ie("2月8日上午北京冬奥会自由式滑雪女子大跳台决赛中中国选手谷爱凌以188.25分获得金牌!")) /home/bml/storage/.local/lib/python3.7/site-packages/paddlenlp/transformers/tokenizer_utils_base.py:2481: FutureWarning: The max_seq_len argument is deprecated and will be removed in a future version, please use max_length instead. FutureWarning, /home/bml/storage/.local/lib/python3.7/site-packages/paddlenlp/transformers/tokenizer_utils_base.py:1884: FutureWarning: The pad_to_max_length argument is deprecated and will be removed in a future version, use padding=True or padding='longest' to pad to the longest sequence in the batch, or use padding='max_length' to pad to a max length. In this case, you can give a specific length with max_length (e.g. max_length=45) or leave max_length to None to pad to the maximal input size of the model (e.g. 512 for Bert). FutureWarning, [{}]
这个问题当前仅在CPU环境下发现,在GPU环境下可以正常输出,可以将paddle换成2.5.0rc1解决。后续paddle版本更新后,会解决这个问题。
@DrownFish19 请问在centos的CPU环境下,paddlepaddle和paddlenlp怎样的版本组合能解决这个问题?
@TianruiZhang 我现在测试了paddle develop和paddlenlp 2.6.1是可以正常输出的。或者使用paddle 2.5.0rc1 + paddlenlp 2.6.1也可以正常输出,后续paddle2.5.2版本推出后应该能解决这个问题。
实测paddle 2.5.0rc1 + paddlenlp 2.5.2也可以正常输出。
现在离2.5.1发布都3个月了,还不见2.5.2或者2.6.0的踪影……
另外,神奇的是,用evaluate.py 脚本,在2.5.1下的CPU环境,竟然是正确推理的。
2.5.2出来了,一样不行,还得给它把版本降回去,无语
@DrownFish19 paddle2.5.2出来后问题依然存在,有点影响paddlenlp与其他模块的应用
请问window10安装哪个版本的paddlepaddle? 安装了paddlepaddle==2.5.0rc1 + paddlenlp==2.6.1不行啊
paddlepadle2.4.1 ,paddlenlp 2.4.0 window10+CPU版的paddlepaddle可以
This issue is stale because it has been open for 60 days with no activity. 当前issue 60天内无活动,被标记为stale。