Next Article in Journal
A Novel DME-YOLO Structure in a High-Frequency Transformer Improves the Accuracy and Speed of Detection
Previous Article in Journal
A Deep Learning-Enhanced Stereo Matching Method and Its Application to Bin Picking Problems Involving Tiny Cubic Workpieces
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Target Localization and Grasping of NAO Robot Based on YOLOv8 Network and Monocular Ranging

1
School of Zhongyuan-Petersburg Aviation, Zhongyuan University of Technology, Zhengzhou 450007, China
2
School of Electronic and Information Engineering, Zhongyuan University of Technology, Zhengzhou 450007, China
3
Department of Electronic and Computer Engineering, Ritsumeikan University, Kusatsu 525-0058, Shiga, Japan
*
Authors to whom correspondence should be addressed.
Electronics 2023, 12(18), 3981; https://doi.org/10.3390/electronics12183981
Submission received: 28 August 2023 / Revised: 18 September 2023 / Accepted: 18 September 2023 / Published: 21 September 2023

Abstract

:
As a typical visual positioning system, monocular ranging is widely used in various fields. However, when the distance increases, there is a greater error. YOLOv8 network has the advantages of fast recognition speed and high accuracy. This paper proposes a method by combining YOLOv8 network recognition with a monocular ranging method to achieve target localization and grasping for the NAO robots. By establishing a visual distance error compensation model and applying it to correct the estimation results of the monocular distance measurement model, the accuracy of the NAO robot’s long-distance monocular visual positioning is improved. Additionally, a grasping control strategy based on pose interpolation is proposed. Throughout, the proposed method’s advantage in measurement accuracy was confirmed via experiments, and the grasping strategy has been implemented to accurately grasp the target object.

1. Introduction

With the rapid development of robotics technology, robots have been widely used in various fields such as transportation, welding, and assembly [1]. However, the precise positioning and grasping of robots are key technologies and prerequisites for them to carry out a variety of tasks. Zhang L. et al. proposed a robotic grasping method that uses the deep learning method YOLOv3 and the auxiliary signs to obtain the target location [2]. The method can control the movement of the robot and plan the grasping trajectory based on visual feedback information. However, the detection accuracy of this method is relatively low since target detection in the robot’s image is complicated by a complex background and target occlusion. Huang M. et al. proposed a multi-category SAR image object detection model based on YOLOv5s to address the issues caused by complex scenes [3]. Tan L.et al. adopted the hollow convolution to resample the feature image to improve the feature extraction and target detection performance [4]. The improved YOLOv4 algorithm has been adopted by numerous studies to facilitate target detection in robotic vision, aiming to enhance detection accuracy [5,6]. The improved algorithm has improved both detection speed and accuracy. Sun Y.et al. constructed the error compensation model based on Gaussian process regression (GPR), effectively improving the accuracy of positioning and grasping for large-sized objects [7]. This study focuses on the target localization and grasping of the NAO robot [8,9]. The target object is recognized through YOLOv8 network training [10]. Then, a monocular ranging model is established for the NAO robot to achieve the initial positioning of the target. Then, we establish a visual distance error compensation model to improve the monocular range. Furthermore, we utilize multi-point measurement compensation technology to estimate the target’s position and pose and ultimately achieve grasping the target.
The main contributions include: (1) Combining the YOLOv8 network with the Nao robot’s monocular ranging to realize the target recognition and localization and improving the issue of targets being unable to be accurately segmented in complex environments; (2) Due to the issue of greater errors with longer distances in the monocular distance measurement model, we propose a visual distance error compensation model using Gaussian process regression to improve the Nao robot’s distance ranging error within 2 cm; (3) The multi-point measurement compensation technology is proposed to estimate the target’s position and pose, and ultimately achieve grasping the target.
This paper is organized as follows: In Section 2, relevant target recognition and Localization technology is reviewed. In Section 3, the visual distance error compensation model is established to improve the long-distance monocular visual positioning accuracy of the Nao robot. In Section 4, a grasp control strategy based on pose interpolation is proposed to realize the pose estimation and smooth grasping and further verify the results of target recognition and localization. The experiment and results analysis are given in Section 5. Finally, the discussions are drawn in Section 6.

2. Target Recognition and Localization Technology

Target recognition based on traditional color segmentation has high requirements for the environment in which the target object is situated. In contrast, the YOLOv8 network has the advantages of fast speed, high accuracy, and strong scalability. Through training, the latter can extract feature points from the target to achieve target recognition [11]. The Nao robot operates using a single camera. Hence, this study employs the monocular vision localization techniques [12,13]. A monocular vision system is a typical visual positioning system [14]. But, most of the present research faces the problem that the farther the distance is, the greater the error is, and the attitude of the target object is not considered. First, the position coordinates of the target center under the image coordinate system are obtained through target detection using the YOLOv8 network. Then, the relationship between the location coordinates and image coordinates was determined using the monocular vision positioning model. Finally, it is possible to obtain the location coordinates of the target under the NAO robot coordinate system and to acquire the pose of the target object by measuring the endpoint and the center point of the target object, thereby ensuring that the NAO robot can accurately grasp the object.
The principle of monocular ranging based on the YOLOv8 algorithm is shown in Figure 1. The system mainly consists of three components: target detection, internal and external parameter acquisition, and monocular ranging. In the target detection phase, the detection frame is mainly obtained by the YOLOv8. Then, the internal and external parameters of the camera are obtained through the calibration. Finally, according to the principle of similar triangle ranging, the center point of the frame output in the target detection phase is used as the mapping point and combined with the internal and external parameters of the camera to achieve target positioning.

2.1. Target Recognition Based on YOLOv8 Network

YOLOv8 is a deep neural network architecture used for target detection tasks, as shown in Figure 2. Compared to YOLOv5 and YOLOv7, it provides a new SOTA model and a YOLACT-based instance segmentation model [11]. It is built as a unified framework for training object detection, instance segmentation, and image classification models. And the model can run on both CPU and GPU. The network consists of four main components: the input, the backbone, the loss calculation, and the regression branch. The input layer primarily focuses on data enhancement techniques, such as Mosaic [11], to carry out adaptive detection frame calculation and filling of grayscale values. The backbone network is responsible for feature extraction. The loss calculation process comprises two branches, namely classification and regression, to achieve accurate and efficient target detection [15,16,17].

2.2. Modeling of Monocular Ranging

Based on the NAO robot, a monocular ranging model is employed, utilizing the pinhole perspective principle as depicted in Figure 3. The relationship between the camera coordinate system, and the image coordinate system X Y in the camera imaging model is represented below. With the optical center position O c of the camera lens as the origin point, a camera coordinate system X C Y C Z C is established parallel to the X Y coordinate plane. The Z C axis is perpendicular to the X Y coordinate plane. The line segment O C O 1 represents the camera’s focal length. The point M of coordinates ( X C , Y C , Z C ) , corresponds to the point m in the image coordinate system, with coordinates ( X ,   Y ) . The relationship between image coordinates and actual spatial coordinates is depicted by Equation (1).
X Y 1 = 1 Z c f 0 0 0 0 f 0 0 0 0 1 0 X c Y c Z c 1
where f is the camera focal length.
Hence, after obtaining the coordinates of the center point and endpoint of the target image, the image coordinates can be converted into actual spatial coordinates. Subsequently, the pose of the target object in the robot coordinate system can be determined.
To determine the position of the target point in the image coordinate system, the center point ( u 0 , v 0 ) of the image pixel is taken as the origin of the image coordinate system. The transformation relationship is depicted in Equation (2).
x = ( u u 0 ) d x y = ( v v 0 ) d y
where d x and d y represent the size of each pixel, and u and v correspond to the pixel coordinates of the target point.
Figure 4 shows the monocular ranging model established for the NAO robot. The robot is positioned at the origin O W within the coordinate system O W X W Y W Z W . Point O serves as the camera position, and x O 1 y represents the image coordinate system. The endpoints Q 1 ,   Q 2 of the target rod correspond to q 1 ,   q 2 in the image coordinate system, respectively. Taking point Q 1 as an example, based on the principles of triangle similarity, the corresponding relationships of various angles can be obtained as shown in Equations (3)–(6).
f y = f d y
β 1 = α + γ 1
γ 1 = a r c t a n ( y f y )
X W = H t a n β 1
Among them, α denotes the pitch angle of the NAO robot’s head, H represents the height of the camera above the ground, f is the camera focal length, and f y denotes the component of f in the image coordinate system. The value of f has been calibrated to be 470 pixels.
By utilizing Equations (2)–(6), the X-coordinate P X 1 of point Q 1 can be derived, as depicted in Equation (7).
P X 1 = H t a n ( α + a r c t a n ( v v 0 f y ) )
The monocular ranging model for the NAO robot can be simplified into a perspective view, as shown in Figure 5. There, θ 1 represents the angle between point Q 1 and the principal optical axis in the horizontal direction. As a result, the distance between the target point and the robot in the Y-axis direction can be obtained. This is formulated in Equations (8)–(10), where φ denotes the angle of the NAO robot’s head in the horizontal direction.
f x = f d x
θ 1 = a r c t a n ( x f x )
P Y 1 = Y 1 = P X 1 × tan ( θ 1 + φ )
Similarly, it is possible to derive the position coordinates ( X W 2 , Y W 2 ) of point Q 2 under the robot’s coordinate system.
After the NAO robot has measured an accurate distance, the estimation of the target object’s pose can be achieved through a method of multiple measurements. By using the monocular ranging model established in Figure 4, range measurements are performed on the two endpoints of the target bar, thereby obtaining the coordinate values of Q 1 and Q 2 , which are ( P X 1 , P Y 1 ) and ( P X 2 , P Y 2 ) , respectively. Consequently, the deflection angle ϵ of the target rod on the O W X W Y W plane can be obtained, as demonstrated in Equation (11).
ϵ = a r c t a n ( P X 1 P X 2 P Y 1 + P Y 2 )

3. Modeling Visual Distance Error Compensation

3.1. Error Analysis

Based on the established monocular ranging model of the NAO robot, the distance in the X-axis direction of the robot’s coordinate system is related to the γ angle in a tangent function relationship, as shown in Figure 6. The further away, the smaller the γ angle. This results in larger measurement errors for distances that are further away.
Therefore, an error compensation model is established to reduce measurement errors when the target object is at a distance. The error term k has a relationship with the measured distance d m of the target rod. The relationship is depicted in Figure 7.

3.2. Gaussian Process Regression Model

Gaussian process regression (GPR) is a method of regression analysis using Gaussian processes (GP). The Gaussian process is composed of a series of random variables following a normal distribution [18].
Suppose there is a learning sample X , y containing n independent observations, where X = x 1 , x 2 , , x n is an input table consisting of n input vectors, and y = y 1 , y 2 , , y n is an output table consisting of n corresponding one-dimensional outputs. So, the mean of GP, μ ( x ) , and the variance k ( x , x ) can be expressed by the Equations (12) and (13).
μ ( x ) = E [ f ( x ) ]
k ( x , x ) = E [ ( f ( x ) μ ( x ) ) ( f ( x ) μ ( x ) ) ]
Here, x , x represents any random variable in the sample, and E is the mathematical expectations. Therefore, the GP can be defined as shown in Equation (14). In practical applications, the mean function μ ( x ) is zero through data preprocessing, so GP is as shown in Equation (15).
f ( x ) G P   [ μ ( x ) ,   k ( x , x ) ]
f ( x ) G P   [ 0 ,   k ( x , x ) ]
In regression problems, the output y is also affected by noise ε , which follows the Gaussian distribution with a mean of zero and a variance of σ n 2 , so the output y can be expressed as Equation (16).
y = f ( x ) + ε
Then, we can obtain the prior distribution of y , as Equation (17), and the joint prior distribution of y and f x * , as Equation (18). x * is the test input vector, I is the n-dimensional identity matrix, and K ( X , X ) is n × n order GP covariance matrix, K ( X , x * ) , is n × 1 order covariance matrix between the input set X and the test input vector x * , and k ( x * , x * ) is x * its own covariance.
y ~ N ( 0 , K ( X , X ) + σ n 2 I )
y f x * N 0 , K X , X + σ n 2 I n K X , x * K x * , X k x * , x *
From this, the posterior distribution of the predicted value f ( x * ) can be obtained as shown in Equations (19)–(21). Predicted mean value f ¯ ( x ) is the output of the GPR model and the predicted value of the observed value y .
f x X , y , x N f ¯ x , c o v f x
f ¯ x = K x , X k ( X , X ) + σ n 2 I n 1 y
cov f x = k x , x K x , X K X , X + σ n 2 I n 1 × K X , x
This study selects the square exponential function [18] as the kernel function, as shown in Equation (22).
k x i , x j θ = σ f 2 e 1 2 x i x j T x i x j σ l 2
Among them, σ l and σ f are respectively the characteristic length scale and the signal standard deviation. The Gaussian model can be derived from prior data, as shown in Figure 8. Here, the values of σ l and σ f are 0.7344 and 1.0522 respectively.
The blue “+” is the true value of the function, and the red solid line is the result of Gaussian process regression. The upper and lower solid lines represent two samples of the Gaussian distribution, and the area between them is the confidence region. Both satisfy the mean value of the red solid line. The farther away from the red solid line, the larger the variance and the lower the confidence level.
By combining Equations (16) and (22), we can obtain the error compensation model Equation (23). And by combining Equations (7) and (10), the target coordinates after compensation are given by Equation (24).
y = σ f 2 e 1 2 x i x j T x i x j σ l 2 + ε
X 1 = P X 1 × y Y 1 = P Y 1                

4. Pose-Interpolated Grasping Control Strategy

To verify the results of target recognition and localization, we adopted a pose interpolation strategy to plan the trajectory of the Nao robot arm to achieve smooth grasping of the target.

4.1. Linear Path Interpolation

The path of the NAO robotic arm end effector from the start point to the endpoint follows a linear trajectory. Therefore, interpolation is applied to the straight path between the start and endpoints. Let the positional coordinates of workspace start and end points be denoted as A = ( x a , y a , z a ) and B = ( x b , y b , z b ) , respectively. The distance between the start and end points is L = ( x b x a ) 2 + ( y b y a ) 2 + ( z b z a ) 2 , A point P i on the line segment, A B can be represented as P i = P a + ( P b P a ) S ( t ) / L ,   t [ 0 ,   T ] , and its coordinates are denoted as Equation (25):
  x i = x a + S ( t ) ( x b x a ) L y i = y a + S ( t ) ( y b y a ) L z i = z a + S ( t ) ( z b z a ) L
The interpolation curves of displacement, velocity, and acceleration are depicted in Figure 9. The arm velocity and acceleration both become zero at the start and end of the movement, ensuring the stability of the robot arm throughout its motion.
Substituting the S ( t ) from the acceleration-uniform-deceleration trajectory into the x i , results in the arm’s linear motion trajectory in space, as shown in Figure 10. It is evident that the points are densely packed at the ends of the straight line, while the middle portion is evenly distributed. This arrangement achieves the effect of acceleration-uniform-deceleration.

4.2. Position Interpolation

Due to the issue of excessive acceleration at the start and end points, we employ the fourth-order polynomial interpolation method for trajectory planning during the acceleration and deceleration phases.
The arm end displacement, velocity, and acceleration functions are expressed as S ( t ) , V ( t ) , and A ( t ) . The distance between the start and end points is denoted as L , and the velocity constant is represented as V m , the time intervals for the three phases are represented as t 0 , T / 4 ,   3 T / 4 , T . S ( t ) , V ( t ) , and A ( t ) of these three phases can be represented by the Equations (26)–(28) respectively. The acceleration phase t 0 , T / 4 , S 1 ( t ) , V 1 ( t ) , and A 1 ( t ) are
S 1 ( t ) = V m 2 t 1 3 t 4 + V m t 1 2 t 3 V 1 ( t ) = 2 V m t 1 3 t 3 + 3 V m t 1 2 t 2 A 1 ( t ) = 6 V m t 1 3 t 2 + 6 V m t 1 2 t
The constant velocity phase t T / 4,3 T / 4 , S 2 ( t ) , V 2 ( t ) , and A 2 ( t ) are
S 2 t = V m t V m t 1 / 2   V 2 t = V m                                             A 2 t = 0                                                  
The deceleration phase t 3 T / 4 , T , S 3 ( t ) , V 3 ( t ) , and A 3 ( t ) are
S 3 ( t ) = b 4 t 4 + b 3 t 3 + b 2 t 2 + b 1 t 1 + b 0 V 3 t = 4 b 4 t 3 + 3 b 3 t 2 + 2 b 2 t + b 1                 A 3 t = 12 b 4 t 2 + 6 b 3 t + 2 b 2                                      

4.3. Pose Interpolation

There are two methods for solving the pose of the robotic arm: the Euler method and the quaternion method. However, the Euler method struggles with issues such as singularities and coupling of angular velocities. Therefore, the quaternion method is chosen to interpolate the arm posture of the NAO robot.
The relationship between the quaternion q t and arm end pose matrix R is as shown in Equations (29)–(33), where I is the identity matrix and ω is the anti-symmetric matrix.
{ q t = [ q 0 , q 1 , q 2 , q 3 ] = [ q 0 , q x ] R = I + 2 q 0 ω + 2 ω 2
Convert the initial rotation matrix R b and the final rotation matrix R f into quaternions. And, then, the attitude angle θ is obtained.
q b = [ b 0 , b 1 , b 2 , b 3 ] q f = f 0 , f 1 , f 2 , f 3     θ = cos 1 ( q b q f )
At a certain moment t within this period T , the rotation matrix is represented by the quaternion q t as follows:
q t = x q b + y q f
where x , y are real numbers and the attitude angle t T θ between the initial quaternion q b and the quaternion q t at time t is defined. The attitude angle 1 t T θ between the quaternion q t at time t and the final quaternion q f is defined. Therefore, the quaternion pose interpolation matrix is
q t = q b sin ( ( 1 t T ) θ ) sin θ + q f sin ( t T θ ) sin θ
By performing position interpolation, the displacement matrix P can be obtained. Similarly, through pose interpolation, the rotation matrix R can be derived. By combining the displacement matrix P and the rotation matrix R , the pose interpolation matrix is obtained. Subsequently, by solving the inverse kinematics of the pose interpolation matrix, the angle values of various joints during the NAO robot arm’s motion process can be determined.
Conduct simulation experiments for arm trajectory planning by using MATLAB, taking two points coordinates as the starting and ending points of the arm movement, as illustrated in Equation (33).
{ x y z _ begin = [ 0.1817 ,   0.1362 ,   0.0633 ] x y z _ fin = [ 0.12 ,   0.01 ,   0.03 ]
Using these two points as the starting point and end point for trajectory planning, the corresponding pose interpolation matrix is substituted into the inverse kinematics equation, and arm motion simulation is performed using MATLAB to obtain the variation curve of the five joints from the ShoulderRoll to the WristYaw in the NAO robot’s right arm, as shown in Figure 11. From the curves depicted in the graph, it is evident that the NAO robot’s arm can move smoothly from the start point to the end point.

5. Experiments and Results Analysis

5.1. The NAO Robot Platform

The NAO robot is a bipedal humanoid robot developed by Aldebaran Robotics. It has 25 degrees of freedom in its body. Its hardware equipment includes a CPU, ultrasonic sensors, gyroscopes, and infrared sensors.
The NAO robot’s visual system incorporates two COMS cameras positioned on its forehead and mouth, which serve as a primary mode of perception for the robot in its surrounding environment. In the experiments discussed in this paper, the lower camera of the NAO robot will be utilized.
The right arm of the NAO robot has five degrees of freedom and is a serial robotic arm structure, with each joint connected by a link. According to the D-H method [19], the data shown in Table 1 can be obtained. On this basis, a link coordinate system for the right arm of the NAO robot can be established, as shown in Figure 12. In this coordinate system, s, e, and w represent the shoulder, elbow, and wrist joints of the NAO robot, respectively. The dimensions of the links are obtained through the parameters of the NAO robot’s right arm, where d3 = 0.9 cm and d5 = 10.855 cm.

5.2. Object Detection Experiment

The experimental process begins with data collection using the NAO robot. A dataset is established and fed into the YOLOv8 network for training. The training of the YOLOv8 network is conducted on a Linux-based server.
In this experiment, the target object is a black rod, which is not specific. The NAO robot’s bottom camera collected 100 images of the target rod at different angles, which were then processed through rotation and mirroring. Subsequently, the YOLOv8 network was trained for 800 rounds, with approximately 300 images per round. The original image captured by the NAO robot’s camera is depicted in Figure 13a. The target bar is identified using the YOLOv8 network, resulting in a binary image of the target object, as shown in Figure 13b.
After obtaining the edge point information of the target object, as shown in Figure 14a,b, data processing is employed to extract the pixel coordinates of the object’s center point and endpoints, and then the target is localized.
The rod is positioned in front of the NAO robot at distances ranging from 0.25 m to 1.30 m, with intervals of 0.05 m. Multiple experiments are conducted at each position to calculate an average value. From Table 2, it can be observed that the farther the target is from the robot, the larger the error becomes. Beyond 60 cm, the distance error exceeds the requirements for the task.
To address the issue of significant measurement error when the target’s position exceeds 60 cm, experiments were conducted using the improved monocular distance model with error compensation.
The target was placed in front of the NAO robot at distances ranging from 0.25 m to 1.30 m. From Table 3, it can be observed that the minimum error between the actual and measured positions is 0.13 cm, and the maximum error is 1.93 cm. Whether the target’s position is before or after 0.6 m, the error does not exceed 0.02 m.
As shown in Figure 15, the monocular distance measurement with the integrated error compensation model effectively reduces the distance error for positions that are farther away in the X-axis direction of the robot’s coordinate system.
The rod was placed at 90 cm in the robot’s X-direction, with distances of 0 cm, 20 cm, and 40 cm in the Y-direction. Each position underwent 10 tests, as shown in Table 4. The RMSEs of the three points are 0.644 cm, 0.574 cm, and 1.077 cm, respectively. It is evident that the NAO robot can accurately measure distances in the Y-axis direction, meeting the subsequent precision requirements.
After obtaining the position of the target rod, using the pixel coordinates of the two endpoints of the rod, the endpoint positions are calculated to determine the deviation angle of the rod. At a position of 60 cm in the robot’s X-axis direction, measurements were taken for deviation angles α of 30°, 45°, and 60°. As shown in Table 5, the RMSEs are 0.820°, 0.904°, and 0.901°, respectively, so the NAO robot can effectively measure the deviation angle of the rod, providing a foundation for accurate grasping.

5.3. Object Grasping Experiment

Due to the low friction between the ground and the feet of the NAO robot, it can experience slipping during walking, especially over longer distances. To mitigate this issue, a method involving measuring, short-distance walking, adjustment, and then measuring again. This approach ensures that the NAO robot can walk to the vicinity of the target rod with the correct orientation. Subsequently, adjust its crouching posture using the choreograph software. This ensures that the target rod is within the NAO robot’s workspace. The internal API can obtain the position of its end effector. By combining this information with the known coordinates of the target’s center point, the robot can accurately grasp the target at its center position. This process is illustrated in Figure 16.

6. Discussion

This paper combines YOLOv8 network recognition with monocular ranging methods to recognize and locate the target object. NAO robot acquires the pose information of the target object through its own monocular vision sensor, builds a visual distance error compensation model based on monocular ranging to compensate for distance errors, then moves near the target and grasps the target object by adjusting its attitude.
Based on experimental data and results, it is observed that the visual distance error compensation to the monocular ranging model effectively can improve the accuracy of the NAO robot’s distance measurement. The error between the actual position and measurement position is controlled within 2 cm. This accuracy has been improved compared to other research results, such as the 5% error rate achieved by Wang Z. et al. through single-camera distance measurement [20]. Furthermore, by utilizing pose interpolation techniques, the pose of the finger is adjusted to align with the target at a constant level. The experimental results show that the rotation angle error is controlled within 2°. These results indicate that the NAO robot can precisely estimate the target distance and pose and then facilitate precise walking and posture adjustments to ensure accurate object grasping. As previously mentioned, the accuracy of target recognition and long-distance localization in most present research has been improved.

Author Contributions

Conceptualization, Y.J. and S.W.; methodology, S.W.; software, Z.S.; validation, X.X. and G.W.; investigation, Y.J.; writing—original draft preparation, Z.S.; writing—review and editing, Y.J. and S.W.; project administration, H.L. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by the National Natural Science Foundation of China (Grant No. 62073297), the Natural Science Foundation of Henan Province (Grant No. 222300420595), and the Henan Science and Technology research project (Grant No. 222102520024, No. 222102210019, No. 232102221035).

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

Notations and Abbreviations

SOTA (State-Of-The-Art): Describe the model that achieves the current optimal effect on a certain task in machine learning; YOLACT (You Only Look At CoefficienTs): Real-time Instance Segmentation.

References

  1. Liu, H.; Wu, B.; Li, J. The development process and social significance of humanoid robot. Public Commun. Sci. Technol. 2020, 12, 109–111. [Google Scholar]
  2. Zhang, L.; Zhang, H.; Yang, H.; Bian, G.B.; Wu, W. Multi-target detection and grasping control for humanoid robot NAO. Int. J. Adapt. Control. Signal Process. 2019, 33, 1225–1237. [Google Scholar] [CrossRef]
  3. Huang, M.; Liu, Z.; Liu, T.; Wang, J. CCDS-YOLO: Multi-Category Synthetic Aperture Radar Image Object Detection Model Based on YOLOv5s. Electronics 2023, 12, 3497. [Google Scholar] [CrossRef]
  4. Tan, L.; Lv, X.; Lian, X.; Wang, G. YOLOv4_Drone: UAV image target detection based on an improved YOLOv4 algorithm. Comput. Electr. Eng. 2021, 93, 107261. [Google Scholar] [CrossRef]
  5. Tian, M.; Li, X.; Kong, S.; Wu, L.; Yu, J. A modified YOLOv4 detection method for a vision-based underwater garbage cleaning robot. Front. Inf. Technol. Electron. Eng. 2022, 23, 1217–1228. [Google Scholar] [CrossRef]
  6. Fu, H.; Song, G.; Wang, Y. Improved YOLOv4 marine target detection combined with CBAM. Symmetry 2021, 13, 623. [Google Scholar] [CrossRef]
  7. Sun, Y.; Wang, X.; Lin, Q.; Shan, J.; Jia, S.; Ye, W. A high-accuracy positioning method for mobile robotic grasping with monocular vision and long-distance deviation. Measurement 2023, 215, 112829. [Google Scholar] [CrossRef]
  8. Liang, Z. Research on Target Grabbing Technology Based on NAO Robot. Master’s Thesis, ChangChun University of Technology, ChangChun, China, 2021. [Google Scholar] [CrossRef]
  9. Jin, Y.; Wen, S.; Shi, Z.; Li, H. Target Recognition and Navigation Path Optimization Based on NAO Robot. Appl. Sci. 2022, 12, 8466. [Google Scholar] [CrossRef]
  10. Terven, J.; Cordova-Esparza, D. A comprehensive review of YOLO: From YOLOv1 to YOLOv8 and beyond. arXiv 2023, arXiv:2304.00501. [Google Scholar] [CrossRef]
  11. Li, Y.; Fan, Q.; Huang, H.; Han, Z.; Gu, Q. A Modified YOLOv8 Detection Network for UAV Aerial Image Recognition. Drones 2023, 7, 304. [Google Scholar] [CrossRef]
  12. He, M.; Zhu, C.; Huang, Q.; Ren, B.; Liu, J. A review of monocular visual odometry. Vis. Comput. 2020, 36, 1053–1065. [Google Scholar] [CrossRef]
  13. Kim, M.; Kim, J.; Jung, M.; Oh, H. Towards monocular vision-based autonomous flight through deep reinforcement learning. Expert Syst. Appl. 2022, 198, 116742. [Google Scholar] [CrossRef]
  14. Yang, M.; Wang, Y.; Liu, Z.; Zuo, S.; Cai, C.; Yang, J.; Yang, J. A monocular vision-based decoupling measurement method for plane motion orbits. Measurement 2022, 187, 110312. [Google Scholar] [CrossRef]
  15. Yu, H.; Li, X.; Feng, Y.; Han, S. Multiple attentional path aggregation network for marine object detection. Appl. Intell. 2023, 53, 2434–2451. [Google Scholar] [CrossRef]
  16. Feng, C.; Zhong, Y.; Gao, Y.; Scott, M.R.; Huang, W. Tood: Task-aligned one-stage object detection. In Proceedings of the 2021 IEEE/CVF International Conference on Computer Vision (ICCV), Montreal, QC, Canada, 11–17 October 2021; pp. 3490–3499. [Google Scholar]
  17. Li, X.; Wang, W.; Wu, L.; Chen, S.; Hu, X.; Li, J.; Yang, J. Generalized focal loss: Learning qualified and distributed bounding boxes for dense object detection. Adv. Neural Inf. Process. Syst. 2020, 33, 21002–21012. [Google Scholar]
  18. He, Z.; Fang, L.; Liu, W.; Chi, Y.; Wang, Y.; Fu, J.; Xiong, B. Short-term runoff prediction based on exponential kernel Gaussian Process Regression. China Rural. Water Hydropower 2023, 8, 25–31. [Google Scholar]
  19. Ding, Y.; Zhu, X.; Sun, X.; Meng, X.; Chen, X. Kinematics simulation and control system design of robot. Control. Eng. China 2021, 28, 546–552. [Google Scholar]
  20. Wang, Z.; Li, B.; Liu, R. Single-camera distance measurement algorithm based on YOLOv4 algorithm for unmanned aerial vehicle. Mach. Des. Manuf. Eng. 2022, 51, 58–62. [Google Scholar]
Figure 1. Schematic diagram of monocular ranging based on YOLOv8.
Figure 1. Schematic diagram of monocular ranging based on YOLOv8.
Electronics 12 03981 g001
Figure 2. The structure of YOLOv8 network.
Figure 2. The structure of YOLOv8 network.
Electronics 12 03981 g002
Figure 3. The pinhole imaging model.
Figure 3. The pinhole imaging model.
Electronics 12 03981 g003
Figure 4. The monocular ranging model for the NAO robot.
Figure 4. The monocular ranging model for the NAO robot.
Electronics 12 03981 g004
Figure 5. Vertical view of the monocular ranging model.
Figure 5. Vertical view of the monocular ranging model.
Electronics 12 03981 g005
Figure 6. Relationship between the γ angle and the measured distance.
Figure 6. Relationship between the γ angle and the measured distance.
Electronics 12 03981 g006
Figure 7. Relationship between the measured distance and error coefficient k .
Figure 7. Relationship between the measured distance and error coefficient k .
Electronics 12 03981 g007
Figure 8. Gaussian process regression result.
Figure 8. Gaussian process regression result.
Electronics 12 03981 g008
Figure 9. Interpolation curves for displacement, velocity, and acceleration.
Figure 9. Interpolation curves for displacement, velocity, and acceleration.
Electronics 12 03981 g009
Figure 10. Linear motion interpolation diagram.
Figure 10. Linear motion interpolation diagram.
Electronics 12 03981 g010
Figure 11. Joint angle motion curves.
Figure 11. Joint angle motion curves.
Electronics 12 03981 g011
Figure 12. D-H model of NAO robot’s right arm.
Figure 12. D-H model of NAO robot’s right arm.
Electronics 12 03981 g012
Figure 13. (a) Original image captured by NAO robot; (b) Target object identified by YOLOv8.
Figure 13. (a) Original image captured by NAO robot; (b) Target object identified by YOLOv8.
Electronics 12 03981 g013
Figure 14. (a) Endpoints of the target object; (b) Edge of the target object.
Figure 14. (a) Endpoints of the target object; (b) Edge of the target object.
Electronics 12 03981 g014
Figure 15. Comparison of measured distances before and after error compensation.
Figure 15. Comparison of measured distances before and after error compensation.
Electronics 12 03981 g015
Figure 16. NAO robot grasping process.
Figure 16. NAO robot grasping process.
Electronics 12 03981 g016
Table 1. D-H parameters table of the right arm of NAO robot.
Table 1. D-H parameters table of the right arm of NAO robot.
Links θ i (°) d i /mm a i /mm α i (°)Joint Range (°)
1 θ 1 0090−119.5~119.5
2 θ 2 (−90°)00−90−76~18
3 θ 3 d3090−119.5~119.5
4 θ 4 00−902~88.5
5 θ 5 (−90°)d5090104.5~104.5
1 θ 1 0090−119.5~119.5
Table 2. Actual and measured positions of the target before improvement.
Table 2. Actual and measured positions of the target before improvement.
Actual Position (cm)Measured Position (cm)Actual Position (cm)Measured Position (cm)
2525.508094.71
3029.4985104.26
3535.4590113.50
4038.8395116.43
4543.84100123.99
5052.94105133.08
5557.17110139.06
6064.80115144.73
6573.69120152.62
7082.55125163.13
7587.94130166.29
Table 3. Actual and measured positions of the target after error compensation.
Table 3. Actual and measured positions of the target after error compensation.
Actual Position (cm)Measured Position (cm)Actual Position (cm)Measured Position (cm)
2525.478078.67
3029.698584.64
3535.809090.96
4039.129593.10
4543.0810098.80
5051.60105106.25
5554.89110111.18
6060.37115115.75
6566.13120121.56
7071.46125127.16
7574.64130128.07
Table 4. Actual and measured distances in the Y-axis direction after error compensation.
Table 4. Actual and measured distances in the Y-axis direction after error compensation.
Actual Distance (cm)02040
Index
10.820.441.2
20.720.940.4
30.819.540.4
40.620.441.5
50.820.340.4
60.619.741.7
70.420.241.4
80.520.941.5
90.620.839.6
100.520.540.4
Table 5. Actual deviation angle vs. measured deviation angle.
Table 5. Actual deviation angle vs. measured deviation angle.
α / ° 304560
Index
130.4845.6660.85
230.7645.6959.36
330.5345.9358.82
431.2245.8759.56
529.8746.0560.59
630.8245.9260.89
730.6346.1561.35
829.0845.5661.09
929.3544.5860.53
1031.3446.3759.02
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Jin, Y.; Shi, Z.; Xu, X.; Wu, G.; Li, H.; Wen, S. Target Localization and Grasping of NAO Robot Based on YOLOv8 Network and Monocular Ranging. Electronics 2023, 12, 3981. https://doi.org/10.3390/electronics12183981

AMA Style

Jin Y, Shi Z, Xu X, Wu G, Li H, Wen S. Target Localization and Grasping of NAO Robot Based on YOLOv8 Network and Monocular Ranging. Electronics. 2023; 12(18):3981. https://doi.org/10.3390/electronics12183981

Chicago/Turabian Style

Jin, Yingrui, Zhaoyuan Shi, Xinlong Xu, Guang Wu, Hengyi Li, and Shengjun Wen. 2023. "Target Localization and Grasping of NAO Robot Based on YOLOv8 Network and Monocular Ranging" Electronics 12, no. 18: 3981. https://doi.org/10.3390/electronics12183981

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop