A Modeling Approach on the Correction Model of the Chromatic Aberration of Scanned Wood Grain Images

: There always exists subjective and objective color differences between digital wood grain and real wood grain, making it difficult to replicate the color of natural timber. Therefore, we described a novel method of correcting the chromatic aberration of scanned wood grain to maximally restore the objective color information of the real wood grain. A point-to-point correction model of chromatic aberration between the scanned wood grain and the measured wood grain was established based on Circle 1 by adjusting the three channels ( sR , sG , and sB ) of the scanned images. A conversion of the color space was conducted using the mutual conversion formulas. The color change of the scanned images before and after the correction was evaluated through the L* a* b* color-mode-based ΔE* and the lαβ color-model-based CIQI (Color Image Quality Index) and CQE (Color Quality Enhancement). The experimental results showed that the chromatic aberration ΔE* between the scanned wood grain and the measured wood grain decreased and the colorfulness index CIQI of the scanned wood grain increased for most wood specimens after the correction. The values of ΔE* of the twenty kinds of wood specimens decreased by an average of 3.1 in Circle 1 and 2.3 in Circle 2, thus the correction model established based on Circle 1 was effective. The color of the scanned wood grain was more consistent with that of the originals after the correction, which would provide a more accurate color information for the reproductions of wood grain and had an important practical significance.


Introduction
The color of wood or wood grain depends on the absorption and reflection properties of wood components to different wavelengths in the visible light. It is known that color is one of the most important parameters of the aesthetic performance of wood surface, and yet wood components are vulnerable to weathering factors, such as UV radiation and humidity, leading to the discoloration [1][2][3]. In order to imitate the color of natural timber and reduce the influence of environmental factors on the color of wood surface, technologies such as wood staining [4], decorative paper, and 3D-printed wood grain [5] have been applied. Most of these surface decoration methods require the image acquisition of the natural wood grain to obtain the digital grain, and they are then applied to mass reproductions [6]. However, there always exists subjective and objective color differences between the digital wood grain and the real wood grain, making it difficult to replicate the color of natural timber.
Sang et al. [5] printed the scanned images of a real wood surface by UV-curable inkjet technology, and the replicated wood grain on wood-based panels presented a very vivid and realistic effect in color, texture, and touch under natural light. However, it was not mentioned whether there was any chromatic aberration between the real wood surface and the replicated surface. Nordvik et al. [7] studied the experienced difference between wood seen physically and the picture of it on a computer screen. Forsthuber et al. [8] proved that there was a strong correlation between the values of the relative color change obtained by a spectrophotometer and by a calibrated photo-scanner, while only a moderate correlation was obtained comparing the absolute colorimetric values. In fact, it is because the median filter denoising conducted by the authors during the image analysis and the denoising mainly works on the blue channel. As the blue filter is the least efficient in terms of allowing light to pass through, the scanner noise is typically strongest in the blue channel [9]. To obtain the scanned wood grain whose color is maximally consistent with that of the real grain, image preprocessing such as denoising should be avoided during the image acquisition. In addition, the color-management software compares the known colors of the target (CIE-LAB values in the reference file) with the corresponding RGB values of the scanned target file. From this comparison, the software builds a profile to help applications such as Photoshop or Lightroom understand the input device's RGB values; that is, calibrating and profiling input devices helps us to better understand the colors of our originals [10], and it apparently has no effects on the scanned colors. Feng et al. [11] adjusted the * * * values in Photoshop CC 2018 (Adobe Inc., San Jose, CA, USA) to decrease the chromatic aberration of the scanned images. The * * * differences between the real wood grain and the digital grain reduced, and yet it was a subjective operation process requiring constant adjustments to achieve the ideal result.
From the above, comparing the chromatic aberration between the real wood grain and the digital grain has been proven to be an interesting exploration. However, color correction is mostly used in the distorted images caused by shooting environment [12,13] or in the chromatic aberration of optics themselves. Han et al. [14] proposed an RGBN (Red-green-blue and Near-infrared) camera color correction pipeline to solve color bias and the multicollinearity of the imaging devices. Kozubek et al. [15] invented a novel method of chromatic aberration measurement and software correction using subresolution bead imaging and computer image analysis. Additionally, in terms of studies on real wood color, Yao et al. [16] investigated the effect of heat on color and surface chemistry of wood flour (WF). Forsthuber et al. [17] developed a novel color measurement procedure to estimate the color of early-and latewood in the annual rings of wood. Nasir et al. [18] used the * * * color measuring system to develop a machine learning model for predicting the mechanical properties of artificially weathered fir, alder, oak, and poplar wood. Studies on the digital wood color such as the color analysis of digital Birch wood after the heat treatment [19] and those about the color image itself, such as the perceptually optimized enhancement of color in images using JND (Just Noticeable Difference) transform and color constancy [20] and the novel method on color image enhancement [21] have also been widely reported.
Overall, only a few studies focused on the correction of chromatic aberration between real wood grain and digital grain. In order to maximally restore the objective color information of the real wood grain by digitalizing, we reduced the chromatic aberration by establishing a point-to-point correction model of , , and between the measured wood grain and the scanned wood grain. The color information of digital images and that of real objects was connected through this method. The * * * values of the scanned wood grain after the correction were more consistent with those of the real grain and they could be saved as wood material stock images. Most importantly, a more accurate color information of the natural timber would be provided for the reproductions of wood grain by color correcting.

Pretreatment and Scanning of Wood Grain
Wood specimens from twenty kinds of tree species were selected as the research objects. The specimens free from knots were cut to the size of 65 mm × 40 mm × 10 mm (length × width × height) and polished to prepare a clear and flat surface. All these pieces were conditioned for 3 months in a climate room at 20 °C and 65% RH to constant weight.
Flatbed scanners are commonly available at low cost [8]. Prior to the scanning, two identical circles with a diameter of about 32 mm were drawn on the wood surface according to the area covered by the colorimeter when measuring colors. The twenty pieces of wood were then scanned centrally at one time by HP Smart Tank (Hewlett-Packard Co., Beijing, China) scanner with a charge coupled device CIS at 8 bits per channel and 300 ppi (pixels per inch) resolution. As mentioned above, color management had no effects on the scanned colors, and calibrating and profiling the scanner was canceled. Automatic color adjustments in the scanner settings were turned off and no denoising or sharpening options were enabled in order to maximally reproduce the colors of originals.
The scanned wood grain was stored in a lossless TIFF format and cropped to the size of 60 mm × 35 mm (length × width). Hence, the size of each wood image is 709 × 413 pixels with 256 gray levels. The twenty kinds of wood specimens are shown in Figure 1 and Table 1.  The images we acquire are usually the sRGB format of nonlinear color space [22], and it is necessary to convert the sRGB to the RGB of linear color space, i.e., gamma correction [23], then to XYZ and * * * . However, roundtripping from RGB to * * * to RGB is a destructive process on 8-bit/channel images [9]. In consequence, the original sRGB format of the scanned images was kept, and the colorimetric values of sRGB and * * * were calculated using the mutual conversion formulas.
(1) sRGB to * * * The conversion of gamma correction is as Equation (1). The conversion of RGB to XYZ is as Equation (2). The conversion of XYZ to * * * is as Equations (3) and (4) where the value of is , , and . The values of * , * , and * are obtained by substituting the values of ( ) into Equation (4).

Color Measurement of Original Wood Grain
The color measurement of the wood specimens was conducted using a Color Meter Pro (CHNSpec Technology Co., Hangzhou, China) with D/8-SCI at D65 lighting condition and 10° field angle. As the * * * color space has been widely used to represent surface colors [24][25][26], values of lightness * and chromaticity * and * were measured.
The colorimeter was then placed on the two circles of the wood specimens. Each circle was measured three times and the average value was taken. This value represented the mean colorimetric value within the circle with a diameter of 8 mm on the wood surface due to the 8 mm measuring aperture. The 8 mm circle was also concentric with the 32 mm drawn one.

Color Calculation of Digital Wood Grain
As shown in Figure 2, a concentric circle with a diameter of 8 mm was drawn in the 32 mm circle, and the 8 mm circle was cut out and saved in a PNG format at 8 bits per channel and 300 ppi resolution. The mean values of sRGB of the 8 mm circles were obtained in Photoshop CC2018, and color conversion was conducted using Equations (1)-(4) to calculate the mean values of * * * .

Correction Model of Chromatic Aberration
Since there might be a strong correlation between the values of the relative color change obtained by a spectrophotometer and by an uncalibrated scanner, it was assumed that the colorimetric values between the measured point on the original wood grain and the corresponding point on the digital grain had a certain proportion. Based on this assumption, the colorimetric values of Circle 1 were used to establish the correction model, and those of Circle 2 were used to further confirm whether the assumption was tenable.
Initially, we converted the measured * * * values of the 8 mm circles in Circle 1 to the sRGB values. Secondly, we calculated the chromatic aberration between this converted sRGB values and the sRGB values of the corresponding point on the scanned wood grain. The correction model of the chromatic aberration of , , and are as Equations (9)-(11), respectively.
where are the converted values of the 8 mm circles on the original wood grain using Equations (5)- (8), and are the values of the corresponding point on the digital wood grain. is the average values of all pixels in the scanned image [27]. ( , ) is the pixel value of one point at the image coordinate, and ′( , ) is that after the chromatic aberration correction.

Calculation of Chromatic Aberration
The total color difference of the 8 mm circles between the digital wood grain and the original wood grain was calculated using the Equation (12) [8,26]: * = √ * + * + * where * is the comprehensive evaluation index of color difference, * is the lightness difference, * and * are the chromaticity differences.

Evaluation of Colorfulness Index
Colorfulness is the attribute of chrominance information humans perceive. Panetta et al. [28] demonstrate that colorfulness can be represented effectively with combinations of image statistics. The lαβ color model proposed by Ruderman et al. [29] is based on human vision system, and it will not be affected by environment or device [30]. Therefore, to further investigate the color change of scanned wood grain before and after the correction, two metrics using the lαβ color model were introduced to evaluate the colorfulness.
The CIQI (Color Image Quality Index) colorfulness metric [31] is shown in Equation (13) Zhang et al. [32] introduced the logarithmic operation into the colorfulness measure because the subjective sensation was proportional to the logarithm of the stimulus. As shown in Equation (14), the CQE (Color Quality Enhancement) colorfulness metric was proposed by combinations of a subset of color image quantities in the logarithmic domain [28].

Statistical Analyses before the Chromatic Aberration Correction
The colorimetric values of the 8 mm circles obtained by measuring and scanning were compared. The correlation diagrams between them are shown in Figure 3. Clearly there was a highly linear positive correlation of the , , and values obtained through the two methods, and the difference between Circle 1 and Circle 2 was small. As a result, the assumption mentioned in 3.3 was valid, and the colorimetric values of Circle 1 were used to establish the correction model. The values of * of the 8 mm circles between the measured wood grain and the scanned wood grain before the chromatic aberration correction were calculated using Equation (12). The results are shown in Table 2, and the corresponding cluster analysis diagram is shown in Figure 4.   Figure 4 shows that the values of * are closer for most wood specimens sharing a similar color, but the color difference between the No.1 and No.20 specimens is conspicuous (see Figure 1). This demonstrated that a closer value of * could not represent a similar color of the originals, and the chromatic aberration * between the original wood grain and the digital wood grain depended on the scanner's ability of reproducing different values of , , and . Consequently, it was not recommended to correct the chromatic aberration of different kinds of wood specimens by increasing or decreasing the same sRGB values even if their values of * were close.

Color Comparison after the Chromatic Aberration Correction
The measured * * * values of the 8 mm circles in Circle 1 were converted to sRGB values using Equations (5)- (8), and the sRGB values of the corresponding point on the scanned wood grain were obtained in Photoshop. The correction model was then established on the basis of the difference of sRGB values using Equations (9)- (11).
The values of * of the 8 mm circles between the measured wood grain and the scanned wood grain after the chromatic aberration correction were calculated using Equation (12). The results are shown in Table 3, and the changing trends of * before and after the correction are shown in Figure 5.  It can be seen from Figure 5 that the values of * went down sharply for most wood specimens after the chromatic aberration correction. However, the No. This phenomenon might be explained by the fact that the correction model of the chromatic aberration was established based on Circle 1. It could be further summarized that if one wood surface had distinct colors, multi-point measurements were required to establish different correction models by dividing color regions, which would inevitably cause uncoordinated color block areas in the scanned images after reorganization. Also, it might be very difficult to determine suitably chromatic aberration regions in the images [33]. If the falling range of * was required to be consistent on any point of the scanned images, the better solution was to maximally find the corresponding points between the digital wood grain and the original wood grain, and then to substitute the mean values of the scanned points and the measured points, respectively, into the correction model. In this paper, the surface color of each wood specimen was relatively uniform. Additionally, as the values of * of the 8 mm circles in both Circle 1 and Circle 2 decreased, the correction model established based on Circle 1 was effective. The comparison of the scanned wood grain images before and after the correction is shown in Figure 6. According to the assessment guidelines on the classification of the overall color change used by Hrčková et al. [19], the color change is visible by medium quality filter when the value of * is between 3 and 6. Since less than half of the wood specimens showed a change over 3 of * after the correction, the color difference in Figure 6 was not obvious for most of them.

Colorfulness Evaluation of the Scanned Wood Grain Images
The colorfulness of the scanned wood grain images before and after the chromatic aberration correction was calculated using Equations (13) and (14), respectively. The changes of the evaluation values of CIQI and CQE after the correction are shown in Table  4, and the corresponding scatter diagram before and after the correction is shown in Figure 7.  In general, because the color change of scanned wood grain before and after the correction was not obvious, both the colorfulness metrics showed a low sensitivity. It could be observed from Figure 6 that the saturation of No. 18  Notably, though the color change of most wood specimens was not obvious, it was found from Figure 6 that the saturation of the No.20 wood specimen reduced while its CQE value rose fractionally (see Table 4 and Figure 7), which indicated that the CQE method proposed by Panetta et al. [28] might not be suitable to evaluate the colorfulness of the scanned wood grain images. Accordingly, only the colorfulness index CIQI could accurately evaluate the color change of the scanned wood grain after the chromatic aberration correction of sRGB.

Conclusions
Even the best flatbed scanners available on the market exhibit chromatic aberration to some extent. In this paper, a point-to-point correction model of the chromatic aberration between the scanned wood grain and the measured wood grain was established by adjusting the three channels ( , , and ) of the scanned images to maximally restore the objective color information of the originals. The conversion of the color space was conducted using the mutual conversion formulas. The color change of scanned wood grain before and after the correction was evaluated through the * * * color-mode-based * and the lαβ color-model-based CIQI and CQE.
The experimental results showed that the chromatic aberration * decreased and the colorfulness index CIQI increased for most wood specimens after the correction, while CQE had a few errors in the evaluation. The values of * of the twenty kinds of wood specimens decreased by an average of 3.1 in Circle 1 and 2.3 in Circle 2, thus the correction model established based on Circle 1 was effective. Moreover, both the * and CIQI showed a slight change, indicating that this scanner had already retained the colors of the originals to a large extent.
Multi-point measurements between the digital wood grain and the original wood grain were suggested on one wood surface to ensure that the overall colors of the scanned surface share a consistent change after the correction. The method was implemented by substituting the mean values of the scanned points and the measured points, respectively, into the correction model whether the surface had distinct colors or uniform colors.
Due to inevitable human errors, the measured point on the original wood grain and the corresponding point on the digital grain could not be completely coincident. Furthermore, although the influence of environmental factors on the color of wood surface could be avoided by digitalizing, the reading accuracy of the color information relied on the performance and stability of the measuring and scanning equipment. The influence of these factors on the correction model should be further studied.

Conflicts of Interest:
The authors declare no conflict of interest.