A fully convolutional network contains convolutional layers throughout, together with supporting nonlinearity and normalization layers, but no dense linear layers. Using convolution for the output preserves local image structure and produces predictions across an entire image, making the architecture suitable for image segmentation. section 8.1
A practical segmentation pipeline uses the network with image-shaped labels:
- Resize images to 256 × 256, remove alpha channels, move channels to PyTorch’s first dimension, and normalize pixel values. section 8.1.1
- Merge separate nucleus masks with a logical OR, producing one binary mask whose pixels indicate nucleus presence. section 8.1.1
- Train the network to predict the complete mask rather than a single image-level or object-level output. section 8.1 section 8.1.1
Figure 8.2 This is how we process the Data Science Bowl data for image segmentation. Each folder under the root directory has several subfolders: an images folder with one image (I know, confusing) and a masks folder that has a binary mask for each nucleus. The masks are separated for object detection (we’ll get to that later), so we merge them all into one image that indicates where masks are (class 1) and are not (class 0).
Follow the image-and-mask transformation from separate nucleus masks to one binary segmentation target. section 8.1.1
