Scene Painting


by Keian Tarboush and Salman Bader
Supervised by Gur Harary


Abstract

This paper presents a technique for colorizing grayscale images. The general problem of colorizing a grayscale image has no exact solution; consequently, colorization requires considerable user intervention. As a result, current approaches attempt to provide a method to help minimize the human labor required for this task. There are two main approaches for image colorization, the first one is based on annotating the grayscale image with a few color scribbles and then automatically propagate the colors in both space and time to produce a fully colorized image or sequence by solving an optimization problem. The other approach is based on transferring color from a source image to the grayscale image by matching luminance and texture information between the images. In this paper we present a method that combines the two approaches. First, the target grayscale image is matched to a source, color image, and then an optimization problem is obtained and solved using standard techniques, both stages are based on the two main approaches.


Tools

This project was implemented in a Matlab environment, based on two main articles : Levin et al. and Welsh et al.

 

General Scheme

         Figure 1 - General scheme of the algorithm.

 

Algorithm

Stage 1 - Segmentation of color source image

     Figure 2 - Segmentation of color image.

 

Stage 2 - Segmentation of color grayscale target

        Figure 3 - Segmentation of grayscale image.

 

Stage 3 - Matching and color transfer

Each pixel in target segment is matched to pixels in source segments. Each target pixel points at best matching segment.
Characteristics matched : DCT, Histogram and Luminance values of neighboring pixels.

                                                                  Figure 4 - Matching of segments between source and target images.

 

 After the matching of segments colors are transferred. Best matching segment in source image is used to colorize target segment.

                                                                                                         Figure 5 - Color transfer.

 

Stage 4 - Optimization

Chosen colors are sampled and added to grayscale target.

                                                                                                        Figure 6 - Color sample.

Colors are propagated to all pixels using optimization algorithm.

                                                                                                        Figure 6 - Result after optimization.

 

Results

                                                            Source                    Grayscale                   Result                  Original Image

 

DOWNLOADS