# Detection of Pest Feeding Traces on Industrial Wood Surfaces with 3D Imaging
## 1 Introduction
The surface of round timber contains several different types of defects, including visible wormholes that pests create after cutting. These wormholes can be divided into two groups. The first group is represented by vertical wormholes that penetrate deep into the material, defined as holes more than 2 mm deep. The second group consists of horizontal wormholes which run parallel to the surface of the wood and are up to 2 mm deep. Analysis of the pest damage observed on the surface of the boards during the preliminary research showed that 95% of the damage was visible in the form of holes up to 3 mm in diameter and 10 mm or more in length, filled with excrement left by wood-boring pests (Figure 1). This defect analysis was carried out on material graded by operators on dozens of batches of material supplied by different sawmills. Figure 1 shows the surface of the wood with wormholes of various shapes made by the pests. Magnified images of selected wormholes are also included in Figure 1. These images were obtained using a metrological glass scale with a millimetre grid marked on it. This tool was placed directly onto the surface of the wood containing the wormhole. The image was recorded using a stereovision microscope, which allows the shape of the wormhole to be observed with a visible scale and enables the diameter and horizontal dimensions of each wood surface defect to be measured directly. The imaging of wood defects using vision systems has been developed over many years [5; 6; 7]. The majority of these systems use 2D imaging in the visible and infrared regions [8; 9]. These images are used to analyse the wood surface and detect knots, cracks, and surface defects using conventional methods [10]. Fuzzy analysis methods are also used to analyse 2D images [11]. In recent years, image analysis methods based on artificial intelligence for wood defect identification tasks have also developed rapidly [12; 13; 14; 15; 16]. Thermography methods have also been investigated in wood inspection tasks [17; 18]. Thermographic imaging is carried out at much lower resolutions [19]. One study [20] demonstrates the possibility of using microwave imaging to detect the presence of resin streaks in the log, but without being able to determine the location of the defect. There have also been successful attempts to use ultrasonic methods to detect wood defects in the form of cracks and the presence of knots [21]. Laboratory studies on the detection of pest larvae and wormholes using ultrasound are described in [PERSON] [22]. The authors confirm the possibility of detecting pest larvae in one-inch boards. Another approach is multi-sensor point analysis, which allows log validation in a selected cross-section [23]. Internal defects in wood are also analysed using computed tomography [24]. In the work of [PERSON] [25] and [PERSON] [26], the authors used CT scanning to observe pests, including bark beetles, and to analyse the distribution of holes in logs. It is also possible to detect cracks, cavities, and foreign objects [27]. The use of computed tomography (CT) scans for planning the cutting of logs into boards has been the subject of intensive research. CT makes it possible to gather information on the position of knots in the log, which helps operators plan how to cut the boards [28; 29; 30; 31]. Using three-dimensional imaging to detect pitch and measure annual growth is also possible [32]. The medical CT scanner also provides information on the density distribution in the log associated with uneven annual growth or wood moisture distribution [33; 34; 35]. Another application is determining the heartwood/sapwood boundary in the log [36; 37]. Using CT in industrial applications allows imaging at a lower resolution than medical scanners [38]. It limits the detection capabilities of measurement systems based on this imaging technology. Several papers [39; 40; 41] demonstrate the possibility of increasing the efficiency of plank production by using CT scanning to plan log sawing.