This is my 2nd project for Term 3 semantic segmentation using a Fully Convolutional Network (FCN).
The encoder is VGG16 pretrained model. Decoder is fully convolutional network FCN8. Data is from KITTI road dataset.
A pre-trained VGG-16 was followed by, instead of full connected layers, a 1x1 convolution with depth equal to number of classes (road/nonroad). Skip connections was used to improve performance. In this case, as the paper suggests, 1x1 convolution of layer 4 and 2x2 upsampled layers (output of layer 7). Same applied to 1x1 convolution of layer 3 and 2x2 conv2d transpose upsample of output of previous layer. Each convolution and transpose convolution layer include a kernel initializer and regularizer.
Vertical image flipping was used as agumentation to improve the training dataset.
keep_prob: 0.5 learning_rate: 0.00 epochs: 100 batch_size: 5
Training loss was reduced from initial 1.5 to 0.3 after 50 epochs, further reduced to 0.08 at 100 epochs.
Make sure you have the following is installed:
Download the Kitti Road dataset from here. Extract the dataset in the data
folder. This will create the folder data_road
with all the training a test images.
Implement the code in the main.py
module indicated by the "TODO" comments.
The comments indicated with "OPTIONAL" tag are not required to complete.
Run the following command to run the project:
python main.py
Note If running this in Jupyter Notebook system messages, such as those regarding test status, may appear in the terminal rather than the notebook.
- Ensure you've passed all the unit tests.
- Ensure you pass all points on the rubric.
- Submit the following in a zip file.
helper.py
main.py
project_tests.py
- Newest inference images from
runs
folder (all images from the most recent run)
A well written README file can enhance your project and portfolio. Develop your abilities to create professional README files by completing this free course.