pytorch-multigpu icon indicating copy to clipboard operation
pytorch-multigpu copied to clipboard

what's the main difference between single gpu and data parallel?

Open HoracceFeng opened this issue 6 years ago • 1 comments

Hi, I just wonder the difference of train script between "single_gpu" and "data_parallel", since they seem like have the same structure and module, also using the same API.

By the way, would you introduce how to use the distributed one? I am a little bit confuse about how to set the url and how to start using this.

Thx.

HoracceFeng avatar Jul 25 '19 14:07 HoracceFeng

os.environ["CUDA_VISIBLE_DEVICES"] = gpu_devices net = nn.DataParallel(net)

I suggest people to take some effort themselves looking at the code before posting questions. Not a frequent pytorch user myself but this should not be difficult.

nanwei1 avatar Sep 30 '19 14:09 nanwei1