Training SSD on a custom dataset
In the following code, we will train the SSD algorithm to detect the bounding boxes around objects present in images. We will use the truck versus bus object detection task we have been working on:
Find the following code in the Training_SSD.ipynb
file in the Chapter08
folder on GitHub at https://bit.ly/mcvp-2e. The code contains URLs to download data from and is moderately lengthy. We strongly recommend executing the notebook in GitHub to reproduce the results while following the steps and explanations of various code components from the text.
- Download the image dataset and clone the Git repository hosting the code for the model and the other utilities for processing the data:
import os if not os.path.exists('open-images-bus-trucks'): !pip install -q torch_snippets !wget --quiet https://www.dropbox.com/s/agmzwk95v96ihic/\ open-images-bus-trucks.tar.xz !tar -xf open-images-bus-trucks.tar...