fj1024

Results comments of fj1024

> 请问有解决办法吗?[@fj1024](https://github.com/fj1024) [@Jintao-Huang](https://github.com/Jintao-Huang) 我debug到是陷入了死锁的状态,一个只能rank0进入的代码块又去调用了分布式 DDP 或多进程场景下方法safe_ddp_context,一直处于等待的状态。ms-swift/swift/megatron/init.py这部分代码 with torch.device('meta'): self.hf_model = get_model_processor( args.model_dir, model_type=args.model_type, return_dummy_model=True)[0] 修改成from swift.utils.torch_utils import disable_safe_ddp_context_use_barrier with disable_safe_ddp_context_use_barrier(): with torch.device('meta'): self.hf_model = get_model_processor( args.model_dir, model_type=args.model_type, return_dummy_model=True)[0]