Skip to content

Detectron2 coco evaluatorΒ #3437

@Nurungyi

Description

@Nurungyi

πŸ“š Documentation Issue

This issue category is for problems about existing documentation, not for asking how-to questions.

  • Provide a link to an existing documentation/comment/tutorial:
    In tutorial, to execute cocoevaluator, trainer.model, val_loader, evaluator are parameters of inference_on_dataset.
    (below is a tutorial code)

    from detectron2.evaluation import COCOEvaluator, inference_on_dataset
    from detectron2.data import build_detection_test_loader
    evaluator = COCOEvaluator("balloon_val")
    val_loader = build_detection_test_loader(cfg, "balloon_val")
    print(inference_on_dataset(trainer.model, val_loader, evaluator))

Although I think that both (trainer.model, predictor.model) are same in an evaluation, instead of trainer.model, predictor.model is better. While trainer.model can be done after trainer should be finished, predictor.model can be executed with pre trained weight without execution of trainer.

Is it correct??

Thank you!!

  • How should the above documentation/comment/tutorial improve:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions