运行transformer模型是报错如题,
1.减小batch size, 原因是调用cublas函数时会生成句柄,占用一定的内存,确保剩余内存够使用。
2.gpu驱动版本和cuda、torch版本的匹配问题,低版本的gpu驱动,尝试换成11.0以下的cuda版本;高版本的驱动,可以换成11.0以上的cuda版本;参考链接:
Vertices=torch.matmul(vertices.unsqueeze(0), rotations_init), RuntimeError: CUDA error: CUBLAS_STATUS_EXECUTION_FAILED when calling `cublasSgemmStridedBatched in CentOS - PyTorch Forums



