Skip to content

我使用自采数据集进行微调训练后的模型输出的结果为nan #121

@helloheidi

Description

@helloheidi
  您好,我的机器人为双臂结构一共12个自由度。使用3个相机视角。我在使用仓库提供的训练脚本训练完模型后使用evaluate/openloop_eval.py进行评估,但是输出的action全是nan。具体表现为action: (tensor(0., device='cuda:0', dtype=torch.bfloat16), tensor([[[nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan],[nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan],......。我怀疑是在微调过程中模型权重的更新出现了nan。
  同时我在搭建环境时注意到需要flash-attn==2.4.2,并且要求torch==2.6.0。但是2.4.2版本支持的torch版本只到torch==2.2,https://github.com/Dao-AILab/flash-attention/releases/tag/v2.4.2。这里是否冲突。
  最终我安装了更高版本的flash-attn,训练任务也没有报错。但我不确定是否是flash-attn版本不一致导致的训练模型结果异常。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions