Skip to main content

Cave feature extraction and classification from rockery point clouds acquired with handheld laser scanners


Rockeries are unique elements of Chinese classical gardens with historical, cultural, artistic, and scientific value. One of the essential characteristics of garden rockery is the cave features since cave morphological features determine the degree of “Tou” (riddled through) and “Lou” (hollowed out well) features as the defined by rockery appreciation theory, which is important for rockery heritage conservation, assessment, and management. However, in heritage studies, accurately identifying and evaluating rockery caves is a difficult task because of a cave's irregular shape. This paper proposes a methodology to extract and classify cave features by point clouds obtained from data using a handheld laser scanner with a camera. Without completing surface reconstruction, the rockery point cloud is first sliced into chips, then cave chips were extracted from these approximately two-dimensional chips and next merged to obtain three-dimensional cave point clouds. Finally, the cave boundary points are extracted from the cave and fitted by an ellipse for classification. To extract and classify cave features, a methodology to improve rockery digitalization quality is also proposed. The raw point cloud data were preprocessed by pose adjustment, noise removal, and hole repair. The experimental results for the two rockeries in Tongji University and Qiuxiapu Garden indicate that the improved digitization scheme generates complete and closed rockery point clouds, all types of caves were effectively extracted and classified by our proposed method. Additionally, the extracted caves are still represented by point clouds, which suggest the possibility for other research in the future.


A rockery is a man-made landscape built from only stone or a combination of soil and stone. It is a unique element in Chinese classical gardens [1]. Many gardens on the United Nations Educational, Scientific, and Cultural Organization World Heritage List (, such as the Imperial Palace and the Summer Palace gardens, have a large number of excellent rockery heritage sites. As a stone relic, the rockery is a heritage site with historical, cultural, artistic, and scientific value [2]. Rockeries have cultural and artistic attributes because a large number of literati have connected their noble morality, personal spirit, and perception of life to rockeries [3]. These literati wrote books and established theories to summarize the achievements in rockery appreciation during the process of searching for, evaluating, building, and painting rockery, which improve the aesthetics of rockery and related ceremonies [4]. Therefore, the appreciation and protection of rockery have important historical value.

Among the numerous rockery appreciation theories, Mi Fu’s (1051–1107) theory of "Shou (瘦), Tou (透), Lou (漏), and Zhou (皱)" [5] is widely adopted and accepted, as it concisely summarizes the characteristics of rockeries. In his theory, "Shou" is used to describe the exquisite, slender, and jagged shape of a rockery. "Tou" means that the rockery has caves that are hollow for transmitting light and make the rockery color shiny, mainly considering the caves in the horizontal direction. "Lou" has a similar connotation to "Tou" but mostly describes vertical caves. According to the theory, the cave is an important feature of rockeries since the cave feature determines the degree of "Tou" and "Lou".

Rockery appreciation theory guides rockery construction, and in turn, the characteristics of the rockery embody its connotation. With the vigorous development of digital technology, based on Mi Fu's theory, relying on technology to extract cave features has important value for rockery research. In fact, many studies promoted the scientific appreciation of rockery in various aspects, such as in data acquisition and feature analysis.

An analysis of rockeries could only include photographs [6] or hand drawings [7] until the application of three-dimensional (3D) digital technologies, such as photogrammetry and laser scanning in recent years, which enable rockery research to be based on reliable and accurate data. Gu [8] combined an unmanned aerial vehicle camera and photogrammetry to measure gardens, including rockery, which addressed the inaccurate measurement of irregular objects by using traditional methods. Yu [9] employed Huanxiu Shan Zhuang and Ouyuan Garden as study cases to verify the advantages of stand-type laser scanning and close-range photogrammetry to measure rockery in classical gardens in terms of efficiency, accuracy, comprehensiveness, and continuity. Liang [10] applied terrestrial digital photogrammetry (TDP) and terrestrial laser scanners (TLS) to a single monolith and piled mountain data collection. The TDP and TLS results and procedures for obtaining data were compared in terms of various factors, such as input costs of time and labor, data precision, and integrity. It was indicated that TDP was more suitable for data acquisition of the single monolith for better efficiency and convenience with a good effect and that TLS was more appropriate for the digital survey of the piled mountain for better data integrity and precision. An integrated surveying method with TDP and TLS is an ideal method for acquiring rockery data [11]. The above methods all require a sufficient open workspace for data acquisition; otherwise, the obtained data will be incomplete due to the presence of blind spots in the vision field. However, a rockery is a typical irregular geometric object with a complex shape and is often surrounded by vegetation, walls, pools, and buildings, leading to a lack of data, especially the internal data, which is caused by the mutual occlusion of a rockery’s components.

Compared to the above devices, handheld laser scanners can scan caves in rockeries with a wider scanning range [12] and lower scanning accuracy but shorter scanning time and greater flexibility. To balance the completeness and accuracy of the acquired data, in Huanxiu Shan Zhuang, Dong [13] applied TLS to scan the whole part of a rockery with a supplemented narrow part scanned using a handheld laser scanner, and then fused the two parts of the data together. These studies promoted the continuous improvement of rockery data quality and obtained a few types of results, such as the 3D point cloud model, two-dimensional (2D) line drawings of planes and sections, ortho-photograph maps, and 3D reality-based models of the rockery [14]. These types of results provide a reliable data foundation for modern rockery research.

The increasingly rich and accurate rockery data provide the opportunity to extract rockery features to assist in rockery research. Liu [15] extracted the color of the rockery and used it to prove that the rockery was colored according to the environment and climate adaptability. Yang [16] determined the specific values of the length, width, height, and area from the point cloud of the Grand rockery at the Yuyuan Garden in Shanghai to correct its spatial information, which ensured the reference value of the relevant records. Jiang [17] reconstructed a 3D model of a rockery from a laser point cloud and calculated its surface area. Wang [18] tried various methods to calculate the volume of the rockery from the laser point cloud, further supplementing the method of rockery basic characteristics information calculation. In addition to the calculation of basic features, Liang [19] simulated the relationship between the rockery and the natural mountains and split the rockery model into multiple parts and various components, such as peaks, steps, and bridges.

In general, the above research mainly extracts basic features of rockery, such as length, width, height, surface area and volume, rather than the morphological features of rockeries. This is mainly due to the incomplete data and the lack of feature extraction algorithms from the rockery point clouds. For example, in cave extraction, most rockery digital results lack internal data. Cave extraction algorithms are commonly proposed for ice caves or karstic caves by using laser scanners to study ice morphology caves [20] or gravity measurements to analyze karstic cave volumes and positions [21]. However, these methods are not applicable to rockery caves due to their small size. In terms of point cloud feature extraction methods, the focus is generally on 2D features, such as straight lines [22], building facades [23], and object edges [24]. Regarding deep learning methods, while deep learning on the 3D point cloud has shown good performance on several tasks, including classification, parts, and semantic segmentation [25], due to the lack of rockery cave feature datasets, it is unable to train a network for cave feature extraction. In short, none of these current solutions can extract the cave features in rockery point clouds because caves are 3D irregular objects.

Based on the short part of both data and algorithms for rockery feature extraction and classification, the research aims of this paper are as follows:

  1. 1.

    Taking a single monolith as the experimental object, the procedure of rockery data acquisition and preprocessing is improved to achieve complete digitalization of internal and external data.

  2. 2.

    Based on the rockery aesthetic theory, an algorithm is designed to extract and classify the cave features from the high-density rockery 3D point cloud without modeling.

Materials and methods

Data acquisition and preprocessing for rockery

Data acquisition

The rockery is irregular in shape and rich in morphological features, and most of the environments where rockery is located do not have an open space for operation. Therefore, when applying traditional photogrammetry and stand-type laser scanning methods to collect data, difficulties usually occur, as some surfaces and interiors of rockeries cannot be covered. Thus, in this paper, a handheld mobile laser scanning device (DOT-X) is used to collect data on rockery. DOT-X consists of a depth camera, a laser scanner, and a mobile data processing platform that run on a smartphone or tablet (Fig. 1a). With the camera output of the 1920 × 1080 resolution RGB image, the laser scanner adopts a stereo imaging mode that actively emits infrared light at a rate of 90 frames per second. The mobile data processing platform performs real-time point cloud registration and image matching during the data acquisition process, causing DOT-X to output real-time color point clouds with a field angle of 360° and a working distance ranging from 0.3 to 10 m.

Fig. 1
figure 1

DOT-X handheld laser scanner (a) and usage. b A rockery and a scan path

As the handheld scanner was very close to the rockery, only a small part of the rockery was scanned each time. Consequently, to collect the complete data, the scanner must be repeatedly moved around the rockery until the entire rockery has been covered (Fig. 1b). Auxiliary equipment is also required for scanning some special rockery parts, such as the increasing equipment for the peaks and the lighting equipment for the dark caves.

Data preprocessing

The cave extraction and classification require closed point clouds with complete internal and external components, so it is necessary to preprocess the raw data. Preprocessing rockery raw data mainly includes three steps: pose adjustment, noise removal, and hole repair. These are the basic operations for cave extraction and classification, which directly affect the accuracy of the final result.

The cave feature is almost concentrated along the viewing angle direction and the vertical direction in the rockery. To facilitate the determination of the slice direction and the cluster growth of the cave feature, it is necessary to adjust the pose of the rockery point cloud. The vertical direction of the rockery should be consistent with the Z-axis, and the viewing angle direction should be consistent with the X-axis or Y-axis. The raw point cloud pose is shown in Fig. 2a, and the adjusted pose is shown in Fig. 2b.

Fig. 2
figure 2

Preprocessing procedure. a Raw point cloud. b After pose adjustment. c Noise selection (red). d After removing noise. e Mesh (blue) and holes (green). f Close and complete point clouds

In the raw rockery point clouds, there are two types of obvious noise that need to be removed (Fig. 2c). One type of noise is the collected non-rockery data, such as vegetation. Another type of noise is the data dissection due to automatic registration errors.

Due to the inability to collect all internal data and some noise points being removed, the rockery point cloud had many holes (Fig. 2e) that needed to be manually repaired by the Geomagic Wrap software. The surface holes need to be filled, and the incomplete internal caves need to be connected to another cave according to the rockery image and the video taken on the spot; otherwise, the morphological contour will be incomplete in the sliced chips [18], which will lead to cave feature extraction failure.

The data preprocessing was achieved using Geomagic Wrap software. Finally, complete rockery shell-like point clouds were obtained (Fig. 2f).

Cave feature extraction and classification method

Workflow of the proposed method

Point cloud feature extraction methods are generally divided into two categories [26]. The first category finds feature points based on the topological relationship of point clouds in 3D space, which require a huge amount of computation when faced with massive data. Another category converts the point cloud into a 2D plane after projecting or slicing so that the point cloud becomes approximately ordered and then extracts features from it. The cave feature extraction algorithm in this paper belongs to the second category. However, the classification of caves depends on 3D features, such as orientation and opening boundaries. Therefore, a method for cave feature extraction and classification that undergoes 3D-2D-3D is designed, including collection in 3D, extraction in 2D, and then classification in 3D.

Figure 3 depicts a detailed workflow of cave feature extraction and classification, which is based on the following steps that work along the X-axis, Y-axis, and Z-axis:

  1. 1.

    Slice rockery point clouds to chips, extract caves from chips, and then merge and split them to obtain individual caves.

  2. 2.

    Extract features of cave point clouds and then classify caves into four categories.

Fig. 3
figure 3

Workflow of cave feature extraction and classification

Details of each step will be presented in the next sections.

Cave feature extraction

It is difficult to directly extract caves based on 3D rockery point clouds. Therefore, this paper proposes a cave point cloud extraction method from multidirectional chips. This method includes five steps: slicing, grouping, extracting, merging, and splitting.

The first step is slicing, which turns the rockery point clouds into multiple approximately 2D point cloud chips along the X-axis, Y-axis, and Z-axis (Fig. 4). The essence of the slice is calculating the three axes chip numbers of each point that is relative to the base point, and the points with the same number are assigned to the same chip [27]. The calculation formula is written in Eq. (1) as follows:

$$\left\{\begin{array}{c}{num}_{X}=int(\frac{x-{x}_{min}}{dx})\\ {num}_{Y}=int(\frac{y-{y}_{min}}{dy})\\ {num}_{Z}=int(\frac{z-{z}_{min}}{dz})\end{array}\right.$$

where \(x,y,z\) are the current point coordinates in rockery point clouds, \({x}_{min},{y}_{min},{z}_{min}\) are the minimum \(x,y,z\) coordinates of all points, \({d}_{x},{d}_{y},{d}_{z}\) denotes the slicing threshold of the corresponding axis, \(int\) is the rounding down function, and \({num}_{x},{num}_{y},{num}_{z}\) are chip numbers for the corresponding axis.

Fig. 4
figure 4

Slice rockery point clouds (gray) along the X-axis (green), the Y-axis (blue) and the Z-axis (red)

Then, the caves in each chip are extracted by grouping and inclusion discrimination. The rockery chip is not a real 2D object; it is a point cloud chip with a certain thickness, and the point belt is not enclosed but composed of discrete points (Fig. 5a). Therefore, point belt grouping and inclusion discrimination need to be done through the topological relationship of the points. In this paper, the point topology relationship is constructed by generating buffers (Fig. 5b).

Fig. 5
figure 5

Extracting caves in a chip. a Point clouds’ chip. b Buffer of points (red). c Point clouds’ belts (different color means different belt). d Inclusion discrimination diagram. e Caves in the chip

The points of the chip are grouped by generating a cube buffer with a threshold side length for each point (Fig. 5b) and then dashing the points into a point belt (Fig. 5c) if they have intersecting buffers. In a chip, the caves are inclusive belts similar to the blue, green, and purple parts shown in Fig. 5c. The method of inclusion discrimination is that if there is a belt point that has more than one intersection point with another belt through extension lines in the up, down, left, and right directions, this belt is included in another belt (Fig. 5d), i.e., this belt is a cave belt (Fig. 5e). The intersection of two points means is that one point within the ray buffer is generated by the other point (Fig. 5d).

Finally, the 3D caves are restored by merging the extracted caves of all chips in the current axis (Fig. 6a). Next, all the caves are a set of point clouds and need to be split to generate individual cave point clouds (Fig. 6b). The splitting method is the same as grouping point clouds in the chip.

Fig. 6
figure 6

Merged caves parts from all chips (a different color means different chip) and individual caves’ point clouds (b different color means different cave)

Cave feature classification

According to the traditional Chinese rockery appreciation standards, the caves are divided into four categories: Wo, Xiu, Dong, and Huan. Cave classification refers to the direction of the cave and the shape of the opening, as shown in Fig. 7. "Wo" refers to a nonhollow cave in the vertical direction, and "Xiu" refers to a nonhollow cave in the horizontal direction. "Dong" means a hollow cave whose opening has a poor fit with an ellipse, and "Huan" means a hollow cave whose opening has a good fit with an ellipse.

Fig. 7
figure 7

Four types of cave features. a Wo. b Xiu. c Dong. d Huan

To obtain the cave direction and cave opening shape for classification, the axial direction is selected as the cave direction, and the cave boundary is used to represent the opening. Then, a decision tree (Fig. 8) for cave classification is designed according to cave direction and cave opening shapes. First, a preliminary classification of the point sets generated in "Cave feature extraction" section is established. The point sets whose number of points or axial thickness is less than a certain threshold are regarded as noise point sets, and the other point sets are caves. Then, the caves were classified according to the cave boundary number, cave orientation, and goodness of fit. Specifically, the caves with two boundaries or more are classified as "Dong" or "Huan" depending on whether they are fitting or not fitting with the ellipse, and the caves with only one boundary are classified as "Wo" or "Xiu", depending on whether they are in a vertical or horizontal orientation.

Fig. 8
figure 8

The decision tree for cave classification

The required axial direction can directly reference the current axis, but the cave boundary needs to be extracted from cave point clouds. For this purpose, a surface mesh of caves is needed. For applying the reconstruction and repairing method [28] to cave points (Fig. 9a), the cave mesh is shown in Fig. 9b. In a mesh without holes, the points that constitute the boundaries of the caves have distinct characteristics; they are the two vertices of the edge which only belong to one triangle face. When accomplishing boundary point extraction, we can directly group and order them clockwise or counterclockwise by connecting relationships in the mesh.

Fig. 9
figure 9

Extracting boundary points and fitting them into an ellipse. a Points. b 3D mesh and boundary (red). c Boundary points. d Best fitting ellipse

The final quantitative feature of cave classification is how well the cave boundary points fit the ellipse. After extracting, grouping, and ordering the cave boundary points, they are projected onto the axial plane and then fit into an ellipse (Fig. 9d) with Eq. (2) to determine whether the cave is a “Dong” or a “Huan” according to the fitting error. Finally, Eq. (3) and Eq. (4) are used to calculate the area and perimeter of the cave boundary points as their quantitative features as follows:


where \(\left( {x_{i} ,y_{i} } \right)\left( {i = 1,2,3\,...\,n} \right)\) are the projection plane coordinates of a cave boundary point,

\(\mathrm{x}\) is the column vector and \(\,{\text{x}}\,{ = }\,\left( {x_{i} } \right)^{T} \left( {i = 1,2,3\,...\,n} \right)\),

\(\mathrm{y}\) is the column vector and \({\text{y}}\,{ = }\left( {y_{i} } \right)^{T} \left( {i = 1,2,3\,...\,n} \right)\),

\(a,\mathrm{b},\mathrm{c},\mathrm{d},\mathrm{e},\mathrm{f}\) are the coefficients of the ellipse equation,

\(S\) is the area value of a cave boundary,

\(\mathrm{C}\) is the perimeter value of a cave boundary.

Case area

Two single monoliths with many caves were selected as study cases from Tongji University’s Siping Road Campus and Qiuxiapu Garden, Shanghai, China. Tongji University’s Siping Road campus is located in Yangpu District, Shanghai. It was established in approximately 1946 and has many good cultural landscape resources [29]. Qiuxiapu Garden is located in Jiading District, Shanghai. It is a typical Chinese classical garden built in the Jiajing years (1522–1566) of the Ming Dynasty with excellent rockery design [30]. The rockeries selected from these two places are named "Tongji Rockery" and "Qiuxia Rockery". It can be seen in Fig. 10 and Table 1 that the size and shape of the two rockeries are quite different. The size of Tongji Rockery is 2.994 m, 1.692 m, and 2.352 m. It is a horizontally expanded rockery, covering an area of 3.312 m2. There are many caves but few hollow parts, so the volume is 2.259 m3. In contrast, Qiuxia Rockery is a vertically expanded rockery. The sizes are 1.091 m, 0.906 m, and 1.455 m, and the coverage area is 0.321 m2. There are few caves but many hollow parts in it, so the volume is only 0.229 m3. The caves of these two rockeries with different shapes are representative and suitable study cases.

Fig. 10
figure 10

Shots of Tongji Rockery (a) and Qiuxia Rockery (b)

Table 1 Basic information for Tongji Rockery and Qiuxia Rockery

Experimental results and analysis

Data acquisition and preprocessing result

Data acquisition for both rockeries was conducted using DOT-X in October 2019 and January 2021. The data characteristics of these two rockeries are shown in Table 2. After approximately 5 min and 3 min of data acquisition, the volume of laser scanning raw data for Tongji Rockery and Qiuxia Rockery was more than 35 million and 19 million points, respectively. Both of these rockeries point clouds were downsampled before preprocessing according to an acceptable compromise between the level of detail of the final caves and the computing resources needed for data processing. Since there are many small components inside the Qiuxia Rockery, it took approximately 72 h for data preprocessing. The Tongji Rockery preprocessing with simple internal components took approximately 48 h. Figures 11 and 12 show that the two rockeries have been digitized well, and the internal caves have also been completely restored. The preprocessed point cloud counts of the two rockeries are approximately 1.25 million and 1.54 million, which can be regarded as high-density point clouds with volumes of 2.259 m3 and 0.229 m3. These data are the basis for subsequent cave feature extraction and classification.

Table 2 Data characteristics for Tongji Rockery and Qiuxia Rockery
Fig. 11
figure 11

Digitized Tongji Rockery. a Point cloud data collected by DOT-X handheld laser scanner. b Preprocessed point clouds

Fig. 12
figure 12

Digitized Qiuxia Rockery. a Point clouds data collected by DOT-X handheld laser scanner. b Preprocessed point clouds

Cave feature extraction result

The slicing threshold and buffer length threshold need to be determined during cave feature extraction. According to the density of the point cloud in this study, the thickness of all axial chips is set to 10 mm, that is, \({d}_{x},{d}_{y},{d}_{z}\) in Eq. (1) are assigned a value of 10. Then, the buffer length threshold for point grouping and point intersection discrimination is set to 10 mm according to the point cloud density and slicing threshold. Under these threshold settings, the extracted caves in some Tongji Rockery chips are shown in Fig. 13, and the extracted caves in the two rockeries are shown in Fig. 14.

Fig. 13
figure 13

Result of the cave feature extraction in the chip for Tongji Rockery X-axis (a, d), the Y-axis (b, e) and Z-axis (c, f)

Fig. 14
figure 14

Result of the cave feature extraction for Tongji Rockery (a, b) and Qiuxia Rockery (c, d)

The cave feature classification result

In the process of cave feature classification, considering the density of rockery point clouds and the shape of the caves, a sufficient point count threshold of the cave feature is set to 450, and a sufficient thickness threshold of caves is set to 25 mm. The findings of 90 noise point sets and 41 pure caves from Tongji Rockery are shown in Fig. 15a and  b. The findings of 32 noise point sets and 19 pure caves from Qiuxia Rockery are shown in Fig. 15c and d.

Fig. 15
figure 15

Noise points sets (a, c) and pure caves (b, d)

The 41 pure caves of Tongji Rockery were classified into 19 nonhollow caves and 22 hollow caves according to the count of boundaries. The 19 nonhollow caves were divided into 7 "Wo" and 12 "Xiu" according to the axial direction set in the pose adjustment step of data preprocessing, as shown in Fig. 16a and b, respectively. For the 22 hollow caves, based on the boundary point data, the ellipse fitting error was calculated with Eq. (2). The cave with all boundary point fitting errors less than 0.20 or the cave that has two boundaries and one boundary fitting error less than 0.15 was classified as "Huan". Thus, we obtained 10 "Dong" and 12 "Huan", as shown in Fig. 16c and  d. Under the same conditions, the 19 pure caves of Qiuxia Rockery are classified, and the count of "Wo, Xiu, Dong, and Huan" is "1, 3, 14, and 1" (as shown in Fig. 17).

Fig. 16
figure 16figure 16

The cave feature classification result of Tongji Rockery. a Wo. b Xiu. c Dong. d Huan

Fig. 17
figure 17

The cave feature classification result of Qiuxia Rockery. a Dong. b Wo, Xiu and Huan

To quantitatively analyze the cave feature extraction and classification algorithm effect, the thickness, opening perimeter, and opening area of all caves in the two rockeries were calculated using Eq. (3) and Eq. (4). The resulting data characteristics are shown in Table 3 and Table 4. The extracted caves have a wide range of data characteristics. The cave thickness ranges from 27 mm (Fig. 17b-1) to 1070 mm (Fig. 16c-10), the opening perimeter ranges from 98 mm (Fig. 17c-14) to 3440 mm (Fig. 16c-7), and the opening area ranges from 144 mm2 (Fig. 17c-6) to 277,891 mm2 (Fig. 16c-7). This type of granular data are a good data source for downstream analysis tasks.

Table 3 Data characteristics of all caves of Tongji Rockery (numbers in parentheses correspond to the subplots in Fig. 16)
Table 4 Data characteristics of all caves in Qiuxia Rockery (numbers in parentheses correspond to the subplots in Fig. 17)

Analysis and discussion

To assess the accuracy and integrity of the caves extracted by our proposed method, all caves in Tongji Rockery and Qiuxia Rockery were extracted manually as the actual caves (Fig. 18 gray points). Then, the results extracted by our proposed method (Fig. 18 blue and yellow) are compared with the manual results.

Fig. 18
figure 18

Manually and algorithm extracted caves of Tongji Rockery (a) and Qiuxia Rockery (b)

Since the most important factor affecting the algorithm extraction results is the slicing threshold, multiple slicing thresholds around the point cloud density (average point distance) were set to repeat the cave extraction and assessment experiment. For the Tongji Rockery with a 7.0 mm point cloud density, slicing thresholds were set from 5 to 13 mm in steps of 1 mm. For the Qiuxia Rockery with a 2.9 mm point cloud density, slicing thresholds were set from 3 to 9 mm in steps of 1 mm.

Accuracy analysis

With an inappropriate slicing threshold, the extracted cave will include some non-cave parts (Fig. 19). To assess the accuracy, Eq. (5) is used as follows:

Fig. 19
figure 19

Cave with non-cave parts (additional perspectives of Fig. 16c-7)

$${p}_{average accuracy}=\frac{{count(X}_{overlap})}{{count(X}_{algorithm})}$$

where \({X}_{overlap}\) is the point set composed of the points that are both in the algorithm extracted caves and the manually extracted caves, \({X}_{algorithm}\) is the point set of algorithm extracted caves, \(count\) is the count function, and \({p}_{average accuracy}\) is the percentage of the average accuracy.

The average accuracies of Tongji Rockery and Qiuxia Rockery with different slicing thresholds are shown in Fig. 20. The 5 mm and 6 mm slicing threshold average accuracies of Tongji Rockery in Fig. 20 show that a slicing threshold smaller than the point cloud density will lead to lower average accuracy. The other results in Fig. 20 indicate that a slicing threshold greater than or equal to the point cloud density leads to a higher average accuracy. However, a slicing threshold that is too large reduces the cave extraction integrity.

Fig. 20
figure 20

Average accuracy corresponding to different slicing thresholds

Integrity analysis

Since cave extraction is performed along the coordinate axis, only the cave in closed area can be correctly extracted (Fig. 21 left). Usually, the closed area is composed of the parts of the cave that can form a closed point cloud belt in the current axis chips. Therefore, the algorithm extracted caves are almost all less than the actual caves. In the case of a large slicing threshold, the extracted cave is even smaller than the closed area (Fig. 21 right).

Fig. 21
figure 21

Cave with missing cave portion (additional perspectives of Fig. 16d and 16d)

To assess the integrity of the algorithm extracted cave, Eq. (6) is used as follows:

$${p}_{average integrity}=\frac{{count(X}_{overlap})}{{count(X}_{manual})}$$

where \({X}_{overlap}\) is the point set composed of the points that are both in the algorithm extracted caves and in the manually extracted caves, \({X}_{manual}\) is the point set of manually extracted caves, \(count\) is the count function, and \({p}_{average integrity}\) is the percentage of the average integrity.

As shown in Fig. 22, within a certain range, a smaller slicing threshold will lead to higher average integrity. Sensitivity studies of slicing have also shown that reducing the slicing threshold will achieve more desirable results [31]. However, the slicing threshold cannot be reduced indefinitely because a chip that is too thin will cause grouping failure due to a large point distance (Fig. 23b) and eventually lead to cave extraction failure. That is, the slicing threshold needs to ensure the continuity of the chip point clouds (Fig. 23a).

Fig. 22
figure 22

Average integrity corresponding to different slicing thresholds

Fig. 23
figure 23

Point cloud continuity for 10 mm (a) and 2 mm(b) slicing threshold

When the chip point cloud contiguity is low (Fig. 23b), cave extraction can still be performed by increasing the grouping buffer length threshold. However, a grouping buffer length threshold that is too large leads to disruption of cave extraction and causes the cave’s number to be greater than the actual number. For example, caves c-2, c-3, c-4, c-5, c-6, and c-7 in Fig. 17a all come from the same cave, but regardless of the X-axis, Y-axis, or Z-axis extraction results, the complete cave is divided into two caves (Fig. 24).

Fig. 24
figure 24

Incomplete cave along the X-axis (b), the Y-axis (c) and Z-axis (d) and the compound caves (a) of b, c and d

The reason for this is that a chip was wrongly grouped. As shown in Fig. 25, the closest distance between the cave point belt and the outermost belt is less than the threshold for grouping (10 mm), so the cave belt and the outermost belt are grouped into one, which eventually leads to cave extraction failure.

Fig. 25
figure 25

Wrong grouping (b, c) caused by a too large grouping buffer threshold (10 mm) leads to losing part of the cave (a)

In summary, to ensure the success of cave extraction and high integrity, the slicing threshold and the grouping buffer threshold should preferably be set slightly larger than the point cloud density.


To provide support data for modern rockery research, the study attempts to extract and classify the important morphological features in the rockery, that is, the cave features. Therefore, a set of rockery digitization schemes is improved, and the cave feature extraction and classification algorithm is proposed.

In the rockery digitization stage, various digitization schemes were analyzed, and it was found that most schemes only collected surface point cloud data for a specific angle. To improve this situation, the DOT-X handheld scanner combining photogrammetry and laser scanners was used to collect data around the rockery, and then the raw point cloud data were preprocessed by pose adjustment, noise removal, and hole repair to generate high-density complete point clouds.

In the cave extraction and classification stage, the 3D rockery was reduced to many approximate 2D chips by slicing, the caves were extracted from these chips, and then the caves from all chips merged to restore the 3D caves’ point clouds; afterwards, they were split to generate individual caves. Furthermore, features, such as the cave point count, thickness, boundary points, and direction are extracted to divide them into four categories: "Wo, Xiu, Dong, and Huan".

The experiment applied to two rockeries with abundant caves that verified the effectiveness of the digitization scheme, the cave feature extraction and the classification algorithm. After calculating the data characteristic of the extracted caves, we found that the data characteristic range is very wide, which is very helpful for downstream analysis tasks, such as rockery beauty analysis and evaluation [32]. In addition, the extracted and classified caves are still in point cloud data form, allowing the possibility for future study and application. For example, a future study may involve creating multiscale rockery digital twins with extracted caves or 3D printing caves to activate, restore, and protect rockeries [13], as the physical 3D model presented is visually attractive and allows for a better understanding of the heritage values [33]. Finally, the influence of the thresholds set in the experiment on the results was also analyzed, which provides ideas for future improvement. The current shortcoming is that axial selection leads to low cave extraction integrity. In future research, we will explore the possibility of extracting caves from more angle axes.

Availability of data and materials

The dataset used and analyzed in this article is available in hyperlink





Terrestrial digital photogrammetry


Terrestrial laser scanners




  1. Fu-ming B. Analysis and appreciation of rockery in Suzhou Gardens. Chin Landsc Archit. 2013;29(2):100–4 (in Chinese).

    Google Scholar 

  2. Hatır ME. Determining the weathering classification of stone cultural heritage via the analytic hierarchy process and fuzzy inference system. J Cult Herit. 2020;44:120–34.

    Article  Google Scholar 

  3. Egan R. The Problem of Beauty: Aesthetic Thought and Pursuits in Northern Song Dynasty China. Cambridge: Harvard University Asia Center Publications Program; 2006. p. 219–26.

    Book  Google Scholar 

  4. Ming X. Yunlin Stone collection and the tastes in appreciating stones by the Literati in the Song Dynasty. El Paso: Southwest University; 2018. p. 15–7 (in Chinese).

    Google Scholar 

  5. Gu L. History and conservation of rockwork in gardens of Imperial China. Sheffield: University of Sheffield; 2018. p. 86–8.

    Google Scholar 

  6. Xu P. An interdisciplinary study: Rock worship in Chinese classical gardens. Int J Arts Sci. 2014;7(5):547–58.

    Google Scholar 

  7. Zheng J. Art and the Shift in Garden Culture in the Jiangnan Area in China (16th-17th Century). Asian Cult History. 2013;5(2):1.

    Article  CAS  Google Scholar 

  8. Liyuan G, Xinren G, Woudstra J. The Application of digital 3D technology in garden surveys: rockwork as a case study. Archit J. 2016;S1:35–40 (in Chinese with English abstract).

    Google Scholar 

  9. Mengzhe Y, Xi L. Study on the surveying methods based upon the 3D laser scanning and close-range photogrammetry techniques of the rockery and pond in the classical Chinese gardens. Landsc Archit. 2017;2:117–22. (in Chinese with English abstract).

    Article  Google Scholar 

  10. Liang H, Li W, Lai S, Jiang W, Zhu L, Zhang Q. How to survey, model, and measure rockeries in a Chinese classical garden: a case study for Huanxiu Shanzhuang, Suzhou China. Landsc Res. 2020;45(3):377–91.

    Article  Google Scholar 

  11. Liang H, Zhang Q. A review of three-dimensional digital surveying and information management for garden cultural heritages. J Nanjing For Univ (Natural Sciences Edition). 2020;44(5):9–16. (in Chinese with English abstract).

    Article  Google Scholar 

  12. Giannetti F, Puletti N, Quatrini V, Travaglini D, Bottalico F, Corona P, et al. Integrating terrestrial and airborne laser scanning for the assessment of single-tree attributes in Mediterranean forest stands. Eur J Remote Sens. 2018;51(1):795–807.

    Article  Google Scholar 

  13. Dong Q, Zhang Q, Zhu L. 3D scanning, modeling, and printing of Chinese classical garden rockeries: Zhanyuan’s South Rockery. Herit Sci. 2020;8(1):61.

    Article  Google Scholar 

  14. Zhang Q, Liang H, Li W, Yang M, Zhu L, Huang A. Research of the application of digital survey techniques in private garden. J Nanjing For Univ (Natural Sciences Edition). 2018;42:1–5. (in Chinese with English abstract).

    Article  CAS  Google Scholar 

  15. Jinfang L, Bo Z, Ping A. The color analysis of the mountain of Chinese classical gardens in Beijing. Yuanmingyuan Academic J; 2016. p. 191–6. (in Chinese)

  16. Chen Y, Feng H. Digital heritage landscape: Research on spatial character of the grand rockery of Yuyuan Garden in Shanghai based on 3D Point Cloud technologies. Chin Landsc Archit. 2018;34(11):20–4 (in Chinese with English abstract).

    Google Scholar 

  17. Yun J, Yijin C. Application of 3D laser scanning technology in calculation of rock sculpture surface area. Geotech Invest Surv. 2019;47(4):66–9 (in Chinese).

    Google Scholar 

  18. Wang Y, Ding M, Zhang Q, Qu Z, Zhang X, Zhang R, et al. The Volume calculation methods of irregular stone artifacts based on 3d laser scanning technology: a case on the rockery in the humble administrator’s garden. SSRN Electron J. 2022.

    Article  Google Scholar 

  19. Liang H, Li W, Zhang Q. Semantic-based 3D information modelling and documentation of rockeries in Chinese classical gardens: a case study on the rockery at Huanxiu Shanzhuang, Suzhou China. J Cult Herit. 2019;37:247–58.

    Article  Google Scholar 

  20. Gómez-Lende M, Sánchez-Fernández M. Cryomorphological topographies in the study of ice caves. Geosciences. 2018;8(8):274.

    Article  Google Scholar 

  21. Braitenberg C, Sampietro D, Pivetta T, Zuliani D, Barbagallo A, Fabris P, et al. Gravity for detecting caves: airborne and terrestrial simulations based on a comprehensive karstic cave benchmark. Pure Appl Geophys. 2016;173(4):1243–64.

    Article  Google Scholar 

  22. Alshawabkeh Y. Linear feature extraction from point cloud using color information. Herit Sci. 2020;8(1):28.

    Article  CAS  Google Scholar 

  23. Wang Y, Ma Y, Ax Zhu, Zhao H, Liao L. Accurate facade feature extraction method for buildings from three-dimensional point cloud data considering structural information. ISPRS J Photogramm Remote Sens. 2018;139:146–53.

    Article  CAS  Google Scholar 

  24. Wang Y, Ewert D, Schilberg D, Jeschke S. Edge extraction by merging 3D point cloud and 2D image data. 2013 10th International Conference and Expo on Emerging Technologies for a Smarter World (CEWIT); 2013. p. 1–6.

  25. Bello SA, Yu S, Wang C, Adam JM, Li J. Review: deep learning on 3D point clouds. Remote Sens. 2020;12(11):1729.

    Article  Google Scholar 

  26. Bowen D, Zhaoba W, Yong J, Youxing C, Qizhou W, Haiyang L. Feature extraction method of laser scanning point cloud based on morphological gradient. Laser Optoelectron Progress. 2018;55(5):239–45. (in Chinese with English abstract).

    Article  Google Scholar 

  27. Jintao L, Xiaojun C. Straight-Line-Segment Feature-Extraction method for building-facade point-cloud data. Chin J Lasers. 2019;46(11):287–98. (in Chinese with English abstract).

    Article  Google Scholar 

  28. Hoppe H, DeRose T, Duchamp T, McDonald J, Stuetzle W. Surface reconstruction from unorganized points. Proc 19th Annu Conference Comput Graph Interact Tech: Association Computer Machinery. 1992;26:71–8.

    Google Scholar 

  29. Tianren Y, Jian C. The investigation and evaluation of resources in Campus Human Landscape——Tongji University as an example. Chin Soc Landsc Archit CHSLA Annual Meeting. 2014;2014:183–9 (in Chinese).

    Google Scholar 

  30. Congzhou C. Qiuxiapu Garden in Jiading and Anlan Garden in Haining. Cultural Relics. 1963;2:39–48 (in Chinese).

    Google Scholar 

  31. Zolanvari SMI, Laefer DF, Natanzi AS. Three-dimensional building façade segmentation and opening area detection from point clouds. ISPRS J Photogramm Remote Sens. 2018;143:134–49.

    Article  Google Scholar 

  32. Long F, Shao-Cai LI, Sun HL, Yang LX. Analysis and evaluation of the structural elements of rockery beauty in Chinese Gardens. J Southwest Univ (Natural Science Edition). 2008;30(8):147–54 (in Chinese with English abstract).

    Google Scholar 

  33. Wabiński J, Mościcka A. Natural heritage reconstruction using full-color 3D Printing: a case study of the valley of five polish ponds. Sustainability. 2019;11(21):5907.

    Article  Google Scholar 

Download references


Not applicable.


National Science Foundation of China (No. 42271429) and the Fundamental Research Funds for the Central Universities of China.

Author information

Authors and Affiliations



LL and HW contributed to the concept of the study. CW collected and performed the experiments. CW, HW and LL performed the analysis. CW wrote the manuscript. HW, LL and CY improved the manuscript. CY also helped perform the analysis with constructive discussions. All authors read and approved the final manuscript.

Corresponding author

Correspondence to Hangbin Wu.

Ethics declarations

Competing interests

The authors declare that they have no competing interests.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit The Creative Commons Public Domain Dedication waiver ( applies to the data made available in this article, unless otherwise stated in a credit line to the data.

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Lou, L., Wei, C., Wu, H. et al. Cave feature extraction and classification from rockery point clouds acquired with handheld laser scanners. Herit Sci 10, 177 (2022).

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI:


  • Rockery
  • Point clouds
  • Cave feature
  • Extraction
  • Classification