원시데이터 수집 시스템
선정목록으로

Advances in colour transfer

관련 필름·전자재료 · (16) CPI(투명 폴리이미드)

기본 정보

저자
  1. François Pitié — Electronic & Electrical Engineering Department Trinity College Dublin Ireland
DOI
10.1049/iet-cvi.2019.0920
저널
IET Computer Vision
발행년도
2020
발행기관
Institution of Engineering and Technology
피인용수
4
라이선스
cc-by-nc-nd
논문 유형
–
언어
–
원문 페이지
https://doi.org/10.1049/iet-cvi.2019.0920
토픽
Color Science and Applications
OpenAlex ID
W3088635278

평가 내용

관련도
관련
사업분야
필름·전자재료 · (16) CPI(투명 폴리이미드)
부 분야
–
R&D 측면
–
확신도
–
근거 용어
–
판단 근거
임베딩 유사도 기반 평가로 '필름·전자재료 > CPI(투명 폴리이미드)' 분야에 선정된 논문입니다.
R&D 활용 포인트
–
평가 입력
–

초록

Colour grading is an essential step in movie post‐production, which is done in the industry by experienced artists on expensive edit hardware and software suites. This paper presents a review of the advances made to automate this process. The review looks in particular at how the state‐of‐the‐art in optimal transport and deep learning has advanced some of the fundamental problems of colour transfer, and how far are we still from being able to automatically grade images.

본문 48,571자

본문 펼치기
Colour grading is an essential step in movie post-production, which is done in the industry by experienced artists on expensive edit hardware and software suites. This paper presents a review of the advances made to automate this process. The review looks in particular at how the state-of-the-art in optimal transport and deep learning has advanced some of the fundamental problems of colour transfer, and how far are we still from being able to automatically grade images. Introduction Colour grading is the artistic process of changing the colour attributes of an image, through the adjustment of colour controls, such as white balance, exposure, brightness, contrast or gamma. It is an essential step in image editing and it is used at different points in the movie production pipeline. It is first used to colour correct shots to reproduce accurately what was recorded. It is then used to colour balance all the shots and establish continuity throughout the movie. Colour grading can also be used later on towards achieving specific practical effects, such as when filming nighttime scenes in daylight. Lastly, colour grading is used to establish a desired visual artistic style. The task is to change the original colours, to match the director's desired colour scheme, whether it is the monochromatic colour scheme of The Matrix, the variations of pink in Grand Budapest Hotel or the complementary orange/blue colours of most action movies. Introduction Currently, in the industry, colour grading is achieved by experienced artists, called colourists, who use expensive edit hardware and software suites to manually match the colour between the frames. Typical colour grading operations include adjusting the exposure, brightness and contrast, gammas, calibrating the white point or setting a colour mapping curve to non-linearly affect the colour channels. More complex colour grading will require retouching specific areas of the images. Typically the object of interest (actor's face or a car), would be masked out, tracked throughout the shot, and graded separately from the rest of the scene. Grading then becomes a fairly complex operation and it would be therefore beneficial to automate this task in some way. Introduction In the academic community, the problem of automating this process was first approached as an example-based colour transfer application. The idea, coined by Reinhard et al. [1] (2002), is to find a colour mapping that, when applied to an input image, can change the colour palette to match the one of a target image (see Fig. 1). Early works mainly looked at per-channel solutions [1,2], but it is only when the problem was linked to the theory of optimal transport (OT) [Morovic and Sun [3] (2003), Pitié et al. [4] (2005)], that satisfying solutions for colour images were found. Most of the literature that followed is still based on or related to the mathematical framework of OT. Introduction Colour transfer does not, however, stop at just finding a mapping that links two colour distributions. In practice, a number of issues need also to be addressed. In a series of papers on the topic, Pitié et al. [4][5][6][7][8] (2005,2007,2008) identified some of these specific issues. One is that applying non-linear colour mapping can cause artefacts that need to be filtered out in post-processing steps. Another is that any difference of content between the input and target images can cause issues during the colour transfer, and mitigating strategies must be put in place. Introduction In this review, we study the recent advances in colour transfer, OT and deep learning for the application of colour grading images and see how the literature has advanced on these issues. Introduction Organisation of the review: we will first give some context to the application and go through the core colour grading operations used by the artists and see how these impact the colour distributions (Section 2). The colour transfer problem is then introduced in Section 3 and linked to the theory of OT in Section 4. Recent advances will then be discussed in Sections 5 and 6, and assessed in Section 7. Background Colour correction usually refers to the adjustment of white and black levels, exposure, contrast and white balance that are applied to restore the image original and unprocessed colours. The aim of colour correction is to provide a visually consistent baseline on which subsequent colour adjustments can be accurately applied. All footage and scenes are first carefully matched during that step to create visual consistency throughout scenes. Background Part of the need for colour correction used stems from colour management issues. On the same production, footage may come from different cameras, each camera using its own native input colour space (e.g. Red Log Film, BMD Film Log, S-Log 2 etc.). Also, various footages may be sent around to different postproduction teams, which may apply their own colour corrections or might be working in different colour spaces. Still, the final output has to look the same on any display, let it be a TV display or cinema display. Adopting consistent colour management practices has been a big challenge for the industry, and to standardise the colour management workflows for production and post-production, the Academy of Motion Picture Arts and Sciences introduced in 2014 the Academy Colour Encoding System (ACES), which aimed at becoming the industry standard for managing colour across the entire film making process. Typically artists will start from predefined profiles and then work their way to match a precise colour palette. Basic colour grading controls The basic colour grading operations available to colourists are usually presented to the artists through colour wheels interfaces (see Fig. 2), which help the artist set the lift, gain and gamma for each colour channel. Histograms for each colour channels give the artist useful feedback on their grading operation. Assuming floating-point bitdepth, the basic colour grading operation is defined as follows: Basic colour grading controls (1) Basic colour grading controls The offsets b r , b g , and b b are sometimes called lifts and control the overall brightness for each channel. Gamma: The gamma values γ r , γ g , and γ b can be used to convert to display gamma, which is usually 2.2, but they can also be used to control the midtones. Basic colour grading controls Gain: The gain values a r , a g , and a b can be used to control the colour tint, temperature, and exposure. For instance, the exposure can be changed as follows: Basic colour grading controls The white balance/tint can be changed by setting the gains to [a r , a g , a b ] = [1/w r , 1/w g , 1/w b ], where w = [w r , w g , w b ] defines the red, green, and blue (RGB) values of white. Typically the artist would get these values by sampling in the image a pixel that should be white (using for instance a calibration card). The gain, lift, and gamma parameters are interdependent but it may be easier to think that lift primarily affects the shadows, whilst gamma affects the midtones, and gain affects the highlights. Basic colour grading controls Colour matrix: Cross channels interactions can also be defined through a simple affine model: Basic colour grading controls where A is the 3 × 3 matrix of all cross channels linear dependencies. For instance, colour desaturation can be expressed as: Basic colour grading controls where s ∈ [0, 2] controls the amount of colour saturation. Curves: Colourists may need to go beyond these basic controls and manually define one-dimensional (1D) piece-wise polynomial colour mappings by directly specifying spline control points (see Fig. 2 bottom). Colour lookup table (LUT): The combined effect of all successive grading operations can be baked into a single LUT. The LUT can be 1D if the colour manipulations are done independently on each channel. The LUT needs to be 3D if the cross-channels' operations are involved. LUT are commonly distributed to achieve colour space conversion or to apply a specific grading profile. bottom). Secondary and localised grading: Following a global colour grade, the colourists may need to proceed to a secondary grade, which is applied to selected areas of the image. For instance, the specific grade could be applied to the yellow pixels only. Alternatively, the grade may need to be applied to a particular object, or person. In that case, the artist would need to pull a mask of the object and track throughout the video. Colour grading and colour statistics There is a key relationship between histograms, brightness, contrast and the colour grading that is applied. Colourists have some intuition for it, as they monitor the effect of the colour grade on the histograms. Let us detail the mathematics of this relationship. Colour grading and colour statistics Assume that we apply an affine colour mapping u ↦ v = t(u) = au + b on the luminance alone. The mean intensity and variance are directly affected by the transform as follows: Colour grading and colour statistics var(v) = var(t(u)) = a 2 var(u) (5) mean(v) = mean(t(u)) = a × mean(u) + b . Colour grading and colour statistics What we learn from this is that changing the lift b directly affects the overall brightness of the image. Conversely, changing the gain a affects the variance and thus the overall contrast of the image. This relationship can be extended to curves and histograms as well. Assume that the 1D curve is increasing monotonically. That is, if we rank luminance values from the darkest to the brightest u 0 < u 1 < u 2 < ⋯ < u n , then the mapping does not change the order: t(u 0 ) < t(u 1 ) < t(u 2 ) < ⋯ < t(u n ). Colour grading and colour statistics Most of the basic colour grading operations are increasing monotonically thus most final grades are increasing monotonically too. Now, under such colour transformations, the proportion of pixels that have a brightness less than a particular value u 0 is the same as the proportion of pixels that have a brightness less than v 0 = t(u 0 ) after transformation. Thus, we have this simple relationship: Colour grading and colour statistics The probability P u u < u 0 corresponds to the cumulative distribution function H u (u 0 ) (e.g. cumulative histogram): Colour grading and colour statistics Assuming continuous distributions, differentiating leads to the following relationship between the probability density functions (pdfs): Colour grading and colour statistics In practice, the continuous pdfs h u and h v are approximated by histograms. Colour grading and colour statistics The colour mapping operates on the cumulative histogram as a warp and the histogram as a re-scaling and warp. Remarks At this point, we can already make two remarks. Remarks Firstly, colour statistics can be gathered without taking notice of the exact locations of the sampled colours. The colour mean, variance, and histograms are all relatively insensitive to motion and stay similar between consecutive frames. This is interesting as colour matching is usually done between pictures with similar content but not pixel identical (e.g. two frames from a sequence, two images of a similar cityscape). Secondly, extremely stretched colour mappings do have an impact on the image noise. Noise is always present on images, due to a combination of sensor thermal noise, debayer algorithms and subsequent compressions artefacts and applying stretched colour mappings may enhance the noise artefacts. For instance, it is well known by colour artists that noisy low light images are difficult to grade, as increasing the exposure has the effect of increasing the noise accordingly (6). Colour transfer We are now interested in the inverse problem of automatically finding the colour grading operations to apply to a picture, to match the colour grade of another one. This is the colour transfer problem, as first coined by Reinhard et al. [1] (2002). Colour transfer If we denote as u i the colour samples of the original image and v i the colour samples of the target palette image, the colour palette of the original and target pictures correspond then to the distributions/histograms h u and h v . The problem is to find a colour mapping u ↦ t(u) such that the new colour distribution h t(u) matches the target palette h v . Simple cases Regression: if we have pixel correspondences between the source scene and the target scene, it is possible to obtain the grading parameters through optimisation. Consider for instance that pixels u i = (r i , g i , b i ) i in the original image are matched to pixel colours v i = (r i ′, g i ′, b i ′) i in the target image, then we can recover all the affine colour transform parameters with least squares: Simple cases where the matrices X = [r i , g i , b i , 1] i and Y = [r i ′, g i ′, b i ′, 1] i stack the colours of the matching pixels. This is the approach used in many colour correction techniques (see for instance Hwang et al. [9], 2014). Moments matching: if we do not have correspondences, we can still derive from (6) a simple mechanism for matching the grade between two images. Given two images for which we measure the mean mean(u), mean(v) and variance var(u) and var(v) for each of the channels. Then we can recover the estimates for the gain and lift per channel with: Simple cases We can even estimate the full affine colour transform parameters by matching the means μ u , μ v and covariance matrices Σ u and Σ v of both distributions. A popular method [10][11][12][13][14] is to find the mapping that realigns the principal axes of Σ v to that of Σ u : Simple cases The square root matrices Σ u 1/2 and Σ v 1/2 are uniquely defined as Simple cases Note that the estimated mapping is not necessarily the same mapping like the one that would be found using least squares with matching pixels. The intension is here to match the target palette, not the exact transformation of each pixel. In fact, many mappings can achieve the transfer of colour distributions. Simple cases Histogram matching: 1D curves/LUTs can also be estimated from the 1D histograms of both images. Starting from the relationship of (8), the histogram matching 1D curve can be found using the inversion of the cumulative histogram H v (v) [15]: Simple cases where Simple cases This 1D mapping can easily be solved by using discrete look-up tables. Simple cases Going beyond 1D LUT and estimating full 3D LUTs turns out to be significantly more complicated. We could apply this 1D nonlinear pdf matching separately for each channel [16] but the results are poor. It is only with the works of Morovic and Sun [3] (2003) and Pitié [5] (2005) that practical solutions were proposed. Problem with N > 1 For continuous distributions (Fig. 3), the relationship on the pdfs of (9) extends to the N-dimensional case as follows: Problem with N > 1 where J t (u) is the Jacobian of t taken at u. This is a non-trivial constraint and the simple relationship we had for cumulative histograms does not hold anymore for N > 1 dimensions, as order and monotonicity are not defined anymore (e.g. we cannot say that blue>orange or that yellow>purple). The idea of monotonicity is actually pivotal and, without it, there are infinitely many solutions to (15). To understand this, consider the discrete distributions problem, with two images of identical size: the distribution transfer problem becomes an assignment problem (see Fig. 4). Given two sets of n colour samples {u i } i = 1: n and {v i } i = 1: n from both images, any assignment of colour u i to v σ(i) , for any permutation σ, will work Problem with N > 1 In other words, assigning pixels in the input image to randomly selected pixels of the target image would be a valid colour grade as the generated image would exactly follow the target distribution. See for instance how both assignments in Figs. 4 and 5 produce the same target palette. Random assignments are unlikely to produce interesting colour grading and the assignment in Fig. 4 is probably more desirable than the one in Fig. 5. This is a real practical problem: recolouring the sky in green and the grass in blue may still globally produce the correct target colour palette but locally the colours will have been swapped. Optimal transport To solve the colour transfer problem, we need to do more than just matching colour distributions. Other conditions need to be added to bring interesting properties to the colour mappings. The most suitable mathematical framework to do this is OT. The link between colour transfer and OT was first made by Morovic and Sun [3] (2003) and Pitié et al. [4] (2005). Monge-Kantorovitch formulation In the historical formulation of OT by Monge (1781), the mapping is not only required to match the target distribution but also to minimise its displacement cost. Monge-Kantorovitch formulation For discrete distributions, the Monge OT problem is to find the permutation/assignment σ that minimises: Monge-Kantorovitch formulation where c(u, v) is the transportation cost function, which is typically Monge-Kantorovitch formulation For continuous distributions, the Monge solution minimises the following objective function: Monge-Kantorovitch formulation In colour transfer, this OT colour map will give the desired palette while minimising the overall colour changes. As we will see later, the optimal map has very interesting geometrical properties. One can think of the displacement cost as a very reasonable prior on the transformation: we want as few changes as possible. The Monge problem is actually very difficult to solve in its original formulation as it is combinatorial in nature. Also, the oneto-one assignment constraint causes issues when multiple pixels share the same colour values (see Fig. 6). Monge-Kantorovitch formulation Real practical colour transfer difficulties arise because of the one-to-one mapping constraints. Consider, for instance, the case where the input image U contains a large region with sky but that the target image V only contains a small patch of sky. The assignment will have to assign some of the pixels in the sky region to something else, hence creating visual artefacts. Monge-Kantorovitch formulation The Kantorovitch's optimal transportation formulation (1942) offers a relaxation of the one-to-one mapping constraint. Instead of estimating a function u ↦ t(u), we are looking to estimate a transportation plan π(u, v), that indicates the proportion of pixels with colour u are mapped to a particular colour v. Monge-Kantorovitch formulation For discrete distributions, the transportation plan π is minimised as follows: Monge-Kantorovitch formulation where π is essentially a joint histogram h uv (u, v) of correspondences between colours u and v, with ∀ j, Monge-Kantorovitch formulation Similarly, for continuous distributions π needs to minimise: Monge-Kantorovitch formulation and π(u, v) is a joint pdf of correspondences between u and v. Importantly, for continuous distributions, the Kantorovitch solution is actually the Monge solution, i.e. the best map is indeed a one-to-one mapping: π(u, v) = δ(t(u) − v). In practice, the continuous case can be approximated by increasing the number of pixels n. For large datasets, the discrete Kantorovitch solution is almost a one-to-one assignment. Monge-Kantorovitch formulation OT is a rich mathematical problem. It originated in optimal transportation and allocation of resources applications (e.g. how to minimise the cost of moving mining ores to factories) but it is now used in many applications in a wide range of fields and major mathematical advances have been made in recent years [17][18][19][20]. Reference books on OT include the monographs by Villani [19,20] (2003, 2009) and more recently by Peyré and Cutiri [21] (2018). Monge-Kantorovitch formulation One notable feature of OT is that it defines very useful distances between histograms and probability measures. These OT distances are also known as Wasserstein distance in statistics and earth mover's distance (EMD) in computer vision [22]: Solving the OT problem The cost of computing the Kantorovitch OT solution is still very expensive as its complexity grows as O(n 3 log(n)) with the number of points n [23]. The discretised problem can be numerically solved by linear programming using the simplex algorithm [24]. Several specialised algorithms for solving the transport problem also exist, notably the northwest corner method and the Vogel's approximation [25]. Recently, in a landmark paper, Cuturi [26] showed that a further entropic relaxation of OT could lead to a much more efficient implementation using Sinkhorn's algorithm. A detailed review of this technique and other OT solvers can be found in [21]. Solving the OT problem A notable special case is a 1D case, where the mapping is actually simply the one we defined in (14). Solving the OT problem Another interesting case is if both distributions are multivariate Gaussians, the OT solution is linear and admits a closed-form solution [27]. For two multivariate Gaussian (MVG) N(μ u Σ u ) and N(μ v Σ v ), the linear OT solution is defined as: Solving the OT problem This gives a better alternative to the principal axis method of (13). The merits of this linear mapping for colour transfer are discussed by Pitié in [7,8] (2007). Geometrical properties of the OT maps Despite its mathematical and numerical complexity, OT offers a useful framework for the colour transfer problem. The main interest is that OT maps possess very desirable geometrical properties. Geometrical properties of the OT maps The first one is that assuming continuous pdfs and the OT solution always exists and is unique. Hence, if we take a continuous approximation of the colour distributions, there is always an unambiguous OT map. Moreover, the OT map is the gradient of a convex function [18,28]: the OT solution always exists and is unique. This property is the extension of monotonicity to N-dimensional functions. We pointed out earlier that, in practice, 1D curves used by colourists are most likely monotonic and preserve the order of the pixel values. We cannot order colours in ℝ 3 but this property is the closest we can get to it. This means that bright areas of a picture will remain bright after transformation and that colour inversions or rotations will not happen. In Fig. 7 is shown the OT mapping when matching multivariate Gaussians distributions. The OT mapping is only made of pulling and pushing, no curl or rotation. Using OT in colour transfer OT offers a solid mathematical framework for estimating the colour transfer mapping between colour distributions and the geometrical properties the optimal colour maps are a good match to the kind of operations that colourists do. The practical details on how to use OT are however key. One issue is the size of the distribution. As the cost of computing the OT grows very quickly with the number of samples, Morovic and Sun [3] (2003), and many other works, first discretise the colour distributions into a handful of clusters (e.g. with k-means). Since the number of clusters is relatively low, the OT plan π(u, v) is not a straightforward one-to-one mapping and input colour clusters will be assigned to multiple target colour clusters. Morović proposes to randomly sample the target colours according to the proportions given by the plan π(u, v). This process is, in essence, similar to a randomised dithering. Using OT in colour transfer The first solution to work on very large datasets was proposed by Pitié et al. [4,6] (2005). The proposed solution is to approximate the original Monge-Kantorovitch OT problem by a sliced approximation over 1D distributions. The idea is to break down the problem into a succession of simultaneous 1D distribution transfer problems. For a series of colour directions e n ∈ ℝ 3 , the colours are projected as u ∈ ℝ 3 ↦ u ⊤ e n ∈ ℝ. The projection amounts to applying a colour filter of colour e and looking at the resulting intensity image. The advantage of the projection is that it brings the problem down to a 1D colour transfer problem, which we know how to solve using (14). Intuitively, we are trying to solve the problem by iterating through all the possible colour components of the picture, e.g. cycling through, not only red, green and blue, but also magenta, cyan, orange, purple, yellow, turquoise, grey etc. This approximation of the original OT problem has then been studied in detail as the sliced Wasserstein distance [21,29,30] Colour grading post-processing Figs. 8 and 9 show that applying colour mapping may produce some grainy artefacts. The artefacts are caused by a stretch of the colour mapping as any slight variations in the original image become magnified. As discussed in Section 2.2, the image variance is affected by the stretch as var(au) = a 2 var(u). Stretches in the colour map can be due to large differences in the content of the images (see Fig. 10) or simply because the desired transfer is actually extreme. It is often difficult to fully address this problem before applying the transfer. Gradient matching This problem was first recognised by Pitié et al. [4,6] (2005). The proposed solution was inspired by the work of Pérez et al. [32] (2003) on Poisson image editing. The idea is to loosely match the gradient field of the graded picture to the one of the original picture. That way the structure of the original image is preserved. We present here a slightly simplified version of the energy optimised in [4]: Gradient matching The term ∥ ∇W − ∇U ∥ 2 forces the input image gradient to be preserved and ∥ W − t(U) ∥ 2 preserves the constructed colour mapping (for simplicity the spatial indices x, y have been omitted). The original paper [4] also include weight fields which control where the gradient does not need to match the input image. The energy can be rewritten as a quadratic function: Gradient matching where the sparse matrix L is the Laplacian matrix. One issue with this approach is that by fixing the gradient values, we are essentially assuming that the mapping is locally a simple offset t(u) = u + b. This means that, locally, the image contrast stays the same, regardless of t(u). We can see on the last row of Fig. 9 that the portrait looks slightly blurred. The reason is that the overall contrast is not coherent with the local contrast. Matting Laplacian To be able to change the contrast, another approach is to make local approximations of the colour grading with affine colour transforms. As affine transforms have a constant stretch detJ t (u) = Σ v 1/2 / Σ u 1/2 , they do not produce visible artefacts (besides a possible increase of the noise). By only making local affine approximations, the impact on the overall colour distribution is minimum. Ideally, each local affine transform should be consistent with the neighbouring affine transformations. We can formalise this using the Matting Laplacian framework of Levin et al. [31] (2008). The idea is to jointly optimise for the local affine parameters A i , b i at each pixel i and the filtered image W: local gain maps a rr , a rg , a rb , a gr , a gg , a gb , a br , a bg , a bb and offset maps b r , b g , b b for the image pairs of Fig. 8, with the explicit approach of Pitié [33]. The gain and offset maps are shown as a colour picture (e.g. red = a rr /5 + 0.5, green = a rg /5 + 0.5, and blue = a rb /5 + 0.5) 310 IET Comput. Vis., 2020, Vol. 14 Iss. 6 310 where u j , w j and t(v) i are the colours in U, W and the graded image t(U) at pixel j and i. N i is the neighbourhood at location i, and ∥ A i ∥ 2 2 = ∑ kl A i (k, l) 2 is the L 2 norm. The parameter λ controls the fidelity to the graded image t(U). 310 At this point, following the original approach of Levin et al., we can integrate A, b out of the problem and generate a marginalised estimate of W: 310 This leads to a quadratic energy function: 310 where the sparse Matting Laplacian matrix L M is computed from the input image U [31]. Alternatively, as proposed in Pitié [33] (2016), we can explicitly solve for A, b by minimising: 310 and recover the filtered image W by simply applying the local affine transforms: 310 The Matting Laplacian approach is very successful at preserving the original image structures and it has now become the method of choice for reducing colour transfer artefacts in colour transfer and style transfer applications [34][35][36][37][38] (2013, 2016, 2017, 2018, 2019). Results for various values of λ are shown in Fig. 8. Good parameters are typically around λ = 10 −3 and ϵ = 10 −3 . The idea is that you want to keep ϵ as low as possible to obtain optimal sharpness. The value for λ depends on the quality of the initial colour grade. Low values of λ guarantee maximum fidelity to the original image structure. 310 Existing works use the implicit derivation from Levin's original paper (see (28)), without ever computing the actual values for the gain and offset values. Directly estimating the gain and offset values as in Pitié [33] would, however, be more interesting for the colourists as these maps can easily be edited and applied at different resolutions. Fig. 11 shows the estimated gains and offsets maps for the image pair of Fig. 8. Colour transfer beyond optimal transport Colour transfer does not stop at OT. The literature on colour transfer is large [see review by Faridul et al. [39] (2014)] and a number of fundamental problems still remain unsolved. Colour transfer challenges Recall that colour transfer is about finding a transformation on an input image that can match the colour palette of a target image. Carefully looking at some of the assumptions we made so far will help us identify key outstanding points that need to be addressed. Colour palettes are not colour distributions: The first assumption we made was that the colour palette could be approximated by the colour distribution. This is not always true. As we have seen in Section 4, many colour mapping can achieve a colour distribution transfer, but not all will produce the correct assignments, and cross-matches between different objects are possible. Colour palettes are not colour distributions: If OT gives reasonable estimates, these are not always accurate. For instance, the linear OT map of (22) cannot estimate the desaturation of (4). The reason is that the linear OT map has to be symmetric definite positive and the matrix in (4) is not. In practice, there is not much difference in the final grade because the distributions do match, but both images would be different in some subtle ways as seen in Fig. 12. Colour palettes are not colour distributions: Contextual information needs thus to be exploited to guide the colour transfer. This could be done using pixel correspondences for instance. Distributions rarely match: The second assumption made in the OT approach is that the colour distributions should match. This, again, is not necessarily true. Images used in colour transfer applications are never identical. They could be frames taken from different shots or they could be radically different images. Frequently objects will differ in size (e.g. the amount of visible sky), some objects would have moved or that are only present in one image. In all these cases, the OT map will be affected. We must therefore take care of the distributions before OT can be applied. Colour transfer is more than colour mapping: The last assumption is that one-to-one colour mappings can transform the grade of the image. This is true in first approximation for most tasks, but this is not always true. Take for instance the application of matching lighting conditions for pictures taken at different times of day, under different weather conditions. Properly re-lighting images would require information about the 3D scene geometry, materials, lights setup etc., and no global or local colour grade An example of this problem is demonstrated in Fig. 13, where we try to match the first image of the sequence to photographs taken later during the day. All the pixel locations are aligned and we can directly estimate local affine transforms between both images. To do this we use Levin's Matting Laplacian framework. Even in this best case scenario, where we can find correspondences for each pixel, it is clear that the quality of the grade deteriorates with the day-to-night transition. What is happening is that there is no affine colour transform that can predict how pixels will be illuminated at night. This means that colour transfer may need to operate in a different space than the colour space, as colour alone is not enough to identify how a pixel should be recoloured. Guiding the colour assignments In this section, we look at the solutions proposed in the literature to guide the colour transfer and deal with colour mismatch and content differences between images. Pixel correspondences: One approach to avoid misassignments is to establish pixel correspondences between the input and target images and use these to constrain the colour [62] mapping estimation. This is the approach used in works such as Oliveira et al. [40] (2015), Hwang et al. [9] (2014), Park et al. [41] (2016), Vazquez-Corral and Bertalmio [42] (2014) and Frigo et al. [43] (2015). In these papers, pixel correspondences are used to regress basic global affine colour transform parameters and the gammas. The aim is to achieve a consistent white balance and gamma across different images or a video. When matching vastly different images, classic tracking methods will fail. Dedicated matching algorithms can be found in the work Shih et al. [38] (2013) Efros and Freeman [44] (2001) and more recently in Liu et al. [45] (2018), but these only give rough, sparse, noisy matches. Supplying semantic masks: Another possible approach used by deep learning works [34][35][36][37] is to produce semantic label maps for the images. Modern semantic segmentation algorithms such as DeepLab [46] (2018) can generate masks for common classes (e.g. sky, grass, trees, buildings, cars, people etc.), which can then be used to apply per-class colour transfers. We still need to deal with possible content mismatches as some labels might be present in the input image but not in the target image. Luan et al. [36] (2017) proposed to avoid these orphan labels by constraining the input semantic labels to be chosen among the labels of the reference style image. The idea is to force the semantic segmentation algorithm to find the nearest available label (e.g. choosing 'sea' instead of 'lake'). The semantic maps does not need to be precise to be useful as they are mainly here to compensate for large content variations in the distributions. Also, any error is usually dealt with by the post-processing filter. Using simpler colour models: As artefacts mainly arise with non-smooth colour mappings, a solution to mitigate the impact of content mismatch is to impose some smoothness on the colour mapping. For instance, considering a linear mapping as in (22) will avoid any risk of visible artefacts. Usually, some nonlinearity is necessary when the styles between the input and target images are very different. Then a popular way to obtain smooth non-linear functions is to consider thin plate splines (TPS) as in Grogan et al. [47][48][49] (2012, 2017). There is also the option to approximate the estimated OT map as a TPS [see Frigo et al. [43] (2015)]. Alternatively, we can impose smoothness on the distributions themselves as it will have the implicit effect of smoothing the resulting colour map. This can be done by smoothing the histograms or by employing a kernel density estimates (see Silverman [50]) with large bandwidth h: Using simpler colour models: where K h is the kernel function. Increasing h, increases the smoothness the pdf estimate and of the resulting OT map. The most popular approach is probably to explicitly model the distribution as Gaussian mixture models [48,49,[51][52][53]: Cluster equalisation: To deal with objects changing size between images, a solution is to reduce the relative size of distribution clusters. In this way, the variations in colour proportions are limited [see Pitié et al. [4] (2005) and Neumann and Neumann [54] (2005)]. This strategy is specially adapted when working with GMMs. For instance, Grogan et al. [49] (2017) limit the GMM to 50 clusters and normalise all the weights to w i = 1. Cluster equalisation: Directly manipulating the distributions comes however with many drawbacks. One is that small clusters have their relative importance increased and thus increase the number of orphan clusters that do not have a match in the target image. Also, if the distributions were actually correct to start with, we are now taking the risk of biasing the colour transfer. The best solution is often to leave most of the correction process to the post-processing filter. 6.2.5 Relaxing the optimal transport constraints: A number of works have tried to jointly address the optimal transfer problem and the need to preserve the original picture structure [see Papadakis et al. [55,56] (2010), Freedman and Kisilev [57] (2010)]. In Ferradans et al. [58] (2013), for instance, the OT problem is reworked to relax the mass conservation constraint and allow for additional regularisation terms. The joint optimisation is usually made possible because the structure-preserving energies defined in Section 5 yield simple quadratic regularisation terms. If, as in Papadakis et al. [55], we want to match the original gradient (Pitié et al. [6]), the regularisation term to include is: Cluster equalisation: Similarly, as proposed in deep photo style transfer [36], Levin et al.'s [31] regularisation penalty can be included by simply adding this regularisation term to the overall objective function: Neural colour transfer As discussed in Section 6. Neural colour transfer where the content is compared in the deep feature space: Neural colour transfer and the styles are represented by the Gram matrix of the feature vectors: Neural colour transfer This term is the Frobenius norm of the difference between the Gram matrices of the neural network responses. Minimising the quantity corresponds to minimising the maximum mean discrepancy between the two distributions [64]. The image W itself can be optimised by gradient descent. Backpropagation is used to compute the gradient of the loss function (35) with respect to the input image pixel values. Results reproduced from [62] are shown in Fig. 14. While the method shows impressive performance for artistic stylisation (see top row), the artefacts introduced by the style transfer make this approach inappropriate for direct use as a colour transfer method. Deep photo style transfer Luan et al. [36] adapted the neural style transfer approach to also include specific losses tailored to the colour transfer problem. In particular, Luan Fig. 18-⑳, DPST can selectively recolour the buildings at night time. Deep photo style transfer One notable issue with the approach is that generating a picture requires a costly optimisation. Also, gradient descent is not guaranteed to reach the global minimum. Looking at the results, we find that strong re-colouring choices are being made and colours tend to be too intense. We suspect that this is because of a poor convergence of the gradient descent optimisation. Examples showing optimisation failures can be seen in Fig. 20-37 or Fig. 19-44. Using an encoder-decoder architecture for a closed-form solution To avoid this slow optimisation framework, Li et al. [35] have trained a decoder network that, given some deep features φ, can predict a pre-image X such that ϕ(X) = φ. The network is trained using an encoder-decoder architecture (see Fig. 22). The encoder is VGG-19 and the decoder learns to reconstruct the input image. Using an encoder-decoder architecture for a closed-form solution The idea is then to start from the input image U, compute its deep features ϕ(U), apply a simple linear pdf transfer on the deep feature distributions and then come back to the image domain using the decoder network. Results The difficulty with evaluating colour transfer approaches is the lack of accepted objective benchmark on which the research community could compare their results. Part of the reason is that any evaluation requires an artistic assessment of the transfer. In fact, recent works do start to include user studies to report user preference scores. Results In this review, we are mainly interested in the recent advances in colour transfer that address complex colour style transfers for images. We are thus not going to review colour corrections that Table 1 only necessitate global affine or gamma corrections. We will instead consider example-based colour style transfer applications. We selected a number of challenging input/target image pairs from the list of 60 image pairs provided in [36]. The images are presented in Figs. 15-21. The circled numbers on the figures correspond to the pair index in that dataset. Results The list of evaluated methods and their label in the figures are detailed in Table 1. The range of methods covers most of the significant advances and approaches in the colour transfer. We indicate with the superscript * when the method is followed by the Matting Laplacian filter as a post-process. Results IDT (Pitié et al. [6], 2005), is a reference in the field and is our baseline approximation of the OT solution. Results GMM (Grogan and Dahyot [48], 2019). The method takes a Gaussian mixture model approximation of the colour distribution and also makes an TPS approximation for the colour mapping. The technique also equalises the colour cluster sizes, as discussed in Section 6.2.4. Results The technique operates by matching the 50 most important colour clusters in both images. It is particularly faithful when assigning colour matches (see Fig. 15-② for instance). The cluster size equalisation makes it however prone to mismatch (see for instance the colour inversion in Fig. 17-⑬). Note that Grogan and Dahyot [48] are interested in an interactive application, thus it is expected that the colourist will manually fix these incorrect assignments [48]. Results One other issue is that TPS is too smooth to be able to capture changes across regions that have close colours (see for instance Fig. 16-⩾, where the sky and the building are mapped together, instead of separately). Results OTreg (Ferrandans et al. [58], 2013). The method is based on a regularised OT framework. The framework relaxes the constraint that cluster sizes need to match and also adds a penalty to preserve the image structure. Results The method operates on colour clusters, which can cause some banding artefacts (see Fig. 23), as, contrary to Grogan The results are similar to the baseline IDT approach of Pitié et al. [6] but they usually lack the contrast or the colour accuracy of non-linear transforms. Results DPST (Luan et al. [36], 2017). The method is the deep photo style transfer approach discussed in Section 6.4. The method gives impressive results on some difficult image pairs, especially for dayto-night transitions (see Fig. 16-⩾ and Fig. 18-⑳). The convergence of the method is an issue, however, and strong artefacts can be seen in Fig. 20-37, Fig. 19-44. Results PWCT (Li et al. [35], 2018). Closed-form deep colour transfer approach (see Section 6.5). Results The encoder-decoder structure allows for a fast colour transfer. However, the raw results are very noisy (see Fig. 24). Once the images have been post-processed (see PWCT*), the results are quite good and differ in interesting ways from the baseline OT solutions. For instance, contrary to GMM, OTreg, MKL, IDT, the method can, to some extend, deal with day-to-night transitions (see the bridge in Fig. 16-⩾,the house in Fig. 18-⑳ and the sky in Fig. 16-⩽ and Fig. 18-24). Results The method relies, however, heavily on the Matting Laplacian filter and noisy artefacts still show through after filtering (see the textured sky in Fig. 15-② for instance). Results Semantic labelling. In addition to the state-of-the-art, we also wanted to see how providing semantic labels improves the quality of the colour transfer. We modified the code for (IDT), (MKL) and (regOT) to also operate on semantic masks. We indicate that a method relies on semantic masks with the subscript s. For instance, Fig. 18 Colour grading results for the image pairs 20, 24 of [36], see Table 1 in IDT s * , we apply IDT independently on each of the semantic labels and then post-processed the composite image using the Matting Laplacian filter. Results Most of the day-to-night transfers can be suitably achieved if semantic masks are given, even when using the baselines IDT and MKL. Also, potential issues related to content changes disappear (see for instance Fig. 17-⑮), and colour inversions are possible (see Fig. 20-49 and Fig. 20-50). New artefacts can, however, be produced if the masks are incorrect (e.g. the sky in Fig. 21-59 is split into different segments, creating the white band on the right). Results Also, providing semantic masks nullifies the need for regularising the OT solution or to equalise the cluster weights. Indeed the regularisation of OTReg s * acts as a bias in the estimation, and in most situations, the simple IDT s * is superior (e.g. the colours are better reproduced in Fig. 20-50, Fig. 15-① or Fig. 15-②). Discussion and conclusion As we have seen in this review, OT is still the cornerstone of the colour transfer applications. It is almost always necessary, because, precise, dense and complete pixel correspondence maps are simply never available. Abstracting the analysis to distributions allows us to extend solutions to all pixels in the image. Two of the long-standing issues with OT methods are that: (i) due to content changes, distributions rarely match; and (ii) monotonic OT solutions cannot cope with the complex transfer, like in day-tonight transitions. Discussion and conclusion The addition of semantic masks seems to make an instant improvement to all OT methods. It is a very efficient and affordable way of dealing with content mismatches and complex localised grading. The advantages are also that semantic masks can easily be edited by the colourist and integrated into their workflow. When using semantic masks, it seems to be advantageous to stick to simple, unbiased, methods (e.g. IDT [6], MKL [8]) as making assumptions about the shape of the transform and colour distributions lead to biases in the estimate and can cause failure in edge cases. Discussion and conclusion The recent advances in deep learning offer the most promising avenue to go beyond colour mapping. By working directly in the deep feature space, complex transforms become possible. The approach is still relatively novel, and there is scope to address a number of issues. For instance, if the optimisation scheme of Luan Table 1 for the list of methods 318 IET Comput. Vis., 2020, Vol. 14 Iss. 6, pp. 304-322 This is an open access article published by the IET under the Creative Commons Attribution-NonCommercial-NoDerivs License (http://creativecommons.org/licenses/by-nc-nd/3.0/) et al. [36] is not practical, the encoder-decoder approach of Li et al. [35] is quite imprecise and relies heavily on the post-processing filter. A better approach is still required. Lastly, Levin's Matting Laplacian regularisation can be very effective for suppressing colour grading artefacts.. We propose that explicitly estimating its local affine parameter fields [33] can provide colourists a simple way of editing non-global colour transfer maps. Yet, as we have seen in this review, the Matting Laplacian cannot work for day-to-night transitions or other complex transfers. At its core, the Matting Laplacian assumes that the colour transfer can be explained by a simple local one-to-one colour mapping. This is however not always the case. The solution to go beyond the Matting Laplacian will probably come from neural network approaches, as they seem to hold the key to complex image manipulations. Table 1 for the list of methods IET Comput. Vis., 2020, Vol. 14 Iss. 6, pp. 304-322 This is an open access article published by the IET under the Creative Commons Attribution-NonCommercial-NoDerivs License (http://creativecommons.org/licenses/by-nc-nd/3.0/) Fig. 21 Colour grading results for the image pairs 59, 60 of [36], see Table 1 for the list of methods

섹션 본문 125문단 · 45,688자

(제목 없음)

1Colour grading is an essential step in movie post-production, which is done in the industry by experienced artists on expensive edit hardware and software suites. This paper presents a review of the advances made to automate this process. The review looks in particular at how the state-of-the-art in optimal transport and deep learning has advanced some of the fundamental problems of colour transfer, and how far are we still from being able to automatically grade images.

Introduction

2Colour grading is the artistic process of changing the colour attributes of an image, through the adjustment of colour controls, such as white balance, exposure, brightness, contrast or gamma. It is an essential step in image editing and it is used at different points in the movie production pipeline. It is first used to colour correct shots to reproduce accurately what was recorded. It is then used to colour balance all the shots and establish continuity throughout the movie. Colour grading can also be used later on towards achieving specific practical effects, such as when filming nighttime scenes in daylight. Lastly, colour grading is used to establish a desired visual artistic style. The task is to change the original colours, to match the director's desired colour scheme, whether it is the monochromatic colour scheme of The Matrix, the variations of pink in Grand Budapest Hotel or the complementary orange/blue colours of most action movies.

3Currently, in the industry, colour grading is achieved by experienced artists, called colourists, who use expensive edit hardware and software suites to manually match the colour between the frames. Typical colour grading operations include adjusting the exposure, brightness and contrast, gammas, calibrating the white point or setting a colour mapping curve to non-linearly affect the colour channels. More complex colour grading will require retouching specific areas of the images. Typically the object of interest (actor's face or a car), would be masked out, tracked throughout the shot, and graded separately from the rest of the scene. Grading then becomes a fairly complex operation and it would be therefore beneficial to automate this task in some way.

4In the academic community, the problem of automating this process was first approached as an example-based colour transfer application. The idea, coined by Reinhard et al. [1] (2002), is to find a colour mapping that, when applied to an input image, can change the colour palette to match the one of a target image (see Fig. 1). Early works mainly looked at per-channel solutions [1,2], but it is only when the problem was linked to the theory of optimal transport (OT) [Morovic and Sun [3] (2003), Pitié et al. [4] (2005)], that satisfying solutions for colour images were found. Most of the literature that followed is still based on or related to the mathematical framework of OT.

5Colour transfer does not, however, stop at just finding a mapping that links two colour distributions. In practice, a number of issues need also to be addressed. In a series of papers on the topic, Pitié et al. [4][5][6][7][8] (2005,2007,2008) identified some of these specific issues. One is that applying non-linear colour mapping can cause artefacts that need to be filtered out in post-processing steps. Another is that any difference of content between the input and target images can cause issues during the colour transfer, and mitigating strategies must be put in place.

6In this review, we study the recent advances in colour transfer, OT and deep learning for the application of colour grading images and see how the literature has advanced on these issues.

7Organisation of the review: we will first give some context to the application and go through the core colour grading operations used by the artists and see how these impact the colour distributions (Section 2). The colour transfer problem is then introduced in Section 3 and linked to the theory of OT in Section 4. Recent advances will then be discussed in Sections 5 and 6, and assessed in Section 7.

Background

8Colour correction usually refers to the adjustment of white and black levels, exposure, contrast and white balance that are applied to restore the image original and unprocessed colours. The aim of colour correction is to provide a visually consistent baseline on which subsequent colour adjustments can be accurately applied. All footage and scenes are first carefully matched during that step to create visual consistency throughout scenes.

9Part of the need for colour correction used stems from colour management issues. On the same production, footage may come from different cameras, each camera using its own native input colour space (e.g. Red Log Film, BMD Film Log, S-Log 2 etc.). Also, various footages may be sent around to different postproduction teams, which may apply their own colour corrections or might be working in different colour spaces. Still, the final output has to look the same on any display, let it be a TV display or cinema display. Adopting consistent colour management practices has been a big challenge for the industry, and to standardise the colour management workflows for production and post-production, the Academy of Motion Picture Arts and Sciences introduced in 2014 the Academy Colour Encoding System (ACES), which aimed at becoming the industry standard for managing colour across the entire film making process. Typically artists will start from predefined profiles and then work their way to match a precise colour palette.

Basic colour grading controls

10The basic colour grading operations available to colourists are usually presented to the artists through colour wheels interfaces (see Fig. 2), which help the artist set the lift, gain and gamma for each colour channel. Histograms for each colour channels give the artist useful feedback on their grading operation. Assuming floating-point bitdepth, the basic colour grading operation is defined as follows:

11(1)

12The offsets b r , b g , and b b are sometimes called lifts and control the overall brightness for each channel. Gamma: The gamma values γ r , γ g , and γ b can be used to convert to display gamma, which is usually 2.2, but they can also be used to control the midtones.

13Gain: The gain values a r , a g , and a b can be used to control the colour tint, temperature, and exposure. For instance, the exposure can be changed as follows:

14The white balance/tint can be changed by setting the gains to [a r , a g , a b ] = [1/w r , 1/w g , 1/w b ], where w = [w r , w g , w b ] defines the red, green, and blue (RGB) values of white. Typically the artist would get these values by sampling in the image a pixel that should be white (using for instance a calibration card). The gain, lift, and gamma parameters are interdependent but it may be easier to think that lift primarily affects the shadows, whilst gamma affects the midtones, and gain affects the highlights.

15Colour matrix: Cross channels interactions can also be defined through a simple affine model:

16where A is the 3 × 3 matrix of all cross channels linear dependencies. For instance, colour desaturation can be expressed as:

17where s ∈ [0, 2] controls the amount of colour saturation. Curves: Colourists may need to go beyond these basic controls and manually define one-dimensional (1D) piece-wise polynomial colour mappings by directly specifying spline control points (see Fig. 2

bottom).

18Colour lookup table (LUT): The combined effect of all successive grading operations can be baked into a single LUT. The LUT can be 1D if the colour manipulations are done independently on each channel. The LUT needs to be 3D if the cross-channels' operations are involved. LUT are commonly distributed to achieve colour space conversion or to apply a specific grading profile.

19Secondary and localised grading: Following a global colour grade, the colourists may need to proceed to a secondary grade, which is applied to selected areas of the image. For instance, the specific grade could be applied to the yellow pixels only. Alternatively, the grade may need to be applied to a particular object, or person. In that case, the artist would need to pull a mask of the object and track throughout the video.

Colour grading and colour statistics

20There is a key relationship between histograms, brightness, contrast and the colour grading that is applied. Colourists have some intuition for it, as they monitor the effect of the colour grade on the histograms. Let us detail the mathematics of this relationship.

21Assume that we apply an affine colour mapping u ↦ v = t(u) = au + b on the luminance alone. The mean intensity and variance are directly affected by the transform as follows:

22var(v) = var(t(u)) = a 2 var(u) (5) mean(v) = mean(t(u)) = a × mean(u) + b .

23What we learn from this is that changing the lift b directly affects the overall brightness of the image. Conversely, changing the gain a affects the variance and thus the overall contrast of the image. This relationship can be extended to curves and histograms as well. Assume that the 1D curve is increasing monotonically. That is, if we rank luminance values from the darkest to the brightest u 0 < u 1 < u 2 < ⋯ < u n , then the mapping does not change the order: t(u 0 ) < t(u 1 ) < t(u 2 ) < ⋯ < t(u n ).

24Most of the basic colour grading operations are increasing monotonically thus most final grades are increasing monotonically too. Now, under such colour transformations, the proportion of pixels that have a brightness less than a particular value u 0 is the same as the proportion of pixels that have a brightness less than v 0 = t(u 0 ) after transformation. Thus, we have this simple relationship:

25The probability P u u < u 0 corresponds to the cumulative distribution function H u (u 0 ) (e.g. cumulative histogram):

26Assuming continuous distributions, differentiating leads to the following relationship between the probability density functions (pdfs):

27In practice, the continuous pdfs h u and h v are approximated by histograms.

28The colour mapping operates on the cumulative histogram as a warp and the histogram as a re-scaling and warp.

Remarks

29At this point, we can already make two remarks.

30Firstly, colour statistics can be gathered without taking notice of the exact locations of the sampled colours. The colour mean, variance, and histograms are all relatively insensitive to motion and stay similar between consecutive frames. This is interesting as colour matching is usually done between pictures with similar content but not pixel identical (e.g. two frames from a sequence, two images of a similar cityscape). Secondly, extremely stretched colour mappings do have an impact on the image noise. Noise is always present on images, due to a combination of sensor thermal noise, debayer algorithms and subsequent compressions artefacts and applying stretched colour mappings may enhance the noise artefacts. For instance, it is well known by colour artists that noisy low light images are difficult to grade, as increasing the exposure has the effect of increasing the noise accordingly (6).

Colour transfer

31We are now interested in the inverse problem of automatically finding the colour grading operations to apply to a picture, to match the colour grade of another one. This is the colour transfer problem, as first coined by Reinhard et al. [1] (2002).

32If we denote as u i the colour samples of the original image and v i the colour samples of the target palette image, the colour palette of the original and target pictures correspond then to the distributions/histograms h u and h v . The problem is to find a colour mapping u ↦ t(u) such that the new colour distribution h t(u) matches the target palette h v .

Simple cases

33Regression: if we have pixel correspondences between the source scene and the target scene, it is possible to obtain the grading parameters through optimisation. Consider for instance that pixels u i = (r i , g i , b i ) i in the original image are matched to pixel colours v i = (r i ′, g i ′, b i ′) i in the target image, then we can recover all the affine colour transform parameters with least squares:

34where the matrices X = [r i , g i , b i , 1] i and Y = [r i ′, g i ′, b i ′, 1] i stack the colours of the matching pixels. This is the approach used in many colour correction techniques (see for instance Hwang et al. [9], 2014). Moments matching: if we do not have correspondences, we can still derive from (6) a simple mechanism for matching the grade between two images. Given two images for which we measure the mean mean(u), mean(v) and variance var(u) and var(v) for each of the channels. Then we can recover the estimates for the gain and lift per channel with:

35We can even estimate the full affine colour transform parameters by matching the means μ u , μ v and covariance matrices Σ u and Σ v of both distributions. A popular method [10][11][12][13][14] is to find the mapping that realigns the principal axes of Σ v to that of Σ u :

36The square root matrices Σ u 1/2 and Σ v 1/2 are uniquely defined as

37Note that the estimated mapping is not necessarily the same mapping like the one that would be found using least squares with matching pixels. The intension is here to match the target palette, not the exact transformation of each pixel. In fact, many mappings can achieve the transfer of colour distributions.

38Histogram matching: 1D curves/LUTs can also be estimated from the 1D histograms of both images. Starting from the relationship of (8), the histogram matching 1D curve can be found using the inversion of the cumulative histogram H v (v) [15]:

39where

40This 1D mapping can easily be solved by using discrete look-up tables.

41Going beyond 1D LUT and estimating full 3D LUTs turns out to be significantly more complicated. We could apply this 1D nonlinear pdf matching separately for each channel [16] but the results are poor. It is only with the works of Morovic and Sun [3] (2003) and Pitié [5] (2005) that practical solutions were proposed.

Problem with N > 1

42For continuous distributions (Fig. 3), the relationship on the pdfs of (9) extends to the N-dimensional case as follows:

43where J t (u) is the Jacobian of t taken at u. This is a non-trivial constraint and the simple relationship we had for cumulative histograms does not hold anymore for N > 1 dimensions, as order and monotonicity are not defined anymore (e.g. we cannot say that blue>orange or that yellow>purple). The idea of monotonicity is actually pivotal and, without it, there are infinitely many solutions to (15). To understand this, consider the discrete distributions problem, with two images of identical size: the distribution transfer problem becomes an assignment problem (see Fig. 4). Given two sets of n colour samples {u i } i = 1: n and {v i } i = 1: n from both images, any assignment of colour u i to v σ(i) , for any permutation σ, will work

44In other words, assigning pixels in the input image to randomly selected pixels of the target image would be a valid colour grade as the generated image would exactly follow the target distribution. See for instance how both assignments in Figs. 4 and 5 produce the same target palette. Random assignments are unlikely to produce interesting colour grading and the assignment in Fig. 4 is probably more desirable than the one in Fig. 5. This is a real practical problem: recolouring the sky in green and the grass in blue may still globally produce the correct target colour palette but locally the colours will have been swapped.

Optimal transport

45To solve the colour transfer problem, we need to do more than just matching colour distributions. Other conditions need to be added to bring interesting properties to the colour mappings. The most suitable mathematical framework to do this is OT. The link between colour transfer and OT was first made by Morovic and Sun [3] (2003) and Pitié et al. [4] (2005).

Monge-Kantorovitch formulation

46In the historical formulation of OT by Monge (1781), the mapping is not only required to match the target distribution but also to minimise its displacement cost.

47For discrete distributions, the Monge OT problem is to find the permutation/assignment σ that minimises:

48where c(u, v) is the transportation cost function, which is typically

49For continuous distributions, the Monge solution minimises the following objective function:

50In colour transfer, this OT colour map will give the desired palette while minimising the overall colour changes. As we will see later, the optimal map has very interesting geometrical properties. One can think of the displacement cost as a very reasonable prior on the transformation: we want as few changes as possible. The Monge problem is actually very difficult to solve in its original formulation as it is combinatorial in nature. Also, the oneto-one assignment constraint causes issues when multiple pixels share the same colour values (see Fig. 6).

51Real practical colour transfer difficulties arise because of the one-to-one mapping constraints. Consider, for instance, the case where the input image U contains a large region with sky but that the target image V only contains a small patch of sky. The assignment will have to assign some of the pixels in the sky region to something else, hence creating visual artefacts.

52The Kantorovitch's optimal transportation formulation (1942) offers a relaxation of the one-to-one mapping constraint. Instead of estimating a function u ↦ t(u), we are looking to estimate a transportation plan π(u, v), that indicates the proportion of pixels with colour u are mapped to a particular colour v.

53For discrete distributions, the transportation plan π is minimised as follows:

54where π is essentially a joint histogram h uv (u, v) of correspondences between colours u and v, with ∀ j,

55Similarly, for continuous distributions π needs to minimise:

56and π(u, v) is a joint pdf of correspondences between u and v. Importantly, for continuous distributions, the Kantorovitch solution is actually the Monge solution, i.e. the best map is indeed a one-to-one mapping: π(u, v) = δ(t(u) − v). In practice, the continuous case can be approximated by increasing the number of pixels n. For large datasets, the discrete Kantorovitch solution is almost a one-to-one assignment.

57OT is a rich mathematical problem. It originated in optimal transportation and allocation of resources applications (e.g. how to minimise the cost of moving mining ores to factories) but it is now used in many applications in a wide range of fields and major mathematical advances have been made in recent years [17][18][19][20]. Reference books on OT include the monographs by Villani [19,20] (2003, 2009) and more recently by Peyré and Cutiri [21] (2018).

58One notable feature of OT is that it defines very useful distances between histograms and probability measures. These OT distances are also known as Wasserstein distance in statistics and earth mover's distance (EMD) in computer vision [22]:

Solving the OT problem

59The cost of computing the Kantorovitch OT solution is still very expensive as its complexity grows as O(n 3 log(n)) with the number of points n [23]. The discretised problem can be numerically solved by linear programming using the simplex algorithm [24]. Several specialised algorithms for solving the transport problem also exist, notably the northwest corner method and the Vogel's approximation [25]. Recently, in a landmark paper, Cuturi [26] showed that a further entropic relaxation of OT could lead to a much more efficient implementation using Sinkhorn's algorithm. A detailed review of this technique and other OT solvers can be found in [21].

60A notable special case is a 1D case, where the mapping is actually simply the one we defined in (14).

61Another interesting case is if both distributions are multivariate Gaussians, the OT solution is linear and admits a closed-form solution [27]. For two multivariate Gaussian (MVG) N(μ u Σ u ) and N(μ v Σ v ), the linear OT solution is defined as:

62This gives a better alternative to the principal axis method of (13). The merits of this linear mapping for colour transfer are discussed by Pitié in [7,8] (2007).

Geometrical properties of the OT maps

63Despite its mathematical and numerical complexity, OT offers a useful framework for the colour transfer problem. The main interest is that OT maps possess very desirable geometrical properties.

64The first one is that assuming continuous pdfs and

the OT solution always exists and is unique.

65Hence, if we take a continuous approximation of the colour distributions, there is always an unambiguous OT map. Moreover, the OT map is the gradient of a convex function [18,28]:

66This property is the extension of monotonicity to N-dimensional functions. We pointed out earlier that, in practice, 1D curves used by colourists are most likely monotonic and preserve the order of the pixel values. We cannot order colours in ℝ 3 but this property is the closest we can get to it. This means that bright areas of a picture will remain bright after transformation and that colour inversions or rotations will not happen. In Fig. 7 is shown the OT mapping when matching multivariate Gaussians distributions. The OT mapping is only made of pulling and pushing, no curl or rotation.

Using OT in colour transfer

67OT offers a solid mathematical framework for estimating the colour transfer mapping between colour distributions and the geometrical properties the optimal colour maps are a good match to the kind of operations that colourists do. The practical details on how to use OT are however key. One issue is the size of the distribution. As the cost of computing the OT grows very quickly with the number of samples, Morovic and Sun [3] (2003), and many other works, first discretise the colour distributions into a handful of clusters (e.g. with k-means). Since the number of clusters is relatively low, the OT plan π(u, v) is not a straightforward one-to-one mapping and input colour clusters will be assigned to multiple target colour clusters. Morović proposes to randomly sample the target colours according to the proportions given by the plan π(u, v). This process is, in essence, similar to a randomised dithering.

68The first solution to work on very large datasets was proposed by Pitié et al. [4,6] (2005). The proposed solution is to approximate the original Monge-Kantorovitch OT problem by a sliced approximation over 1D distributions. The idea is to break down the problem into a succession of simultaneous 1D distribution transfer problems. For a series of colour directions e n ∈ ℝ 3 , the colours are projected as u ∈ ℝ 3 ↦ u ⊤ e n ∈ ℝ. The projection amounts to applying a colour filter of colour e and looking at the resulting intensity image. The advantage of the projection is that it brings the problem down to a 1D colour transfer problem, which we know how to solve using (14). Intuitively, we are trying to solve the problem by iterating through all the possible colour components of the picture, e.g. cycling through, not only red, green and blue, but also magenta, cyan, orange, purple, yellow, turquoise, grey etc. This approximation of the original OT problem has then been studied in detail as the sliced Wasserstein distance [21,29,30]

Colour grading post-processing

69Figs. 8 and 9 show that applying colour mapping may produce some grainy artefacts. The artefacts are caused by a stretch of the colour mapping as any slight variations in the original image become magnified. As discussed in Section 2.2, the image variance is affected by the stretch as var(au) = a 2 var(u). Stretches in the colour map can be due to large differences in the content of the images (see Fig. 10) or simply because the desired transfer is actually extreme. It is often difficult to fully address this problem before applying the transfer.

Gradient matching

70This problem was first recognised by Pitié et al. [4,6] (2005). The proposed solution was inspired by the work of Pérez et al. [32] (2003) on Poisson image editing. The idea is to loosely match the gradient field of the graded picture to the one of the original picture. That way the structure of the original image is preserved. We present here a slightly simplified version of the energy optimised in [4]:

71The term ∥ ∇W − ∇U ∥ 2 forces the input image gradient to be preserved and ∥ W − t(U) ∥ 2 preserves the constructed colour mapping (for simplicity the spatial indices x, y have been omitted). The original paper [4] also include weight fields which control where the gradient does not need to match the input image. The energy can be rewritten as a quadratic function:

72where the sparse matrix L is the Laplacian matrix. One issue with this approach is that by fixing the gradient values, we are essentially assuming that the mapping is locally a simple offset t(u) = u + b. This means that, locally, the image contrast stays the same, regardless of t(u). We can see on the last row of Fig. 9 that the portrait looks slightly blurred. The reason is that the overall contrast is not coherent with the local contrast.

Matting Laplacian

73To be able to change the contrast, another approach is to make local approximations of the colour grading with affine colour transforms. As affine transforms have a constant stretch detJ t (u) = Σ v 1/2 / Σ u 1/2 , they do not produce visible artefacts (besides a possible increase of the noise). By only making local affine approximations, the impact on the overall colour distribution is minimum. Ideally, each local affine transform should be consistent with the neighbouring affine transformations. We can formalise this using the Matting Laplacian framework of Levin et al. [31] (2008). The idea is to jointly optimise for the local affine parameters A i , b i at each pixel i and the filtered image W: local gain maps a rr , a rg , a rb , a gr , a gg , a gb , a br , a bg , a bb and offset maps b r , b g , b b for the image pairs of Fig. 8, with the explicit approach of Pitié [33]. The gain and offset maps are shown as a colour picture (e.g. red = a rr /5 + 0.5, green = a rg /5 + 0.5, and blue = a rb /5 + 0.5)

310

74IET Comput. Vis., 2020, Vol. 14 Iss. 6

75where u j , w j and t(v) i are the colours in U, W and the graded image t(U) at pixel j and i. N i is the neighbourhood at location i, and ∥ A i ∥ 2 2 = ∑ kl A i (k, l) 2 is the L 2 norm. The parameter λ controls the fidelity to the graded image t(U).

76At this point, following the original approach of Levin et al., we can integrate A, b out of the problem and generate a marginalised estimate of W:

77This leads to a quadratic energy function:

78where the sparse Matting Laplacian matrix L M is computed from the input image U [31]. Alternatively, as proposed in Pitié [33] (2016), we can explicitly solve for A, b by minimising:

79and recover the filtered image W by simply applying the local affine transforms:

80The Matting Laplacian approach is very successful at preserving the original image structures and it has now become the method of choice for reducing colour transfer artefacts in colour transfer and style transfer applications [34][35][36][37][38] (2013, 2016, 2017, 2018, 2019). Results for various values of λ are shown in Fig. 8. Good parameters are typically around λ = 10 −3 and ϵ = 10 −3 . The idea is that you want to keep ϵ as low as possible to obtain optimal sharpness. The value for λ depends on the quality of the initial colour grade. Low values of λ guarantee maximum fidelity to the original image structure.

81Existing works use the implicit derivation from Levin's original paper (see (28)), without ever computing the actual values for the gain and offset values. Directly estimating the gain and offset values as in Pitié [33] would, however, be more interesting for the colourists as these maps can easily be edited and applied at different resolutions. Fig. 11 shows the estimated gains and offsets maps for the image pair of Fig. 8.

Colour transfer beyond optimal transport

82Colour transfer does not stop at OT. The literature on colour transfer is large [see review by Faridul et al. [39] (2014)] and a number of fundamental problems still remain unsolved.

Colour transfer challenges

83Recall that colour transfer is about finding a transformation on an input image that can match the colour palette of a target image. Carefully looking at some of the assumptions we made so far will help us identify key outstanding points that need to be addressed.

Colour palettes are not colour distributions:

84The first assumption we made was that the colour palette could be approximated by the colour distribution. This is not always true. As we have seen in Section 4, many colour mapping can achieve a colour distribution transfer, but not all will produce the correct assignments, and cross-matches between different objects are possible.

85If OT gives reasonable estimates, these are not always accurate. For instance, the linear OT map of (22) cannot estimate the desaturation of (4). The reason is that the linear OT map has to be symmetric definite positive and the matrix in (4) is not. In practice, there is not much difference in the final grade because the distributions do match, but both images would be different in some subtle ways as seen in Fig. 12.

86Contextual information needs thus to be exploited to guide the colour transfer. This could be done using pixel correspondences for instance.

Distributions rarely match:

87The second assumption made in the OT approach is that the colour distributions should match. This, again, is not necessarily true. Images used in colour transfer applications are never identical. They could be frames taken from different shots or they could be radically different images. Frequently objects will differ in size (e.g. the amount of visible sky), some objects would have moved or that are only present in one image. In all these cases, the OT map will be affected. We must therefore take care of the distributions before OT can be applied.

Colour transfer is more than colour mapping:

88The last assumption is that one-to-one colour mappings can transform the grade of the image. This is true in first approximation for most tasks, but this is not always true. Take for instance the application of matching lighting conditions for pictures taken at different times of day, under different weather conditions. Properly re-lighting images would require information about the 3D scene geometry, materials, lights setup etc., and no global or local colour grade An example of this problem is demonstrated in Fig. 13, where we try to match the first image of the sequence to photographs taken later during the day. All the pixel locations are aligned and we can directly estimate local affine transforms between both images. To do this we use Levin's Matting Laplacian framework. Even in this best case scenario, where we can find correspondences for each pixel, it is clear that the quality of the grade deteriorates with the day-to-night transition. What is happening is that there is no affine colour transform that can predict how pixels will be illuminated at night. This means that colour transfer may need to operate in a different space than the colour space, as colour alone is not enough to identify how a pixel should be recoloured.

Guiding the colour assignments

89In this section, we look at the solutions proposed in the literature to guide the colour transfer and deal with colour mismatch and content differences between images.

Pixel correspondences:

90One approach to avoid misassignments is to establish pixel correspondences between the input and target images and use these to constrain the colour [62] mapping estimation. This is the approach used in works such as Oliveira et al. [40] (2015), Hwang et al. [9] (2014), Park et al. [41] (2016), Vazquez-Corral and Bertalmio [42] (2014) and Frigo et al. [43] (2015). In these papers, pixel correspondences are used to regress basic global affine colour transform parameters and the gammas. The aim is to achieve a consistent white balance and gamma across different images or a video. When matching vastly different images, classic tracking methods will fail. Dedicated matching algorithms can be found in the work Shih et al. [38] (2013) Efros and Freeman [44] (2001) and more recently in Liu et al. [45] (2018), but these only give rough, sparse, noisy matches.

Supplying semantic masks:

91Another possible approach used by deep learning works [34][35][36][37] is to produce semantic label maps for the images. Modern semantic segmentation algorithms such as DeepLab [46] (2018) can generate masks for common classes (e.g. sky, grass, trees, buildings, cars, people etc.), which can then be used to apply per-class colour transfers. We still need to deal with possible content mismatches as some labels might be present in the input image but not in the target image. Luan et al. [36] (2017) proposed to avoid these orphan labels by constraining the input semantic labels to be chosen among the labels of the reference style image. The idea is to force the semantic segmentation algorithm to find the nearest available label (e.g. choosing 'sea' instead of 'lake'). The semantic maps does not need to be precise to be useful as they are mainly here to compensate for large content variations in the distributions. Also, any error is usually dealt with by the post-processing filter.

Using simpler colour models:

92As artefacts mainly arise with non-smooth colour mappings, a solution to mitigate the impact of content mismatch is to impose some smoothness on the colour mapping. For instance, considering a linear mapping as in (22) will avoid any risk of visible artefacts. Usually, some nonlinearity is necessary when the styles between the input and target images are very different. Then a popular way to obtain smooth non-linear functions is to consider thin plate splines (TPS) as in Grogan et al. [47][48][49] (2012, 2017). There is also the option to approximate the estimated OT map as a TPS [see Frigo et al. [43] (2015)]. Alternatively, we can impose smoothness on the distributions themselves as it will have the implicit effect of smoothing the resulting colour map. This can be done by smoothing the histograms or by employing a kernel density estimates (see Silverman [50]) with large bandwidth h:

93where K h is the kernel function. Increasing h, increases the smoothness the pdf estimate and of the resulting OT map. The most popular approach is probably to explicitly model the distribution as Gaussian mixture models [48,49,[51][52][53]:

Cluster equalisation:

94To deal with objects changing size between images, a solution is to reduce the relative size of distribution clusters. In this way, the variations in colour proportions are limited [see Pitié et al. [4] (2005) and Neumann and Neumann [54] (2005)]. This strategy is specially adapted when working with GMMs. For instance, Grogan et al. [49] (2017) limit the GMM to 50 clusters and normalise all the weights to w i = 1.

95Directly manipulating the distributions comes however with many drawbacks. One is that small clusters have their relative importance increased and thus increase the number of orphan clusters that do not have a match in the target image. Also, if the distributions were actually correct to start with, we are now taking the risk of biasing the colour transfer. The best solution is often to leave most of the correction process to the post-processing filter. 6.2.5 Relaxing the optimal transport constraints: A number of works have tried to jointly address the optimal transfer problem and the need to preserve the original picture structure [see Papadakis et al. [55,56] (2010), Freedman and Kisilev [57] (2010)]. In Ferradans et al. [58] (2013), for instance, the OT problem is reworked to relax the mass conservation constraint and allow for additional regularisation terms. The joint optimisation is usually made possible because the structure-preserving energies defined in Section 5 yield simple quadratic regularisation terms. If, as in Papadakis et al. [55], we want to match the original gradient (Pitié et al. [6]), the regularisation term to include is:

96Similarly, as proposed in deep photo style transfer [36], Levin et al.'s [31] regularisation penalty can be included by simply adding this regularisation term to the overall objective function:

Neural colour transfer

97As discussed in Section 6.

98where the content is compared in the deep feature space:

99and the styles are represented by the Gram matrix of the feature vectors:

100This term is the Frobenius norm of the difference between the Gram matrices of the neural network responses. Minimising the quantity corresponds to minimising the maximum mean discrepancy between the two distributions [64]. The image W itself can be optimised by gradient descent. Backpropagation is used to compute the gradient of the loss function (35) with respect to the input image pixel values. Results reproduced from [62] are shown in Fig. 14. While the method shows impressive performance for artistic stylisation (see top row), the artefacts introduced by the style transfer make this approach inappropriate for direct use as a colour transfer method.

Deep photo style transfer

101Luan et al. [36] adapted the neural style transfer approach to also include specific losses tailored to the colour transfer problem. In particular, Luan Fig. 18-⑳, DPST can selectively recolour the buildings at night time.

102One notable issue with the approach is that generating a picture requires a costly optimisation. Also, gradient descent is not guaranteed to reach the global minimum. Looking at the results, we find that strong re-colouring choices are being made and colours tend to be too intense. We suspect that this is because of a poor convergence of the gradient descent optimisation. Examples showing optimisation failures can be seen in Fig. 20-37 or Fig. 19-44.

Using an encoder-decoder architecture for a closed-form solution

103To avoid this slow optimisation framework, Li et al. [35] have trained a decoder network that, given some deep features φ, can predict a pre-image X such that ϕ(X) = φ. The network is trained using an encoder-decoder architecture (see Fig. 22). The encoder is VGG-19 and the decoder learns to reconstruct the input image.

104The idea is then to start from the input image U, compute its deep features ϕ(U), apply a simple linear pdf transfer on the deep feature distributions and then come back to the image domain using the decoder network.

Results

105The difficulty with evaluating colour transfer approaches is the lack of accepted objective benchmark on which the research community could compare their results. Part of the reason is that any evaluation requires an artistic assessment of the transfer. In fact, recent works do start to include user studies to report user preference scores.

106In this review, we are mainly interested in the recent advances in colour transfer that address complex colour style transfers for images. We are thus not going to review colour corrections that Table 1 only necessitate global affine or gamma corrections. We will instead consider example-based colour style transfer applications. We selected a number of challenging input/target image pairs from the list of 60 image pairs provided in [36]. The images are presented in Figs. 15-21. The circled numbers on the figures correspond to the pair index in that dataset.

107The list of evaluated methods and their label in the figures are detailed in Table 1. The range of methods covers most of the significant advances and approaches in the colour transfer. We indicate with the superscript * when the method is followed by the Matting Laplacian filter as a post-process.

108IDT (Pitié et al. [6], 2005), is a reference in the field and is our baseline approximation of the OT solution.

109GMM (Grogan and Dahyot [48], 2019). The method takes a Gaussian mixture model approximation of the colour distribution and also makes an TPS approximation for the colour mapping. The technique also equalises the colour cluster sizes, as discussed in Section 6.2.4.

110The technique operates by matching the 50 most important colour clusters in both images. It is particularly faithful when assigning colour matches (see Fig. 15-② for instance). The cluster size equalisation makes it however prone to mismatch (see for instance the colour inversion in Fig. 17-⑬). Note that Grogan and Dahyot [48] are interested in an interactive application, thus it is expected that the colourist will manually fix these incorrect assignments [48].

111One other issue is that TPS is too smooth to be able to capture changes across regions that have close colours (see for instance Fig. 16-⩾, where the sky and the building are mapped together, instead of separately).

112OTreg (Ferrandans et al. [58], 2013). The method is based on a regularised OT framework. The framework relaxes the constraint that cluster sizes need to match and also adds a penalty to preserve the image structure.

113The method operates on colour clusters, which can cause some banding artefacts (see Fig. 23), as, contrary to Grogan The results are similar to the baseline IDT approach of Pitié et al. [6] but they usually lack the contrast or the colour accuracy of non-linear transforms.

114DPST (Luan et al. [36], 2017). The method is the deep photo style transfer approach discussed in Section 6.4. The method gives impressive results on some difficult image pairs, especially for dayto-night transitions (see Fig. 16-⩾ and Fig. 18-⑳). The convergence of the method is an issue, however, and strong artefacts can be seen in Fig. 20-37, Fig. 19-44.

115PWCT (Li et al. [35], 2018). Closed-form deep colour transfer approach (see Section 6.5).

116The encoder-decoder structure allows for a fast colour transfer. However, the raw results are very noisy (see Fig. 24). Once the images have been post-processed (see PWCT*), the results are quite good and differ in interesting ways from the baseline OT solutions. For instance, contrary to GMM, OTreg, MKL, IDT, the method can, to some extend, deal with day-to-night transitions (see the bridge in Fig. 16-⩾,the house in Fig. 18-⑳ and the sky in Fig. 16-⩽ and Fig. 18-24).

117The method relies, however, heavily on the Matting Laplacian filter and noisy artefacts still show through after filtering (see the textured sky in Fig. 15-② for instance).

118Semantic labelling. In addition to the state-of-the-art, we also wanted to see how providing semantic labels improves the quality of the colour transfer. We modified the code for (IDT), (MKL) and (regOT) to also operate on semantic masks. We indicate that a method relies on semantic masks with the subscript s. For instance, Fig. 18 Colour grading results for the image pairs 20, 24 of [36], see Table 1 in IDT s * , we apply IDT independently on each of the semantic labels and then post-processed the composite image using the Matting Laplacian filter.

119Most of the day-to-night transfers can be suitably achieved if semantic masks are given, even when using the baselines IDT and MKL. Also, potential issues related to content changes disappear (see for instance Fig. 17-⑮), and colour inversions are possible (see Fig. 20-49 and Fig. 20-50). New artefacts can, however, be produced if the masks are incorrect (e.g. the sky in Fig. 21-59 is split into different segments, creating the white band on the right).

120Also, providing semantic masks nullifies the need for regularising the OT solution or to equalise the cluster weights. Indeed the regularisation of OTReg s * acts as a bias in the estimation, and in most situations, the simple IDT s * is superior (e.g. the colours are better reproduced in Fig. 20-50, Fig. 15-① or Fig. 15-②).

Discussion and conclusion

121As we have seen in this review, OT is still the cornerstone of the colour transfer applications. It is almost always necessary, because, precise, dense and complete pixel correspondence maps are simply never available. Abstracting the analysis to distributions allows us to extend solutions to all pixels in the image. Two of the long-standing issues with OT methods are that: (i) due to content changes, distributions rarely match; and (ii) monotonic OT solutions cannot cope with the complex transfer, like in day-tonight transitions.

122The addition of semantic masks seems to make an instant improvement to all OT methods. It is a very efficient and affordable way of dealing with content mismatches and complex localised grading. The advantages are also that semantic masks can easily be edited by the colourist and integrated into their workflow. When using semantic masks, it seems to be advantageous to stick to simple, unbiased, methods (e.g. IDT [6], MKL [8]) as making assumptions about the shape of the transform and colour distributions lead to biases in the estimate and can cause failure in edge cases.

123The recent advances in deep learning offer the most promising avenue to go beyond colour mapping. By working directly in the deep feature space, complex transforms become possible. The approach is still relatively novel, and there is scope to address a number of issues. For instance, if the optimisation scheme of Luan Table 1 for the list of methods

318

124IET Comput. Vis., 2020, Vol. 14 Iss. 6, pp. 304-322 This is an open access article published by the IET under the Creative Commons Attribution-NonCommercial-NoDerivs License (http://creativecommons.org/licenses/by-nc-nd/3.0/) et al. [36] is not practical, the encoder-decoder approach of Li et al. [35] is quite imprecise and relies heavily on the post-processing filter. A better approach is still required. Lastly, Levin's Matting Laplacian regularisation can be very effective for suppressing colour grading artefacts.. We propose that explicitly estimating its local affine parameter fields [33] can provide colourists a simple way of editing non-global colour transfer maps. Yet, as we have seen in this review, the Matting Laplacian cannot work for day-to-night transitions or other complex transfers. At its core, the Matting Laplacian assumes that the colour transfer can be explained by a simple local one-to-one colour mapping. This is however not always the case. The solution to go beyond the Matting Laplacian will probably come from neural network approaches, as they seem to hold the key to complex image manipulations. Table 1 for the list of methods IET Comput. Vis., 2020, Vol. 14 Iss. 6, pp. 304-322 This is an open access article published by the IET under the Creative Commons Attribution-NonCommercial-NoDerivs License (http://creativecommons.org/licenses/by-nc-nd/3.0/)

Fig. 21

125Colour grading results for the image pairs 59, 60 of [36], see Table 1 for the list of methods

참고문헌 58건

  1. A fast and efficient fuzzy color transfer method 2005 10.1109/isspit.2004.1433825
  2. Topics in Optimal Transportation Graduate studies in mathematics · American Mathematical Society · 2003 10.1090/gsm/058
  3. Wasserstein Barycenter and Its Application to Texture Mixing Lecture notes in computer science · Springer Science+Business Media · 2012 10.1007/978-3-642-24785-9_37
  4. Color style transfer techniques using hue, lightness and saturation histogram matching 2005 10.5555/2381219.2381235
  5. Color Stabilization Along Time and Across Shots of the Same Scene, for One or Several Cameras of Unknown Specifications IEEE Transactions on Image Processing · Institute of Electrical and Electronics Engineers · 2014 10.1109/tip.2014.2344312
  6. Color histogram specification by histogram warping Proceedings of SPIE, the International Society for Optical Engineering/Proceedings of SPIE · SPIE · 2005 10.1117/12.596953
  7. Multi-scale image harmonization ACM Transactions on Graphics · Association for Computing Machinery · 2010 10.1145/1778765.1778862
  8. Image quilting for texture synthesis and transfer 2001 10.1145/383259.383296
  9. Selective color transfer with multi-source images Pattern Recognition Letters · Elsevier BV · 2009 10.1016/j.patrec.2009.01.004
  10. Automated colour grading using colour distribution transfer Computer Vision and Image Understanding · Elsevier BV · 2007 10.1016/j.cviu.2006.11.011
  11. A Probabilistic Approach for Color Correction in Image Mosaicking Applications IEEE Transactions on Image Processing · Institute of Electrical and Electronics Engineers · 2014 10.1109/tip.2014.2375642
  12. Sliced and Radon Wasserstein Barycenters of Measures Journal of Mathematical Imaging and Vision · Springer Science+Business Media · 2014 10.1007/s10851-014-0506-3
  13. Data-driven hallucination of different times of day from a single outdoor photo ACM Transactions on Graphics · Association for Computing Machinery · 2013 10.1145/2508363.2508419
  14. A Closed-Form Solution to Natural Image Matting IEEE Transactions on Pattern Analysis and Machine Intelligence · IEEE Computer Society · 2007 10.1109/tpami.2007.1177
  15. Partial Differential Equations and Monge-Kantorovich Mass Transfer Current Developments in Mathematics · International Press of Boston, Inc. · 1997 10.4310/cdm.1997.v1997.n1.a2
  16. Object-to-object color transfer: Optimal flows and SMSP transformations 2010 10.1109/cvpr.2010.5540201
  17. Compressing and companding high dynamic range images with subband architectures ACM Transactions on Graphics · Association for Computing Machinery · 2005 10.1145/1073204.1073271
  18. Accurate 3D image colour histogram transformation Pattern Recognition Letters · Elsevier BV · 2003 10.1016/s0167-8655(02)00328-8
  19. Color Transfer Using Probabilistic Moving Least Squares 2009 IEEE Conference on Computer Vision and Pattern Recognition · 2014 10.1109/cvpr.2014.427
  20. The distance between two random vectors with given dispersion matrices Linear Algebra and its Applications · Elsevier BV · 1982 10.1016/0024-3795(82)90112-4
  21. Object matching in disjoint cameras using a color transfer approach Machine Vision and Applications · Springer Science+Business Media · 2007 10.1007/s00138-007-0079-x
  22. An efficient PCA-based color transfer method Journal of Visual Communication and Image Representation · Elsevier BV · 2006 10.1016/j.jvcir.2006.08.001
  23. A Variational Model for Histogram Transfer of Color Images IEEE Transactions on Image Processing · Institute of Electrical and Electronics Engineers · 2010 10.1109/tip.2010.2095869
  24. The geometry of optimal transportation Acta Mathematica · Mittag-Leffler Institute · 1996 10.1007/bf02392620
  25. Uniform color transfer 2005 10.1109/icip.2005.1530548
  26. Linear Programming and Extensions RAND Corporation eBooks · RAND Corporation · 1963 10.7249/r366
  27. Polar factorization and monotone rearrangement of vector‐valued functions Communications on Pure and Applied Mathematics · Wiley · 1991 10.1002/cpa.3160440402
  28. N-dimensional probability density function transfer and its application to color transfer 2005 10.1109/iccv.2005.166
  29. The Earth Mover's Distance as a Metric for Image Retrieval International Journal of Computer Vision · Springer Science+Business Media · 2000 10.1023/a:1026543900054
  30. Two-scale tone management for photographic look ACM Transactions on Graphics · Association for Computing Machinery · 2006 10.1145/1141911.1141935
  31. Regularized Discrete Optimal Transport SIAM Journal on Imaging Sciences · Society for Industrial and Applied Mathematics · 2014 10.1137/130929886
  32. A scene-referred color transfer for pleasant imaging on display 2005 10.1109/icip.2005.1529977
  33. Motion driven tonal stabilization 2015 10.1109/icip.2015.7351429
  34. The Distribution of a Product from Several Sources to Numerous Localities Journal of Mathematics and Physics · Wiley · 1941 10.1002/sapm1941201224
  35. DeepLab: Semantic Image Segmentation with Deep Convolutional Nets, Atrous Convolution, and Fully Connected CRFs IEEE Transactions on Pattern Analysis and Machine Intelligence · IEEE Computer Society · 2017 10.1109/tpami.2017.2699184
  36. Efficient and Robust Color Consistency for Community Photo Collections 2016 10.1109/cvpr.2016.53
  37. Image Style Transfer Using Convolutional Neural Networks 2016 10.1109/cvpr.2016.265
  38. Enhancement of Digital Photographs Using Color Transfer Techniques Image processing series · CRC Press · 2008 10.1201/9781420054538.ch11
  39. Fast and robust Earth Mover's Distances 2009 10.1109/iccv.2009.5459199
  40. Controlling Perceptual Factors in Neural Style Transfer 2017 10.1109/cvpr.2017.397
  41. Demystifying Neural Style Transfer 2017 10.24963/ijcai.2017/310
  42. Deep Photo Style Transfer 2017 10.1109/cvpr.2017.740
  43. Robust Registration of Gaussian Mixtures for Colour Transfer. arXiv (Cornell University) · Cornell University · 2017
  44. A Survey of Color Mapping and its Applications HAL (Le Centre pour la Communication Scientifique Directe) · Le Centre pour la Communication Scientifique Directe · 2014 10.2312/egst.20141035
  45. User Interaction for Image Recolouring using £2 2017 10.1145/3150165.3150171
  46. Computational Optimal Transport now publishers, Inc. eBooks · 2019 10.1561/9781680835519
  47. Automated Deep Photo Style Transfer arXiv (Cornell University) · Cornell University · 2019 10.48550/arxiv.1901.03915
  48. <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML" display="inline" overflow="scroll" id="d1e500" altimg="si5.gif"><mml:msub><mml:mrow><mml:mi mathvariant="script">L</mml:mi></mml:mrow><mml:mrow><mml:mn>2</mml:mn></mml:mrow></mml:msub></mml:math> Divergence for robust colour transfer Computer Vision and Image Understanding · Elsevier BV · 2019 10.1016/j.cviu.2019.02.002
  49. Very Deep Convolutional Networks for Large-Scale Image Recognition arXiv (Cornell University) · Cornell University · 2014 10.48550/arxiv.1409.1556
  50. An alternative matting Laplacian 2022 IEEE International Conference on Image Processing (ICIP) · 2016 10.1109/icip.2016.7533035
  51. Photo Stylistic Brush: Robust Style Transfer via Superpixel-Based Bipartite Graph IEEE Transactions on Multimedia · Institute of Electrical and Electronics Engineers · 2017 10.1109/tmm.2017.2780761
  52. A Closed-Form Solution to Photorealistic Image Stylization Lecture notes in computer science · Springer Science+Business Media · 2018 10.1007/978-3-030-01219-9_28
  53. Poisson image editing ACM Transactions on Graphics · Association for Computing Machinery · 2003 10.1145/882262.882269
  54. Photographic tone reproduction for digital images ACM Transactions on Graphics · Association for Computing Machinery · 2002 10.1145/566654.566575
  55. Density Estimation for Statistics and Data Analysis Springer eBooks · Springer Nature · 1400 10.1007/978-1-4899-3324-9
  56. Optimal Transport Grundlehren der mathematischen Wissenschaften · Springer Nature · 2008 10.1007/978-3-540-71050-9
  57. Digital Image Processing Springer eBooks · Springer Nature · 1991 10.1007/978-3-662-11565-7
  58. The linear Monge-Kantorovitch linear colour mapping for example-based colour transfer 2007 10.1049/cp:20070055