Are you sure you want to delete this task? Once this task is deleted, it cannot be recovered.
Encore 97909f7d8f | 1 week ago | |
---|---|---|
README.md | 1 week ago | |
config.json | 1 week ago | |
configuration_Mind.py | 1 week ago | |
convert_ms_to_hf.py | 1 week ago | |
infer.py | 1 week ago | |
modeling_mind.py | 1 week ago | |
spm.PC_Sailboat.V1.0.136832.model | 1 week ago | |
tokenizer.py | 1 week ago |
此仓库用于将NPU(mindspore)版本的多语言脑海转成GPU(HuggingFace)版本
在同测试集上的bleu值(解码配置为top3)
BLEU | |
---|---|
NPU(mindspore) | 17.34 |
GPU(HuggingFace) | 18.16 |
在同输入下模型的输出logit的逐元素误差
绝对值 | |
---|---|
最大误差 | 0.01699 |
平均误差 | 0.00242 |
1.将NPU(mindspore)下的权重文件下载至本地
2.修改convert_ms_to_hf.py文件中的ckpt_path为上述保存的路径,执行convert_ms_to_hf.py会在当前路径下生成pytorch_model.bin文件
from transformers import AutoModelForCausalLM
model = AutoModelForCausalLM.from_pretrained(
"local_path_to_this_repo",
trust_remote_code=True
)
具体预测代码参考infer.py
Dear OpenI User
Thank you for your continuous support to the Openl Qizhi Community AI Collaboration Platform. In order to protect your usage rights and ensure network security, we updated the Openl Qizhi Community AI Collaboration Platform Usage Agreement in January 2024. The updated agreement specifies that users are prohibited from using intranet penetration tools. After you click "Agree and continue", you can continue to use our services. Thank you for your cooperation and understanding.
For more agreement content, please refer to the《Openl Qizhi Community AI Collaboration Platform Usage Agreement》