Skip to content

Commit 70a16ea

Browse files
committed
Merge branch 'master' into attach-data-refactor
2 parents ae9d7e0 + ea2287e commit 70a16ea

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

pytorch_lightning/plugins/training_type/training_type_plugin.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,10 +127,12 @@ def lightning_module(self) -> 'pl.LightningModule':
127127
@property
128128
def results(self) -> Optional[Union[_EVALUATE_OUTPUT, _PREDICT_OUTPUT]]:
129129
"""
130-
The results of the last training/testing run will be cached here.
131-
In distributed training, we make sure to transfer the results to the appropriate master process.
130+
Enables plugin-agnostic access to the result returned by the training/evaluation/prediction run. The result is
131+
cached instead of returned directly, because some plugins require transmitting the results from one
132+
multiprocessing context to another in a separate step. For example, the plugins that use the "spawn"
133+
start-method send the result to the master process through a
134+
`multiprocessing queue (shared memory) <https://pytorch.org/docs/stable/multiprocessing.html>`_.
132135
"""
133-
# TODO(@awaelchli): improve these docs
134136
return self._results
135137

136138
@property

0 commit comments

Comments
 (0)