MCPcopy Create free account
hub / github.com/PeizeSun/SparseR-CNN / train

Method train

detectron2/engine/defaults.py:412–425  ·  view source on GitHub ↗

Run training. Returns: OrderedDict of results, if evaluation is enabled. Otherwise None.

(self)

Source from the content-addressed store, hash-verified

410 ]
411
412 def train(self):
413 """
414 Run training.
415
416 Returns:
417 OrderedDict of results, if evaluation is enabled. Otherwise None.
418 """
419 super().train(self.start_iter, self.max_iter)
420 if len(self.cfg.TEST.EXPECTED_RESULTS) and comm.is_main_process():
421 assert hasattr(
422 self, "_last_eval_results"
423 ), "No evaluation results obtained during training!"
424 verify_results(self.cfg, self._last_eval_results)
425 return self._last_eval_results
426
427 def run_step(self):
428 self._trainer.iter = self.iter

Callers

nothing calls this directly

Calls 1

verify_resultsFunction · 0.90

Tested by

no test coverage detected