# A Mobile LiDAR-Based Deep Learning Approach for Real-Time 3D Body Measurement
## 3 Proposed Algorithm for Mobile 3D Body Circumference Measurement  
### Merging Keypoints and 3D Data  
In this study, the overall process of body circumference measurement is divided into five stages, as shown in Figure 2. Among these, the length measurement process consists of three main steps. The first step involves detecting the endpoints of the body parts to be measured from photos taken from both the front and side views. The second step calculates the circumference between the detected endpoints, and the third step estimates the total circumference of the desired body part by integrating the results from the front and side views. In this section, we explain the detailed methodology and implementation process for each step and discuss the technical improvements introduced to overcome existing limitations. In the preprocessing stage as shown in Figure 2, noise filtering and edge detection ensure the clarity of depth information before keypoint extraction. HRNet-based keypoint detection is then applied to accurately locate body keypoints, followed by depth map correction to refine the measurement accuracy. First, in the initial stage of body circumference measurement, accurately detecting the endpoints of body parts is essential. To achieve this, we utilized the Human Pose Estimation using the High-Resolution Representations (HRNet) model [12]. HRNet excels  
Figure 2: Flowchart of 3D Measurement Methodology. at maintaining high-resolution representations while precisely detecting keypoints of the body, allowing for accurate identification of various body parts' locations. However, the basic HRNet model provides only a limited number of keypoints necessary for standard pose estimation, which restricts its ability to sufficiently cover all the endpoints required for body circumference measurement. To overcome these limitations, we applied transfer learning in this study. Specifically, we labeled 1000 images of people by categorizing them into two groups: upper body and lower body. In the upper body category, we labeled the endpoints of the chest and waist, and in the lower body category, we labeled the hip and buttock as keypoints. By further training the HRNet model using this labeled dataset, we aimed to expand the model's limited keypoint detection capabilities. The transfer learning process involved collecting 1000 images of people divided into upper and lower body categories, manually labeling the keypoints for the chest, waist, buttock, hips, and femoral condyles in each image, and setting up based on the pre-trained HRNet model. We then retrained the last few layers of the HRNet model using the labeled dataset to accurately detect the new keypoints, evaluated the model's performance with a validation dataset, and adjusted hyperparameters as necessary. In the second stage, we calculate the circumference between the detected endpoints from the front and side views. This calculation is primarily based on the Euclidean distance. Specifically, we define two keypoints as \(k_{1}=(x_{1},y_{1})\) and \(k_{1}=(x_{2},y_{2})\), and represent the distance between the two points as \(d(k_{1},k_{2})\). The Euclidean distance formula is as follows Equation (1) depending on the Figure 3:  
\[d(k_{1},k_{2})=\sqrt{(x_{2}-x_{1})^{2}+(y_{2}-y_{1})^{2}} \tag{1}\]  
Figure 3: Circumference estimation using keypoints \(k_{1},k_{2}\) detected from the camera’s perspective. Under the assumption that the y-axis positions of the two points are identical, the straight-line distances in the x-axis direction are summed to approximate the circumference between the two points. Represents this calculation follows Equation (2):  
\[\text{circum}(x_{1},x_{2})=\] \[d(x_{1},x_{1}+1)+\] \[d(x_{1}+1,x_{1}+2)+\] \[d(x_{1}+2,x_{1}+3)+\ldots+\] \[d(x_{2}-1,x_{2}) \tag{2}\]  
However, the keypoints detected in 2D images do not correspond to their actual positions in 3D space. Therefore, calculating the total circumference by simply summing the front and back circumferences introduces errors.