Implementing Painted Wood Species Classification With Two Neural
Networks for Spectral Rectification
WANG Cheng-kun1, CHEN Guang-sheng2, YANG Zhong3, ZHAO Peng2, 4*, DING Hao-tian1
1. College of Electronic and Information Engineering, Heilongjiang University of Science and Technology, Harbin 150010, China
2. College of Computer and Control Engineering, Northeast Forestry University, Harbin 150040, China
3. Research Institute of Wood Industry, Chinese Academy of Forestry, Beijing 100091, China
4. College of Computer Science & Technology and Software, Guangxi University of Science and Technology, Liuzhou 545006, China
摘要: 根据不同木材表面的光谱反射率差异可以对木材树种进行分类识别。在木制家具及工艺品的生产实践中,考虑到防止木材腐败、开裂,美化木制品外表及延长木制品使用寿命等原因,经常需要在木材表面涂抹某种涂饰。涂抹涂饰将导致木材表面光谱反射率曲线产生漂移和变形,经实验验证无法使用原始木材表面的光谱反射率训练出的分类器模型对涂饰木材光谱曲线进行分类识别。相对于原始木材光谱曲线,涂饰木材光谱曲线的漂移和变形可以用非线性模型来拟合;而这种非线性拟合一般使用神经网络来实现。为了能够继续使用原始木材光谱反射率训练的分类器模型,使用全连接神经网络拟合了原始木材光谱反射率和涂饰木材光谱反射率之间的关系模型,通过该模型对涂饰木材光谱反射率进行校正,实现使用原始木材光谱所训练的分类器模型对涂饰木材进行分类识别的目的。此外,还使用卷积神经网络对光谱反射率提取卷积特征,引入表征原始木材光谱反射率和涂饰木材光谱反射率的卷积特征之间关系的隐藏层,将涂饰木材光谱反射率的卷积特征进行校正,并通过输出层输出其分类结果。为了验证所提出的校正模型的有效性,本文以20种木材样本的近红外光谱(950~1 650 nm/near infrared spectra, NIR)和可见光/近红外光谱(350~1 000 nm/visible and near infrared spectra, VIS/NIR)为研究对象,对比了8种不同涂饰建立的校正模型性能。实验结果表明,NIR的校正分类效果要好于VIS/NIR的校正分类效果;卷积神经网络的校正模型可以将涂抹透明涂饰木材表面的NIR分类正确率提高至70%以上;全连接网络模型可以将涂抹透明涂饰木材表面的NIR分类正确率提高至80%以上,但两种模型都无法对非透明涂饰进行校正。从模型的训练速度和识别效率上看,卷积神经网络的校正模型要好于全连接神经网络的校正模型。综上所述,通过神经网络建立起的原始木材光谱反射率和涂饰木材光谱反射率之间的非线性关系模型,可以对涂抹透明涂饰的木材光谱曲线进行校正。进而实现直接使用原始木材光谱反射率所训练出的分类器模型对涂抹透明涂饰木材光谱曲线进行分类识别,使得木材树种分类识别应用领域从原始木材扩展到涂抹透明涂饰木材,具有较好的实际应用意义和前景。
关键词:木材树种识别;木材表面涂饰;神经网络;光谱反射率
Abstract:Wood species can be classified according to the differences in spectral reflectance of different wood surfaces. To prevent wood corruption or cracking, glorify the appearance, and prolong the service time of wood products, wood surfaces often need to be coated with paints in the production practice of wooden furniture and handicrafts. The influence of paints on the spectral reflectance of wood surfaces will lead to the drift and transformation of spectral curves. The experimental results show that the classification model trained by the spectral reflectance of the original wood samples cannot be used to classify the painted wood. The drift and transformation of spectral curves of painted wood compared with original spectral curves without coated paints can be fitted by nonlinear models such as neural networks. To continue to use the classification model trained by the original wood dataset, we use a fully connected neural network to fit the relationship model between the original spectral reflectance and the coating spectral reflectance. Through this model and SVM classifier, the coating spectral reflectance is corrected to realize the classification of painted wood using the classification model trained by the original wood spectrum. We also use the convolutional neural network model to extract the convolutional features of spectral reflectance and add a hidden layer based on the relationship between the convolutional features of original spectral reflectance and coating spectral reflectance to modify the convolutional features of coating spectral reflectance and output the classification results through the output layer. To verify the effectiveness of the proposed scheme, we collect the near-infrared spectral reflectance (NIR: 950~1 650 nm) and visible/NIR spectral reflectance (VIS/NIR: 350~1 000 nm) of 20 wood species and compare the performances of the rectification models for 8 different paints in terms of the corrected spectra. Because of the experimental results, it can be concluded that the classification performance of NIR is better than that of VIS/NIR. The correction model based on the convolutional neural network can improve the NIR classification accuracy of the transparent wood surface to more than 70%. In contrast, the fully connected neural network can improve that to more than 80%, but neither model can correct non-transparent coatings on the wood surface. Regarding training speed and recognition efficiency, the correction model based on a convolutional neural network is better than that based on a fully connected neural network. In summary, the nonlinear relationship model between the original spectral reflectance and the coating spectral reflectance established by these two neural networks can correct the coating spectral reflectance with clear paints and then classify the painted wood directly by the classification model trained by the original spectral reflectance. The proposed scheme extends wood species classification from the original wood product to coating wood with clear paints with certain practical application significance and prospect.
[1] Timar M C, Gurǎu L, Porojan M. International Journal of Conservation Science, 2012, 3(1): 11.
[2] Wang T, Jiang T, Liu K, et al. PhotoniX 3, 11(2022). https://doi.org/10.1186/s43074-022-00058-0.
[3] Zhang X, Gao J, Gan Y, et al. PhotoniX 4, 10(2023). https://doi.org/10.1186/s43074-023-00087-3.
[4] Pan X, Li K, Chen Z, et al. Forests, 2021, 12(11): 1527.
[5] Pan X, Qiu J, Yang Z. Spectroscopy, 2022, 37(6): 16.
[6] Hao Y, Wang Q, Zhang S. Spectroscopy, 2021, 36(s12): 7.
[7] Yu H, Liang Y, Liang H, et al. Journal of Forestry Research, 2019, 30(6): 2379.
[8] Lazarescu C, Hart F, Pirouz Z, et al. International Wood Products Journal, 2017, 8(1): 32.
[9] Yang Z, Liu Y, Pang X, et al. BioResources, 2015, 10(4): 8505.
[10] Zhang M, Xie X, Zhang D, et al. Microwave and Optical Technology Letters, 2023, 65(5): 1117.
[11] YU Hai-peng, LIU Yi-xing, LUO Guang-hua(于海鹏, 刘一星, 罗光华). Journal of Building Materials(建筑材料学报), 2007, 10(4): 463.
[12] Geng J, Shi L, Ni J, et al. PhotoniX 3, 14(2022). https://doi.org/10.1186/s43074-022-00061-5.
[13] Jiao Y, Li Z, Chen X, et al. Journal of Chemometrics, 2020, 34(11): e3306.
[14] Tong Y, Yu L, Li S, et al. ASP Transactions on Pattern Recognition and Intelligent Systems, 2021, 1(1): 32.
[15] Wilamowski B M, Yu H. IEEE Transactions on Neural Networks, 2010, 21(6): 930.
[16] Lindsay G W. Journal of Cognitive Neuroscience, 2021, 33(10): 2017.