Deep Pose implemented in PyTorch with VGG16 and weighted loss using kernel density estimation.
To improve segmentation performance, a novel neural network architecture (termed DFCN-DCRF) is proposed, which combines an RGB-D fully convolutional neural network (DFCN) with a depth-sensitive fully-connected conditional random field (DCRF). First, a DFCN architecture which fuses depth information into the early layers and applies dilated convolution for later contextual reasoning is designed. Then, a depth-sensitive fully-connected conditional random field (DCRF) is proposed and combined with the previous DFCN to refine the preliminary result. Comparative experiments show that the proposed DFCN-DCRF has the best performance compared with most state-of-the-art methods.READ FULL TEXT VIEW PDF
Fully-connected Conditional Random Field (CRF) is often used as
We propose a dual pathway, 11-layers deep, three-dimensional Convolution...
In this work, we address the face parsing task with a Fully-Convolutiona...
With the advancement of remote-sensed imaging large volumes of very high...
Robust segmentation of hair from portrait images remains challenging: ha...
The Conditional Random Field as a Recurrent Neural Network layer is a
We introduce DeepNAT, a 3D Deep convolutional neural network for the
Deep Pose implemented in PyTorch with VGG16 and weighted loss using kernel density estimation.
In order to realize scene understanding, semantic segmentation plays a very important role and has attracted more and more researchers’ interests[1, 2, 3, 4, 5]. Among existing methods, convolutional neural networks (CNNs) have shown great advantages on semantic segmentation with RGB images. One typical CNN, called fully convolutional neural network (FCN), achieves remarkable performance over the past few years. As reported in Ref. [5, 6, 7], encoder-decoder type FCNs dramatically improved the dense prediction accuracy by fusing different layer representations. In order to expand the receptive field without losing resolution and generate a better performance on multiple segmentation tasks, a dilated convolution operator was applied to replace the encoder-decoder architecture [8, 9]. Despite many efforts had been taken on the improvement, the result was still unsatisfactory, especially, on the boundary of the objects. To remedy this problem, researchers started to combine RGB model based fully-connected conditional random fields (CRFs) with CNN and gained improvements on several semantic segmentation benchmarks [8, 9, 10, 11, 12, 13]. However, it is difficult to apply these methods in the indoor scene where objects share similar colors.
Recently, some RGB-D image datasets [14, 15, 16, 17] have been released in public. Since the depth information includes 3D positions and structures of the objects, utilizing depth channel as complementary information to RGB channel may increase the potential to implement accurate semantic segmentation. This hypothesis is verified by Couprie et al. who interacted the depth information into a multiscale convolutional network . Inspired by this work, a novel neural network (DFCN) architecture with a depth-sensitive fully-connected conditional random field (DCRF) is proposed in this paper. Different from the existing FCNs, we incorporate the depth information into a FCN with dilated operator and a CRF to improve the accuracy greatly.
Before ending this section, the main contributions of this work are listed as follow:
A novel neural network architecture (termed DFCN-DCRF) is proposed, which combines an RGB-D fully convolutional neural network (DFCN) with a depth-sensitive fully-connected conditional random field (DCRF).
The design process and theoretical analysis of the proposed DFCN-DCRF is presented in detail.
Two comparison experiments on SUN RGB-D benchmark verify the effectiveness of the proposed DFCN-DCRF on semantic segmentation.
In this section, the literature of deep CNN for semantic segmentation, fully-connected conditional random fields, and incorporation of depth information are previewed in detail.
In 2015, Long et al. proposed a fully convolutional neural network model , which had a structure of encoder-decoder architecture. In this work, a skip architecture was designed, which combined semantic information from the deep coarse layer with appearance information from a shallow fine layer. The skip architecture is able to take advantage of all feature spectra and showed an accurate segmentation result. As a further discussion, Noh et al.  proposed a novel FCN structure which eliminates the limitation of fixed-size receptive field. On the decoding step, it applied unpooling and convolution transpose to allow the network to learn the upsample weights. With the similar network structure of these two models, Badrinarayanan et al.  presented another architecture called SegNet, which comprised unpooling as well as the skip architecture. Besides, dropout 20] can also further improve the segmentation accuracy during test time [7, 21].
Meanwhile, another approach for contextual reasoning called dilated convolution was proposed. It aims to expands the receptive field on the input image exponentially without losing resolution of the result. As shown in Fig. 1, dilation on convolution expands the receptive field on the input image exponentially without losing resolution of the result. Based on this architecture, Chen et al. proposed DeepLab system which conducts contextual reasoning on images while keeping the spatial information . Yu et al. further applied dilated convolution on a novel FCN architecture with no pooling layer . In our work, we design the core network with both pooling and dilated convolution. The fundamental structure of the proposed DFCN-DCRF is similar to the DeepLab-LargeFOV architecture .
Recently, some semantic segmentation algorithms based on CNN combine the FCN with conditional random fields (CRFs). CRFs is able to model the contextual relationships between different pixel so as to maximize the label agreement of them. Koltun et al presented an efficient inference algorithm for Gaussian Edge Potentials . The inference method allows a fully-connected CRF with pairwise connection over all pairs of pixels to inference in a reasonable time. It has been proved that the poor accuracy of boundary in the output of FCN can be addressed by combining the responses in the last layer of CNN with a fully-connected CRF model [9, 8, 10]
. In particular, Zheng et al. proposed a novel architecture, in which the mean field approximation was modeled as a recurrent neural network and integrated as a part of deep neural network.
Fully-connected CRFs with RGB information works well on refining CNN output, based on the fact that different objects have different colors or brightness. However, indoor scene objects (e.g., bed, couch, pillow) often share similar color or brightness. Therefore, it is reasonable to incorporate the depth information into fully-connected CRF as a post-processing method to provide additional information such as distance or clear distinctive boundaries. The idea of incorporating depth information into conditional random fields was first proposed by Muller et al. . They applied a super-pixel-based model for semantic segmentation. Inspired by Ref. , we incorporate the depth information into a fully-connected CRF after CNN architecture to generate a more accurate segmentation.
Based on some labeled RGB-D image datasets [14, 15, 16, 17], many studies have tried to incorporate the depth information to generate a better performance. Long et al.  shows that simply stack the depth with RGB as a 4-channels input cannot improve the performance in a significant way. Gupta et al.  presented a different representation of depth information referred as HHA. It comprised horizontal disparity, height from the ground and the angle between the local surface normal and gravity direction, and got a good results [5, 23]. However, Hazirbas et al. . argued that the HHA representation did not contain more information than the raw depth itself, and it required a high computation cost. In their work, a fusion-based CNN architecture was presented. The network consisted of two branches of encoding networks, i.e., a depth branch and an RGB branch. The feature representation in these two branches was then fused into the master branch. There are two ways of fusing approaches, i.e., sparse fusion and dense fusion. It was proved that the sparse one is better. Therefore, in our work, we fuse RGB and depth channel feature representation in a sparse way from Conv1 to Conv4.
In this section, the design process and theoretical analysis of the proposed DFCN-DCRF is stated in detail.
We propose a RGB-D FCN architecture (DFCN) to generate the response for the unary potential for each class on each pixel. As shown in Fig. 2
, the DFCN part has two major blocks: 1) Convolution layers with three downsample pooling for features extraction and depth fusion; 2) Dilated convolution layer for contextual reasoning and dense prediction.
In the first block, we employ the 16-layer VGG net from first layer Conv1_1 to Conv4_3 as a fundamental framework. This fundamental framework is applied on both the RGB channel and depth channel (i.e., master branch and depth branch) for features extraction. In this stage, we take layers before every pooling in two branches of the network and fuse them together with element-wise summation. The fusion layers are then added before every pooling layer in the master branch. To prevent further resolution decrease of the feature maps, we replace Pool4 in VGG-16 with a one-strike max-pooling and Pool5 with a one-strike max-pooling and a one-strike average-pooling. To make the values in two branches compatible and easier to train, we normalize the depth channel, which originally ranges from 0 to 65535, into the same range as color images, i.e., from 0 to 255.
In the second block, the dilated convolution is applied after Pool4 with dilation rate of 2 for three layers in Conv5 and dilation rate of 12 for Conv6_1. All dilated convnets in the proposed DFCN-DCRF architecture are followed by batch normalization layers to avoid covariate shift . Conv6_1 and Conv6_2 are also followed by dropout layers when training to avoid overfitting 
. The final score map is upsampled with a factor of 8 by using bilinear interpolation to recover the original resolution. This score map is also converted into a preliminary pixel-wise label prediction, that is, the result of DCRF.
We present a depth-sensitive fully-connected CRF (DCRF) to refine the upsampled output from DFCN. Every pixel is treated as a CRF node, and the energy function of the DCRF is composed of a unary and a pairwise factors (also called first and second order factors). Considering an image I has a size of , the energy function with
denoting label vector is defined as
where with , superscript denoting the transpose of a matrix or a vector. Element is the label assigned of the th pixel. The unary potential is computed from the last layer of DFCN, where is the result of applying softmax on the score map at pixel . is a pairwise potential function with Gaussian kernel over all pair of pixels in image I, which can be represented as
where is the label compatibility function. In our model, . In Potts model , it means that we have penalty for the assignment of different labels. and are feature vectors of pixels in the th and th positions. is smoothness kernel, i.e.,
where and denote the position vectors of the th and th pixels. Parameter controls the degrees of nearness of two pixels. The smoothness kernel is used to eliminate small isolated regions. is appearance kernel. In this paper, we present two kinds of appearance kernels, i.e.,
where is defined the same as before, is the color vector of the th pixel and is the depth vector of the th pixel. , , and control the degrees of nearness and similarity between two pixels. With this definition, pixels with close position, similar color and similar depth are forced as the same label. The position, color and depth features are combined into one Gaussian kernel in Equation (4) but two Gaussian kernels in Equation (5), where controls the balance between two kernels. Equation (4) indicates that big differences in either RGB channel or depth channel can cause the different assignments of labels, and thus the penalty will be small. On the contrary, Equation (5) only gives a small penalty for pixels whose RGB information and depth information are alike. In practice, we find that Equation (4) provides better performance than Equation (5) in the context of indoor semantic segmentation.
In order to balance the importance of the depth and RGB information, the depth input to the fully-connected CRF must be scaled into a compatible range referred to RGB channel. The most accessible way to do so is to directly scale the depth channel into the range of RGB channel. However, the depth channel contains invalid values, which is always presented as an extreme value, i.e., 0 or 65535. These invalid values might prevent the scaled depth values from falling into an appropriate range. Therefore, rather than rigidly scale the depth into 0 to 255, we scale and shift every depth image to have the same mean value and standard deviation with its RGB counterpart. This allows the depth image and RGB image have compatible value range in CRF model.
In this section, the proposed DFCN-DCRF is tested on a SUN RGB-D scene understanding benchmark suite . This dataset was captured by four different kinds of sensors with different resolutions and fields of view. It also contains the data from NYU Depth v2 , Berkeley B3DO  and SUN3D  with totally 10,335 RGB-D images and their pixel-wise semantic annotations. Moreover, it has a default trainval-test split which comprises 5285 images for training/validation and 5050 images for testing. To improve the quality of depth channel, multiple frames are collected to obtain a refined depth map. However, we find that if the invalid area in the raw depth map is too large, the corresponding refined depth image still contains invalid measurement or losing information on corresponding pixels. Thus 387 training images are excluded, as they have more than of invalid values in the raw depth map. According to Ref. , since different classes of objects have different instance-wise and pixel-wise present frequency, we also use weighted losses for different classes.
Training For the CNN stage, bilinear interpolation on RGB channel and nearest-neighbor interpolation on depth channel are applied to get
-size image inputs of two branches. The loss function is the sum of softmax loss on each pixel in the output map. The parameters before Pool4 are initialized with the values from the 16-layer VGG model
pre-trained on ImageNet dataset. Since Conv1_1 layer in depth branch only has one channel, we average the parameter values of VGG Conv1_1 along 3 channels to get a single channel for its initialization. During training, the data is augmented by applying random hue, brightness, contrast and saturation adjustment on the original image, and we randomly scale and crop the image as well as the label to generate more data.
The proposed DFCN-DCRF architecture is implemented on the TensorFlow framework
, and stochastic gradient descent (SGD) is applied for end-to-end training. We set the initial learning rate of layers before Pool5 in the master branch as 0.0002, the final score layer as 0.005, and all other layers as 0.001. All those learning rates are decayed by a factor of 0.9 in every 50,000 iterations. A momentum of 0.9 and weight decay of 0.0005 are also applied. The network is continually trained on a Nvidia Titan X Pascal GPU with a batch size of 5 until the loss does not further decrease.
For the fully-connected CRF stage, we first obtain the DFCN response on the score layer after it is fine-tuned on training. in Equation (2) is set as 3 and in Equation (4) is set as 3. Then a random search algorithm is employed to determine the best values for , , and . More concretely, we randomly search the best values of in a range from 5 to 11, in a range from 90 to 170, and in a range from 7 to 12 , which iteratively refines the search step around the last round’s best values.
Testing The network is performed on 5050 images testing set with three criteria, i.e., the pixel accuracy, the mean accuracy and the intersection-over-union (IoU) score. denotes the number of pixels those are predicted as category but actually belongs to category . denotes the number of pixels with correct prediction of category . denotes the total number of pixels that belongs to category in the ground truth. denotes the total number of categories in the dataset.
Pixel accuracy measures the percentage of correctly classified pixels:
Mean accuracy measures the classwise pixel accuracy:
Intersection-over-union calculates the average value of the intersection between the ground truth and the prediction regions:
Among these metrics, Pixel accuracy measurement is more sensitive to the large objects such as bed, wall, and floor in the dataset, so Pixel accuracy measurement will be misleading when the network performs better on the large objects. Therefore, Mean accuracy measurement and IoU score measurement are more informative.
Two comparison experiments are conducted in this section. In the first experiment, the proposed DFCN and DFCN-DCRF are compared with the start-of-the-art methods. The results are shown in Table 1. For comparisons, we also illustrate the results of pure DFCN. The segmentation results show that both the DFCN and DFCN-DCRF outperform other existing methods, except for Context-CRF . However, it is worth pointing out that Context-CRF requires CNNs with multi-scale image input and pyramid pooling to generate CRF potentials for primary results and another dense CRF to do refinement, which is relatively difficult to train and inference compared with our method. It is also worth noting that our CNN method, which has no CRF post-processing stage, already outperforms FuseNet, which shares the same fusing strategy on a encoder-decoder based FCN architecture.
In the second experiment, we test the proposed DFCN-DCRF with different depth incorporation cases, and the results are shown in Table 2. The CRF with and without depth are denoted as DCRF and CRF. It can be seen from Row 2 and Row 3 of Table 2 that if the RGB based CRF is integrated into RGB based DFCN, the performance will become a bit better but not much. That is to say, the RGB based CRF after RGB based DFCN can only cause a little improvement in Pixel accuracy measurement and IoU score measurement, and even obtain a setback in Mean accuracy measurement. The possible reason is that objects in the indoor environment often have similar colors. Therefore an RGB based CRF cannot distinguish the differences between the objects with similar colors. In addition, we add the depth information into only DCRF part of the model as shown in Row 4 of Table 2, the performance is further improved a bit. The result of adding depth information into DFCN is shown in Row 5 of Table 2, which shows that the performance increase a lot compared with the previous three cases. It implies that the depth information has a great effect if it is added into the DFCN. Furthermore, we combine the DFCN with the RGB based CRF, we find that the performance improves a bit but still not much as shown in Row 6 of Table 2. Compared with Row 2 and 3, as well as 5 and 6, whether integrating the RGB-based CRF into DFCN has little influence on the performance. As can be seen, the proposed DFCN-DCRF has the best performance among all cases. The same conclusion can be obtained from Fig. 3. Moreover, we also compared our method with one state-of-the-art method, i.e., FuseNet-SF5 in classwise mIoU score. The results are shown in Table 3. It shows that both the proposed DFCN-DCRF and DFCN are better than FuseNet-SF5 Ref. .
In this paper, a novel neural network architecture (termed DFCN-DCRF) has been designed and proposed, which combines an RGB-D fully convolutional neural network (DFCN) with a depth-sensitive fully-connected conditional random fields (DCRF). Different from most of methods only adding depth-information into FCN, we have added the depth information into both the DFCN and DCRF. In addition, the design process and theoretical analysis of the proposed DFCN-DCRF have been presented in detail. Two comparison experiments on SUN RGB-D benchmark have verified the effectiveness and advantages of the proposed DFCN-DCRF on semantic segmentation.
Journal of Machine Learning Research, vol. 15, no. 1, pp. 1929–1958, 2014.