A new workflow for the automated measurement of shape descriptors of rocks

Shape properties of rocks carry important geological information about their origin, and they may also provide a window to study the abrasion processes forming their geometry. The number of mechanical equilibria is a significant property with a profound mathematical background that could reveal the secrets hidden in the artifacts of Nature. Although it is easy to count by hand, the automation of its measurement is not a straightforward task. A new workflow is introduced for the fast and efficient measurement of geometrical properties, including the number and location of stable and unstable equilibrium points 5 of rocks based on a portable 3D scanner combined with computer software that can analyze the resulting point cloud. The technique allows for the fast examination of statistically sufficient sample sizes without the need for transportation or storage of the specimens. A previously hand-measured set of pebbles and fragments was used as a reference for the validation of the method, and its effectiveness is demonstrated through the examination of beach pebbles carried out in Kawakawa Bay, New Zealand. 10

devoted to the validation of the technique on a reference set of specimens that were previously analyzed by hand-measurements.
In Sect. 4, we illustrate the robustness of the method in a field-measurements at the Kawakawa Bay, New Zealand. Finally, we summarize our results in Sect. 5.
2 New method 2.1 3D scanning 60 The scanning of three-dimensional objects requires the visibility of the entire surface of the object. In case of former geometry reconstruction techniques, a series of photos or partial scans need to be performed of the pebbles placed on flat surfaces from different angles before the assembly of the final geometry. Unfortunately, the merging procedure is not straightforward and usually has to be done manually, which is often extremely time-consuming due to the removal of the undesired surfaces attached to the pebble geometry. Moreover, it is often a problem that most of the handheld scanners suffer from issues when recording small objects and easily lose the track of pebbles under a certain size. Our aim was to elaborate a scanning technique, which allows the uninterrupted scanning of pebbles resulting in a seamless geometry without the need of any manual postprocessing.
One of the most crucial aspect of such a scanning technique is how the pebble should be fixed in space without even a small parcel of its surface being covered by the holder. To overcome this problem, we constructed a holder of two 0.25 × 0.25 m frames shown in Fig. 1 with tight webs. As long as the strings forming the webs are thin enough to be invisible for the scanner 70 device, the frames manage to hold the pebble stationary leaving plenty of space for the observer to scan each sides.
In order to avoid the scanner to be rotated around the frame, we designed the assembly so that it can be rotated smoothly on a tripod. After fixing the pebble in the frame, the scanning can be performed in one continuous session using the scanner Structure Sensor Mark I. Since the scanner is quite compact, one can hold it by hand during the entire scanning. However, focusing on reproducibility, the results shown in the present work have been obtained using a camera crane fixed on another 75 tripod. The complete layout of the two tripods with the rotating frame and the crane is presented in Fig. 1.
It is crucial for the scanner to never lose the track of the pebble during the scanning process, hence the crane is designed to move the scanner in such a way that the pebble always remains in the center of the view regardless of the crane angle. As Fig. 2 shows, the scanner defines a scanning domain in which it generates the geometry based on the distance field, while everything outside the domain is completely ignored. After the scanning process is initiated, it is essential for the successful scanning to 80 never let the domain out of the sight of the scanner. Since the scanner does not have built-in gyroscope or accelerometer, it computes its relative spatial position and orientation merely based on the recorded three-dimensional point cloud. Therefore, in order to facilitate a robust and accurate orientation, we placed four spherical foam balls over the frames providing sufficiently large reference surfaces for the orientation regardless of the pebble size. Lacking of global reference points, the domain is automatically attached to the rotating frames. The scanning starts at the upper position of the crane, and after a full 360-degree 85 rotation of the specimen, the crane is moved to the bottom position, which is followed by a second 360-degree turn of the specimen. This method ensures that every side of the specimen is captured. The scanner is connected to a computer running Skanect Pro recording the geometry.

Foam balls as reference surfaces Web
Rotating head Specimen Scanner a.
b.  Finally, the geometry containing the specimen and its surroundings with the frame of the web and the reference spheres are exported to stereolithography format. Since the web remains invisible, the pebble geometry is independent of its surroundings, 90 the pebble can be easily extracted using a CAD software (e.g. Blender). Automation of this step is a possible development in the future. The preview and the final geometry are shown in Fig. 3.
With this procedure, one pebble can be scanned under two minutes, and the postprocessing takes up less than a minute. The new scanning technique is compared to the existing methods in Table 1. Although the proposed method defeats the existing methods in portability, speed, and price, the quality of the final point cloud is expected to be lower compared with a fixed laser 95 scanner. However, we expect exponential progress on the development of 3D scanners.

Automated shape analysis
The scanning process results in individual .stl geometries of each specimen. The software, based on the algorithm of Ludmány and Domokos (2018), can handle input in Object File Format (OFF) or STereoLitography (STL) format. It is available in Lud- 3D from 2D photos x slow (40-200 images) slow (1 hour) cheap Tomasi and Kanade (1992) CT, X-ray -slow (7 particle/day) fast very expensive Deiros Quintanilla et al.
proposed method x fast (2 min) fast (1 min) cheap Table 1. Comparison of the existing techniques and the proposed method in terms of portability, recording and postprocessing speed, and price. mány (2020b). It was showed in Domokos et al. (2011b, a), that artificial equilibrium points can appear due to the polyhedral 100 approximation of the surface, and the equilibrium points of the physical object correspond to the convex hull of the point cloud. As a result, the surfaces with faces contained in the input files are ignored, and a triangulated convex hull of the points is constructed right away.
The algorithm calculates level sets of the convex hull and represents the body by M contour lines enclosing points lying at least a distance s i from an arbitrary internal reference point, which is the centroid by default (Fig. 4). The equilibrium points 105 are closed contour lines containing no other contour lines having a larger area than ρ percent of the total surface area. This restriction provides a smoothing of the surface to avoid the effects of the polyhedral approximation of the smooth body. Both The computer program presented here is merely a user-friendly graphical interface on top of the algorithm, which is separated in a function library available in Ludmány (2020a). It does not require the point cloud to be in a .off or a .stl format.
Consequently, this technology can be easily integrated into any other application. check the scanning quality since they are independent of the input parameters and cannot be improved. From S and U , the latter is less straightforward to measure and cannot be treated with equal importance. As a result, we fitted the input parameters to the measured number of stable equilibrium points and expected higher difference for U . We defined two error norms: where e S , e U are the average of the errors specimen by specimen and eS, eŪ are the errors of the average for a set of N pebbles.
For statistical analysis, the average error is more relevant.
6 different sets of pebbles (A1, C1, K1, N1, TA1, T2) and 1 set of fragments (F) were analyzed and evaluated using the 145 same parameter combinations. By comparing a, b, c, the limits of the scanner were also tested: specimens that were too small resulted in significant differences in a, b, c; as a result, we limited the volume in V = 1000 mm 3 . The size of the specimens ranged from 1000 − 21000 mm 3 . The best fit of the parameters was M = 200, ρ = 0.05, m = 10, R = 0.001, which resulted in good agreement between the measurements and computations for pebbles. Figure 5 shows the error of the averages for each sets and 2 summarizes the data of each set. As we can see in  Note that S and U are round numbers so that the error can be relatively high. Due to the averaging evaluation, we expect that the method won't detect extremities, e.g., it is not able to detect monostatic bodies. However, due to the uncertainty in the 155 exact location of the centroid, the consideration of multiple reference points is inevitable. to the coastline. The collecting person was moving from side to side, and the collecting process stopped when the satisfactory amount of pebbles was obtained. We scanned the collected samples with the proposed method and evaluated the geometries using the input parameters determined in Sect. 3.
Location A consisted of six measurement points lying approximately 8 meters far from each other in the direction perpendicular to the coastline. The pebbles were slightly embedded in the sand; therefore, we expected small transportation. We found Location A Figure 7. Shape properties evaluated on the scanned geometries of the samples collected from six measurement points of Location A.
Location A1 is the closest to the coast. The results show that from location A1 to A6 the particles gradually change their shape. The number of unstable equilibrium points decreases, the isoperimetric ratio increases, and the other parameters stay approximately constant.
fragments at location A1 near the coast and rounded pebbles at location A6, but there was no visible difference between them in terms of size distribution. We assumed that the particles along Location A have the same origin, but those that are lying farther from the coast have small sharp edges and corners eroded. Otherwise, we expected no significant difference between rocks along the line. The analysis supported our assumptions. The aspect ratios c/a, b/a and S stayed approximately constant along the line, but U decreased, and I increased. The number of specimens was 20-30 at each location; the size distribution was 170 between 11500 − 108000 mm 3 .
Location B consisted of five points lying from approximately 38 m far from each other. The path was also perpendicular to the coastline. Comparing location B1 and B5, we expected more complex abrasion processes. At location B5, the number of elongated pebbles seemed to be significantly more significant compared to location B1 based on visual inspection. The scanning analysis proved this assumption. Both the aspect ratios decreased, meaning that two sizes of the pebbles decreased 175 more than the longest size, leading to an elongated geometry. Subsequently, I also decreased with S and U decreasing. The number of specimens was 15-30 and the size distribution was between 5000 − 170000 mm 3 . Although the benchmark test in Sect. 3 showed, that using the Structure Sensor Mark I sharp edges cannot be recorded and results in a slightly decreased S and U , using this technique, we managed to catch the gradual changes at both locations. We collected and scanned approximately 400 pebbles and fragments under three days without the need for transportation of the 180 pebbles to the laboratory. Moreover, the dataset is available for further analysis.

Conclusions
A new scanning technique was introduced that can record and evaluate hundreds of specimens under a short period. By introducing portable scanners to geological applications, it becomes unnecessary to transport the collected samples to the laboratory.
Moreover, the postprocessing takes only a few minutes using the suggested setup, and it can be easily automated. Shape pa-185 rameters such as the axis ratios, the isoperimetric ratio and the number of static equilibria are evaluated using from the convex hull of the point cloud that represents the surface with contour lines. The technique is proved to be an excellent alternative to hand-measurements. We expect accelerated development on the hardware side, Structure Sensor Mark II. is already available, and the compatible Skanect Pro version is on the go, that will extend the range of scannable pebble sizes and could provide international groups through easy data sharing and storing. As the mathematical background of abrasion models and shape descriptors develops, there might appear new perspectives that can be examined on existing pebble geometries.
A possible extension of the method could be the scanning of multiple pebbles at the same time. If the scanner is connected to an iPad, then it is able to record the texture of the surface, e.g., it can record the ID written on the specimen. This way, the pebbles can be easily distinguished from each other and extracted in Blender. Structure Sensor Mark II comes with a wide lens 195 camera that can record the texture without an iPad connection. Depending on the size of the pebble, it would be possible to scan 4-5 pebbles at the same time, which could significantly reduce the overall scanning time. Video supplement. A video demonstration of the new method is available at Fehér et al. (2020).