Linjie Chen

Results 92 comments of Linjie Chen
trafficstars

学生模型的评估代码可以参考这里:https://github.com/PaddlePaddle/PaddleNLP/blob/develop/model_zoo/uie/data_distill/evaluate.py 示例: ```shell python evaluate.py \ --task_type relation_extraction \ --test_path ./student_data/dev_data.json \ --label_maps_path ./student_data/label_maps.json \ --model_path ../checkpoint/model_best \ --encoder ernie-3.0-base-zh ```

> > 学生模型的评估代码可以参考这里:https://github.com/PaddlePaddle/PaddleNLP/blob/develop/model_zoo/uie/data_distill/evaluate.py > > 示例: > > ```shell > > python evaluate.py \ > > --task_type relation_extraction \ > > --test_path ./student_data/dev_data.json \ > > --label_maps_path ./student_data/label_maps.json \ >...

你好,可以参考下Taskflow DocPrompt任务里predictor的构造方法 - 获取静态图参数 https://github.com/PaddlePaddle/PaddleNLP/blob/c8bc4405fc6ed7026887c7c97d6ce1afa32e300f/paddlenlp/taskflow/document_intelligence.py#L78-L80 - predictor构建 https://github.com/PaddlePaddle/PaddleNLP/blob/c8bc4405fc6ed7026887c7c97d6ce1afa32e300f/paddlenlp/taskflow/task.py#L249-L254

从报错信息来看是输入数据类型和 Filter 数据类型不一致导致,方便提供下复现代码进一步定位下问题么 ![image](https://user-images.githubusercontent.com/40840292/198531897-08e05502-ea3c-475d-b4a1-1e03e2c1dc3c.png)

@wjddd ernie-layout中的模型是通过jit.save的方式保存为静态图模型的,这里定义了模型的输入shape和type https://github.com/PaddlePaddle/PaddleNLP/blob/develop/model_zoo/ernie-layout/export_model.py#L42 可以check下是否是因为DocPrompt的输入不一致导致的

你好,感谢反馈问题 这里因为ResNet组网中固定了参数名,所以在模型重复实例化的时候会有上面这个问题,我们会在下个版本修复这个问题 参考这里: https://github.com/PaddlePaddle/PaddleNLP/blob/develop/paddlenlp/transformers/ernie_layout/visual_backbone.py#L43 当前版本如果有重复实例化模型的需求,可以在执行 ```python model = ErnieLayoutForTokenClassification.from_pretrained('ernie-layoutx-base-uncased', num_classes=2) ``` 之前加上这两行代码 ```python paddle.enable_static() paddle.disable_static() ```

@done520 你好,可以尝试安装与驱动CUDA版本对应的paddle再试下 ```shell python -m pip install paddlepaddle-gpu==2.3.2.post112 -f https://www.paddlepaddle.org.cn/whl/linux/mkl/avx/stable.html ```

检查下环境里面是否已卸载onnxruntime并且安装了onnxruntime-gpu

你好, 1.原始数据转换为doccano数据格式的label字段建议替换成具有具体含义的文本 2.可以尝试将训练集直接作为验证集进行微调,看下微调后的模型是否能输出训练集中的多值情况,看下在训练集上的输出是否问题

这个entity id是对不同实体的唯一标识,目的地这个label,例如『上海』和『北京』分别对应一个唯一的entity_id,所以才会有entity id有时候是一样的,有时候又是不一样的这种情况哈