Shortcuts

DumpResults

class mmengine.evaluator.DumpResults(out_file_path, collect_device='cpu')[source]

Dump model predictions to a pickle file for offline evaluation.

Parameters
  • out_file_path (str) – Path of the dumped file. Must end with ‘.pkl’ or ‘.pickle’.

  • collect_device (str) – Device name used for collecting results from different ranks during distributed training. Must be ‘cpu’ or ‘gpu’. Defaults to ‘cpu’.

Return type

None

compute_metrics(results)[source]

dump the prediction results to a pickle file.

Parameters

results (list) –

Return type

dict

process(data_batch, predictions)[source]

transfer tensors in predictions to CPU.

Parameters
  • data_batch (Any) –

  • predictions (Sequence[dict]) –

Return type

None

Read the Docs v: v0.4.0
Versions
latest
stable
v0.5.0
v0.4.0
v0.3.0
v0.2.0
Downloads
On Read the Docs
Project Home
Builds

Free document hosting provided by Read the Docs.