[Bug]: paddlenlp 的 Taskflow 在使用 `Taskflow("text_classification", mode='finetune')` 下载文件时,路径组合错误导致无法正确下载,

wwtsj6pe  于 2个月前  发布在  其他
关注(0)|答案(1)|浏览(20)

软件环境

- paddlepaddle:2.6.1
- paddlenlp: 2.6.1
  Windows平台。

重复问题

  • 我已搜索现有的问题

错误描述

paddlenlp 的 Taskflow使用 Taskflow("text_classification", mode='finetune')下载文件时路径组合有错:
[2024-08-08 21:39:36,130] [    INFO] - Downloading tokenizer_config.json from https://bj.bcebos.com/paddlenlp/models/community/C:\Users\username\.paddlenlp\taskflow\text_classification\finetune/tokenizer_config.json

稳定复现步骤 & 代码

from paddlenlp import Taskflow
cls = Taskflow("text_classification", mode='finetune')
yqhsw0fo

yqhsw0fo1#

如果使用finetune后的模型来预测,需要设置
task_path='./checkpoint/model_best/plm'

相关问题