1. Học hỏi
  2. /
  3. Khoa Học
  4. /
  5. Deep Learning for Images with PyTorch

Connected

Bài tập

Bounding boxes prediction

You have trained an object recognition model. Now, you want to use to generate bounding boxes and classifications for a test image.

The model is available as model and it's already in the evaluation mode. The test_image is also available, and torch and torch.nn as nn have been imported.

Hướng dẫn

100 XP
  • Get the model's output for the test_image and assign it to output.
  • Extract the predicted bounding boxes from the output and assign them to boxes.
  • Extract the predicted scores from the output and assign them to scores.