Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError: Default process group has not been initialized, please make sure to call init_process_group. #142

Open
cqray1990 opened this issue Jun 2, 2024 · 1 comment

Comments

@cqray1990
Copy link

cqray1990 commented Jun 2, 2024

if args.local_rank == -1:
    device = torch.device("cuda")
else:
    torch.cuda.set_device(args.local_rank)
    device = torch.device("cuda", args.local_rank)
    deepspeed.init_distributed()
args.global_rank = torch.distributed.get_rank()

 此处代码是不是有问题?单独跑train.py 报错的,不用命令跑,不能单独调试代码,只能用distribute模式
@ZzYAmbition
Copy link

我用命令跑也是这个问题,请问解决了吗。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants