2.3K Star 8.1K Fork 4.3K

GVPMindSpore / mindspore

 / 详情

baichuan2-7b/13b[910B1]训练失败,ValueError: Can't find class type models class name Baichuan7BV2ForCausalLM in class registry

TODO
Bug-Report
创建于  
2024-04-23 15:52
name about labels
Bug Report Use this template for reporting a bug kind/bug

Describe the current behavior / 问题描述 (Mandatory / 必填)

模型仓库地址:https://gitee.com/mindspore/mindformers/blob/dev/research/baichuan2/baichuan2.md

Environment / 环境信息 (Mandatory / 必填)

  • Hardware Environment(Ascend/GPU/CPU) / 硬件环境:

Please delete the backend not involved / 请删除不涉及的后端:
/device ascend/GPU/CPU/kirin/等其他芯片

  • Software Environment / 软件环境 (Mandatory / 必填):
    -- MindSpore version (e.g., 2.2.11) :
    -- Python version (e.g., Python 3.9.19) :
    -- OS platform and distribution (e.g., eulerosv2r10.aarch64 ):
    -- GCC/Compiler version (if compiled from source):

  • Excute Mode / 执行模式 (Mandatory / 必填)(PyNative/Graph):

Please delete the mode not involved / 请删除不涉及的模式:
/mode graph

Related testcase / 关联用例 (Mandatory / 必填)

用例:belle_chat_ramdon_10k.json数据集
Baichuan2-7B-Base
Baichuan2-7B-Chat
Baichuan2-13B-Base
Baichuan2-13B-Chat

Steps to reproduce the issue / 重现步骤 (Mandatory / 必填)

  1. get code from mindformers
  2. cd mindformers/reserach
  3. 修改配置文件中的权重、数据集路径
  4. bash run_singlenode.sh
    "python baichuan2/run_baichuan2.py
    --config baichuan2/run_baichuan2_7b_910b.yaml
    --load_checkpoint /data1/tff/mindformers_update/research/baichuan2/model_dir/rank_0/Baichuan2_7B_Chat.ckpt
    --auto_trans_ckpt True
    --use_parallel True
    --run_mode finetune
    --train_data /data1/tff/mindformers_update/research/baichuan2"
    /data1/tff/mindformers_update/rank_table_8.json [0,8] 8
  5. 验证网络是否训练成功
  6. 验证网络编译时间是否达标

Describe the expected behavior / 预期结果 (Mandatory / 必填)

网络训练成功,编译时间达标

Related log / screenshot / 日志 / 截图 (Mandatory / 必填)

运行日志

Special notes for this issue/备注 (Optional / 选填)

评论 (6)

feria-tu 创建了Bug-Report

Please assign maintainer to check this issue.
请为此issue分配处理人。
@fangwenyi @chengxiaoli @Shawny

感谢您的提问,您可以评论//mindspore-assistant更快获取帮助:

  1. 如果您刚刚接触MindSpore,或许您可以在教程找到答案
  2. 如果您是资深Pytorch用户,您或许需要:
  1. 如果您遇到动态图问题,可以设置set_context(pynative_synchronize=True)查看报错栈协助定位
  2. 模型精度调优问题可参考官网调优指南
  3. 如果您反馈的是框架BUG,请确认您在ISSUE中提供了MindSpore版本、使用的后端类型(CPU、GPU、Ascend)、环境、训练的代码官方链接以及可以复现报错的代码的启动方式等必要的定位信息
  4. 如果您已经定位出问题根因,欢迎提交PR参与MindSpore开源社区,我们会尽快review
feria-tu 修改了标题
feria-tu 修改了描述

您好,建议移步mindformers issue获取更多支持:https://gitee.com/mindspore/mindformers/issues

i-robot 添加了
 
gitee
标签
Shawny 负责人设置为renyujin
Shawny 关联项目设置为MindSpore Issue Assistant
Shawny 计划开始日期设置为2024-04-23
Shawny 计划截止日期设置为2024-05-23
Shawny 添加了
 
mindspore-assistant
标签
Shawny 添加了
 
sig/mindformers
标签

您好,我看到同事已经在mindformers提issue,但是现在还没有回复:#I9ITOT:baichuan2-13B,推理已经成功,现在运行lora微调报错,报错为缺少了一个类

同时我在搜解决案例时看到了之前有解决过类似报错,看能否有参考:#I9HO47:[ST][MS][MF][r2.3][qwen_7b/14b][910B3 8P]网络训练失败,ValueError: Can't find class type optimizer class name AdamWeightDecayX in class registry

@feria-tu 看报错截图是使用了run_mindformer.py进行训练,research下模型应该使用run_baichuan2.py

已解决,成功部署好了,感谢

登录 后才可以发表评论

状态
负责人
项目
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
预计工期 (小时)
参与者(4)
8108889 shawny233 1628167362 8681979 feria tu 1613378966
Python
1
https://gitee.com/mindspore/mindspore.git
git@gitee.com:mindspore/mindspore.git
mindspore
mindspore
mindspore

搜索帮助