We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f4969c8 commit 3beb700Copy full SHA for 3beb700
torch/csrc/api/include/torch/nn/parallel/data_parallel.h
@@ -275,7 +275,7 @@ Tensor data_parallel(
275
return module->forward(std::move(input)).to(*output_device);
276
}
277
278
- autograd::Scatter scatter(*devices, /*chunk_sizes=*/nullopt, dim);
+ autograd::Scatter scatter(*devices, /*chunk_sizes=*/std::nullopt, dim);
279
auto scattered_inputs = fmap<Tensor>(scatter.apply({std::move(input)}));
280
// Input tensor might not be big enough to scale across all available devices
281
if (scattered_inputs.size() < devices->size()) {
0 commit comments