Digital sandbox interaction method and system
By using the camera device and image processing technology in the digital sand table interactive system to calculate the hand image integrity coefficient, motion stability coefficient and intention coefficient, and selecting the gesture with the highest operation priority index for manipulation, it solves the problem of inconsistency in operations when gestures are performed simultaneously in the existing technology. Accurate questions improve the accuracy and user experience of sandbox operations.
Patent Information
- Application Number
- CN202411021041.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-29
- Publication Date
- 2024-09-24
- Estimated Expiration
- 2044-07-29
AI Technical Summary
Existing digital sandbox interaction methods cannot accurately receive the operator's intention when multiple different gestures are performed simultaneously, resulting in inaccurate sandbox operations.
By setting up a camera device in the gesture recognition area to collect hand images in real time, use image processing technology to calculate the hand image integrity coefficient, motion stability coefficient and intention coefficient, calculate the operation priority index, and select the gesture with the highest operation priority index after sorting for sand table manipulation .
It improves the accuracy of sandbox operations, reduces recognition errors and misoperations caused by incomplete gestures, and improves user experience and operating efficiency.
Smart Images

Figure CN118567486B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of digital sandbox, and more specifically to a digital sandbox interaction method and system. Background Art
[0002] Digital sandbox is an interactive system that combines physical sandbox models with virtual reality technology. It is used to simulate and display complex systems (such as urban planning, military exercises, emergency rescue, etc.). Through projection, sensors and computer processing, it realizes real-time interaction and data visualization, providing users with an intuitive and dynamic operating experience.
[0003] Digital sandbox interaction refers to the real-time interaction between users and the digital sandbox system through gestures, touch or other input methods. The system captures user operations through sensors and provides instant feedback, dynamically updates the virtual display content, simulates and controls complex systems, and provides an intuitive and immersive experience. However, this interaction method will result in the inability to accurately receive the operator's intentions and perform accurate sandbox operations when two or more different gestures are detected within the control period.
[0004] In view of the above problems, the present invention proposes a solution. Summary of the invention
[0005] In order to overcome the above-mentioned defects of the prior art, the present invention provides a digital sandbox interaction method and system to solve the problems existing in the above-mentioned background technology.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] A digital sandbox interaction method comprises the following steps:
[0008] Step 1: a camera device is set in the gesture recognition area, and a fixed time interval is set during the detection period to collect hand images in real time through the camera device, and the integrity of the hand image is identified through image processing technology, and the hand image integrity coefficient is calculated;
[0009] Step 2: Calculate the motion stability coefficient through the hand images collected during the detection period;
[0010] Step 3: Obtain the distance between each hand movement and the recognition area as the recognition distance, and collect the total duration of each hand movement. Calculate the intention coefficient based on the recognition distance and the duration of the hand movement. The calculation formula is: , where IT is the intention coefficient, T is the total duration of the hand movement, represents the distance between the hand and the center of the recognition area at time t, It is expressed as the maximum allowed distance between the hand and the center of the recognition area;
[0011] Step 4: The hand image integrity coefficient, action stability coefficient, and intention coefficient are weighted and summed to obtain the operation priority index, which is calculated as follows: , where OP represents the operation priority index, HI represents the hand image integrity coefficient, SW represents the action stability coefficient, IT represents the intention coefficient, a1, a2, a3 represent the weight coefficients of the hand image integrity coefficient, action stability coefficient and intention coefficient;
[0012] Step 5: Sort the operation priority index of each gesture from high to low, and select the gesture with the highest operation priority index for sandbox control.
[0013] Preferably, the steps of identifying the integrity of the hand image by using image processing technology and calculating the hand image integrity coefficient are:
[0014] Step 1.1: Grayscale each collected image, apply Gaussian blur to remove noise, and segment the hand area using skin color detection method;
[0015] Step 1.2: Use the Canny edge detection algorithm to obtain the hand contour, and use morphological operations to process the contour to eliminate small holes and breakpoints;
[0016] Step 1.3: Use a computer to calculate the bounding box area, the hand contour area, and the convex hull area through image processing technology;
[0017] Step 1.4: Calculate the hand image contour area ratio based on the contour area and the convex hull area. The calculation formula is: , where I1 is the contour area ratio, A L Expressed as the contour area, A T It is expressed as the convex hull area;
[0018] Step 1.5: Calculate the ratio of the hand contour area to the bounding box area to get the bounding box fill rate, which is calculated as follows: , where I2 is the bounding box filling rate, A L Expressed as the contour area, A B Expressed as bounding box area;
[0019] Step 1.6: The edge continuity is evaluated by detecting the number of breakpoints on the contour, and the calculation formula is: , where I3 represents edge continuity, N b Expressed as the number of breakpoints on the contour, N MAX Expressed as the maximum allowed number of breakpoints;
[0020] Step 1.7: Identify the number of fingers and detect finger integrity. The calculation formula is: , where I4 represents the finger integrity, N f Expressed as the number of detected fingers, E f Expressed as the expected number of fingers;
[0021] Step 1.8: The hand image integrity is obtained by weighted summing the contour area ratio, bounding box fill rate, edge continuity, and finger integrity. The calculation formula is: , where H represents image completeness, I1 represents contour area ratio, I2 represents bounding box filling rate, I3 represents edge continuity, and I4 represents finger integrity. , , as well as It is expressed as weight coefficients of contour area ratio, bounding box filling ratio, edge continuity, and finger integrity;
[0022] Step 1.9: Calculate the mean of the image completeness of all images as the hand image completeness coefficient.
[0023] Preferably, the step of segmenting the hand area using the skin color detection method is:
[0024] Convert the image from RGB color space to HSV color space;
[0025] In the converted color space, set the threshold range for skin color;
[0026] The pixels that meet the skin color threshold range are set as foreground, and the remaining pixels are set as background to generate a binary image;
[0027] Morphological operations were applied to remove noise and small non-skin areas;
[0028] In the binary image, connected regions are extracted, and the connected region with the largest area is selected as the hand region.
[0029] Preferably, the step of obtaining the hand contour using the Canny edge detection algorithm is:
[0030] Convert the input color image into a grayscale image, and perform Gaussian filtering on the grayscale image;
[0031] Calculate the horizontal and vertical gradients of each pixel using the gradient strength formula Calculate the gradient strength using the gradient direction formula Calculate the gradient direction;
[0032] Check each pixel in the gradient direction, keep the local maximum, and set the rest to zero;
[0033] Set high and low thresholds to classify the gradient intensity image into three categories: strong edge, weak edge, and non-edge;
[0034] Connect the weak edge with the strong edge. If the weak edge is connected to the strong edge, it is retained, otherwise it is suppressed to obtain the hand contour.
[0035] Preferably, the action stability coefficient calculation step is:
[0036] Step 2.1: Use the sensor to capture the hand position in real time and record the coordinate data of the hand in the gesture recognition area over a period of time, and record it at time t i When the hand position is ;
[0037] Step 2.2: Calculate the hand speed based on the change in hand position at each time interval. The calculation formula is changed to , where v i Represented as the hand at t i to i+1 hand speed during the time interval;
[0038] Step 2.3: Calculate the hand acceleration based on the hand velocity in each time interval. The calculation formula is: , where a i Represented as the hand at t i to i+1 hand acceleration during the time interval;
[0039] Step 2.4: Calculate the standard deviation of hand speed based on the hand speed within the time interval. The calculation formula is: ,in is the standard deviation of hand speed, is the average value of hand velocity, and N is the total number of sampling points of hand position data;
[0040] Step 2.5: Calculate the standard deviation of hand acceleration based on the hand acceleration within the time interval. The calculation formula is: ,in Expressed as the standard deviation of hand acceleration, is the average value of hand acceleration;
[0041] Step 2.6: Calculate the motion stability coefficient based on the standard deviation of velocity and acceleration. The calculation formula is: , where SW is the motion stability coefficient, is the standard deviation of hand speed, It is expressed as the standard of hand acceleration, and k is the weight coefficient.
[0042] Preferably, the step of obtaining the distance between each hand movement and the recognition area is:
[0043] Use image processing technology to extract the coordinates of the hand center position , collect the center coordinates of the recognition area, denoted as ;
[0044] Calculate the Euclidean distance between the hand position and the center of the recognition area to reflect the proximity between the hand position and the center of the recognition area. The calculation formula is: , where d is the distance.
[0045] Preferably, a digital sandbox interactive system comprises:
[0046] A gesture data acquisition module, used to collect hand motion data in the gesture recognition area, the hand motion data including hand image information, hand motion information and hand position information, and transmit the hand motion data to the data analysis module;
[0047] A data analysis module is used to receive the hand motion data transmitted by the gesture data acquisition module, analyze the hand motion data to obtain a correlation coefficient, wherein the correlation coefficient includes a hand image integrity coefficient, a motion stability coefficient, and an intention coefficient, and transmit the correlation coefficient to the data evaluation module;
[0048] A data evaluation module is used to receive the correlation coefficient transmitted by the data analysis module, and comprehensively evaluate to obtain an operation priority index, and transmit the operation priority index to the gesture selection module;
[0049] The gesture selection module is used to receive the operation priority index transmitted by the data evaluation module, and select a gesture for sandbox control according to the operation priority index.
[0050] Technical effects and advantages of the present invention:
[0051] Hand images are collected in real time during the detection period, and the integrity of the hand images is identified through image processing technology. The hand image integrity coefficient is calculated, and the movement stability coefficient is calculated through the hand images collected during the detection period. The recognition distance and total duration of each hand movement are obtained, and the intention coefficient is calculated. The hand image integrity coefficient, movement stability coefficient and intention coefficient are weighted and summed to obtain the operation priority index. The operation priority index of each gesture is sorted from high to low, and the gesture with the highest operation priority index is selected for sandbox operation, which effectively improves the accuracy of sandbox operation. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 The present invention is a method flow chart of a digital sandbox interaction method.
[0053] Figure 2The figure is a module schematic diagram of a digital sandbox interactive system of the present invention. DETAILED DESCRIPTION
[0054] The technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the present invention. In addition, the forms of the various structures recorded in the following embodiments are only examples. The digital sandbox interaction method and system involved in the present invention are not limited to the various structures recorded in the following embodiments. All other implementations obtained by ordinary technicians in this field without making creative work belong to the scope of protection of the present invention.
[0055] The present invention provides a digital sandbox interaction method, comprising the following steps:
[0056] Step 1: A camera device is set in the gesture recognition area for identifying hand movements. The camera device is used to collect hand images in real time at fixed time intervals within the detection period. The integrity of the hand image is identified through image processing technology, and the hand image integrity coefficient is calculated;
[0057] Calculating the hand image integrity coefficient can help the system recognize clearer and more complete gesture images. A complete hand image contains more feature information, such as the posture of the fingers and the shape of the palm, which is essential for accurately identifying and distinguishing different gestures; gestures with a high hand image integrity coefficient are usually more stable and less susceptible to background interference or partial occlusion. In this way, the system can more stably recognize and respond to gesture operations, avoiding recognition errors or misoperations caused by incomplete hand images; by giving priority to gestures with high integrity coefficients, the system can ensure that users' operations are smoother and more intuitive when performing sandbox manipulation. This reduces the need for repeated operations due to incomplete gestures, thereby improving user experience and operating efficiency.
[0058] The hand image integrity coefficient can be used as a priority indicator for gesture operations. When multiple gestures exist at the same time, the system can select gestures with higher integrity coefficients for processing. This helps to reasonably allocate system resources in complex interactive environments and improve response speed and accuracy; by calculating the hand image integrity coefficient, the system can filter out some invalid or low-quality gesture images. These low-quality gestures may be incomplete due to occlusion, partial out of field of view or other reasons, thus affecting the recognition effect. Filtering these gestures can reduce the probability of misrecognition and ensure the reliability of the system.
[0059] In this embodiment, it should be specifically explained that the steps of identifying the integrity of the hand image by using the image processing technology and calculating the hand image integrity coefficient are as follows:
[0060] Step 1.1: Grayscale each collected image, apply Gaussian blur or median filtering to remove noise, and segment the hand area using skin color detection, which is a method of segmenting and identifying the hand area by detecting the pixel color in the image. It is usually achieved using color space conversion and threshold segmentation techniques. The key to this method is to select an appropriate color space and threshold so that the skin color can be accurately distinguished from the background;
[0061] Step 1.2: Use the Canny edge detection algorithm to obtain the outline of the hand, and use morphological operations to process the outline and eliminate small holes and discontinuities. The Canny edge detection algorithm is a multi-level edge detection algorithm that is widely used in the field of image processing, especially in object detection and computer vision applications. The goal of the Canny edge detection algorithm is to identify the edges in the image and make them suitable for further analysis and processing;
[0062] Step 1.3: Use a computer to calculate the bounding box area, the hand contour area, and the convex hull area through image processing technology;
[0063] The bounding box area refers to the area of the smallest rectangle that completely surrounds the hand, which is determined by finding the leftmost, rightmost, topmost and bottommost pixel positions of the hand area, and is used to quickly estimate the size and position of the hand area;
[0064] The hand contour area refers to the number of pixels actually occupied by the hand, indicating the real size of the hand. This area can be obtained by detecting the contour of the hand area and calculating all the pixels inside it;
[0065] The convex hull area refers to the area of the smallest convex polygon surrounding the hand contour, which is used to describe the external shape characteristics of the hand. By calculating the convex hull of the hand contour points and measuring its area, the integrity and shape of the hand can be analyzed;
[0066] Step 1.4: Calculate the hand image contour area ratio based on the contour area and the convex hull area. The calculation formula is: , where I1 is the contour area ratio, A L Expressed as the contour area, A T Expressed as the convex hull area, the contour area ratio reflects the hand integrity;
[0067] Step 1.5: Calculate the ratio of the hand contour area to the bounding box area to get the bounding box filling rate, which reflects whether the hand fills the entire bounding box. The calculation formula is: , where I2 is the bounding box filling rate, A L Expressed as the contour area, A B Expressed as bounding box area;
[0068] Step 1.6: The edge continuity is evaluated by detecting the number of breakpoints on the contour, and the calculation formula is: , where I3 represents edge continuity, N b Expressed as the number of breakpoints on the contour, N MAX Expressed as the maximum allowed number of breakpoints;
[0069] Step 1.7: Identify the number of fingers and detect finger integrity. The calculation formula is: , where I4 represents the finger integrity, N f Expressed as the number of detected fingers, E f Expressed as the expected number of fingers;
[0070] Step 1.8: The hand image integrity is obtained by weighted summing the contour area ratio, bounding box fill rate, edge continuity, and finger integrity. The calculation formula is: , where H represents image completeness, I1 represents contour area ratio, I2 represents bounding box filling rate, I3 represents edge continuity, and I4 represents finger integrity. , , , It is expressed as weight coefficients of contour area ratio, bounding box filling ratio, edge continuity, and finger integrity;
[0071] Step 1.9: Calculate the mean of the image completeness of all images as the hand image completeness coefficient.
[0072] In this embodiment, it should be specifically explained that the steps of segmenting the hand area using the skin color detection method are:
[0073] Convert the image from RGB color space to other color spaces more suitable for skin color detection, such as YCbCr, HSV, Lab, etc.
[0074] In the converted color space, set the skin color threshold range to segment possible skin areas;
[0075] The pixels that meet the skin color threshold range are set as foreground (usually white), and the other pixels are set as background (usually black) to generate a binary image;
[0076] Apply morphological operations (such as dilation, erosion, opening, and closing) to remove noise and small non-skin areas and enhance segmentation results;
[0077] In the binary image, connected regions are extracted, and the connected region with the largest area is selected as the hand region.
[0078] In this embodiment, it should be specifically explained that the steps of obtaining the hand contour using the Canny edge detection algorithm are:
[0079] The input color image is converted into a grayscale image by grayscale conversion, and the grayscale conversion is because edge detection usually performs simplified calculations on grayscale images;
[0080] Gaussian filtering is performed on the grayscale image to smooth the image and reduce noise. The Gaussian filtering uses a Gaussian kernel to perform a convolution operation on the image.
[0081] Calculate the horizontal (Gx) and vertical (Gy) gradients for each pixel using the gradient strength formula Calculate the gradient strength using the gradient direction formula Calculate the gradient direction;
[0082] Check each pixel in the gradient direction, keep the local maximum, and set other values to zero;
[0083] Set the high threshold (T_high) and the low threshold (T_low) to classify the gradient intensity image into three categories: strong edge, weak edge and non-edge;
[0084] Connect the weak edge with the strong edge. If the weak edge is connected to the strong edge, it is retained, otherwise it is suppressed to obtain the hand contour.
[0085] Step 2: Calculate the motion stability coefficient through the hand images collected during the detection period;
[0086] Gestures with high motion stability coefficients are less likely to shake violently or change rapidly, which allows the gesture recognition system to more accurately identify and interpret the user's intentions. Stable gestures are more easily recognized by the system as valid control commands, thereby reducing misidentification; stable gestures allow the system to more accurately track and interpret hand positions and movement trajectories, thereby improving the accuracy of sandbox manipulation. This is especially important for sandbox operations that require delicate adjustments and precise control; by calculating the motion stability coefficient, the system can filter out unstable gestures and reduce the occurrence of misoperations. This not only improves the user's fluency and accuracy when manipulating the sandbox, but also reduces the user's difficulty of operation and improves the overall interactive experience.
[0087] When multiple gestures are detected at the same time, the system can determine which gestures should be processed first based on the stability coefficient of the gestures. Gestures with high stability can be given higher priority, ensuring that the system responds quickly to the user's most explicit instructions; stable gestures mean that the changes in the movements are smoother and more consistent, and the system can process and respond more quickly. This helps reduce latency and improve the real-time nature of sandbox control, allowing users to experience more immediate and sensitive interactive feedback.
[0088] In this embodiment, it should be specifically explained that the steps for calculating the motion stability coefficient are:
[0089] Step 2.1: Use a sensor (such as a camera or depth sensor) to capture the hand position in real time and record the coordinate data of the hand in the gesture recognition area over a period of time. Assume that at time t i When the hand position is ;
[0090] Step 2.2: Calculate the hand speed based on the change in hand position at each time interval. The calculation formula is changed to , where v i Represented as the hand at t i to i+1 hand speed during the time interval;
[0091] Step 2.3: Calculate the hand acceleration based on the hand velocity in each time interval. The calculation formula is: , where a i Represented as the hand at t i to i+1 hand acceleration during the time interval;
[0092] Step 2.4: Calculate the standard deviation of hand speed based on the hand speed within the time interval. The calculation formula is: ,in is the standard deviation of hand speed, is the average value of hand speed, N is the total number of sampling points of hand position data, and the standard deviation can reflect the variation of hand movement. The smaller the standard deviation, the more stable the movement.
[0093] Step 2.5: Calculate the standard deviation of hand acceleration based on the hand acceleration within the time interval. The calculation formula is: ,in Expressed as the standard deviation of hand acceleration, is the average value of hand acceleration;
[0094] Step 2.6: Calculate the motion stability coefficient based on the standard deviation of velocity and acceleration. The calculation formula is: , where SW is the motion stability coefficient, is the standard deviation of hand speed, It is expressed as the standard of hand acceleration, and k is a weight coefficient used to balance the influence of speed and acceleration, which is adjusted according to the actual application scenario.
[0095] Step 3: Obtain the distance between each hand movement and the recognition area as the recognition distance, and collect the total duration of each hand movement. Calculate the intention coefficient based on the recognition distance and the duration of the hand movement. The calculation formula is: , where IT is the intention coefficient, T is the total duration of the hand movement, the longer T is, the longer the hand movement lasts. It represents the distance between the hand and the center of the recognition area at time t. It represents the instantaneous position of the hand relative to the recognition area. If the hand is within the recognition area, the distance is small; if the hand is far away from the recognition area, the distance is large. It is expressed as the maximum allowed distance between the hand and the center of the recognition area. If , then the action at that moment is not considered valid, that is, ,This formula indicates that during the entire action duration, the smaller the distance between the hand and the center of the recognition area, the larger the intention coefficient IT, indicating that the user's intention is clearer. On the contrary, if the hand is far away from the recognition area and the distance is large, the intention coefficient IT will decrease, indicating that the user's intention is unclear or the action is unstable;
[0096] Gestures with high intention coefficients usually indicate that the user has a clear and continuous intention to operate. By calculating the intention coefficient, the system can determine whether the user's gesture is clear enough, thereby reducing the response to unintentional or ambiguous gestures and ensuring accurate understanding of the user's operation intention; calculating the intention coefficient can help the system prioritize gestures with clear intentions. This means that the system can respond to gestures with high intention coefficients more quickly, improve the real-time and smoothness of the interaction, and enable users to operate the sandbox more efficiently; by calculating the intention coefficient and prioritizing gestures with high intention, the system can reduce the user's frustration caused by misoperation or ambiguous gestures. This can improve the user experience and make users feel that the system is more intelligent and easy to use.
[0097] In this embodiment, it should be specifically explained that the step of obtaining the distance between each hand movement and the recognition area is:
[0098] Use image processing technology to extract the coordinates of the hand center position , collect the center coordinates of the recognition area, denoted as ;
[0099] Calculate the Euclidean distance between the hand position and the center of the recognition area to reflect the proximity between the hand position and the center of the recognition area. The calculation formula is: , where d is the distance, the Euclidean distance is a geometric distance that represents the straight-line distance between two points. It is derived from Euclidean geometry and is often used to calculate the distance between two points in multidimensional space.
[0100] Step 4: The hand image integrity coefficient, action stability coefficient, and intention coefficient are weighted and summed to obtain the operation priority index, which is calculated as follows: , where OP is the operation priority index, HI is the hand image integrity coefficient. In the digital sandbox interaction, when the hand image is detected more complete and clear in the recognition area, the system considers the gesture to be more stable and the intention to be clearer, so it is given a higher operation priority. This means that the system will give priority to processing and responding to gesture instructions with high image integrity, thereby improving the accuracy of interaction and user experience. In other words, the higher the image integrity coefficient, the higher the possibility and priority of gesture recognition and execution, ensuring that the system responds quickly and accurately to clear and definite gestures. SW is the action stability coefficient. In the digital sandbox interaction system, when the user's gesture is more stable and smooth, the system will give the gesture a higher operation priority. This means that the system will give priority to those gestures with high action stability, because they usually represent the user's more clear and consistent operation intentions. Stable gestures reduce the possibility of misrecognition, improve the reliability and accuracy of interaction, and thus enhance user experience and operation efficiency. In other words, the more stable the action, the higher the possibility and priority of the gesture being responded to quickly and accurately by the system. IT is expressed as the intention coefficient. In the digital sandbox interaction system, the closer the user's gesture is to the recognition area and the longer it lasts, the system will give the gesture a higher operation priority. Specifically, this means that the system determines the user's operating intention by evaluating the distance between the gesture and the recognition area and the duration of the action. The higher the intention coefficient, the clearer and more persistent the user's operating intention. Therefore, the system will give priority to these gestures with high intention coefficients to ensure a more accurate and timely response to the user's operating needs, improve the effectiveness of the overall interaction and user satisfaction. a1, a2, and a3 are expressed as weight coefficients of the hand image integrity coefficient, the action stability coefficient, and the intention coefficient, and this embodiment does not perform specific calculations on the specific values of a1, a2, and a3;
[0101] Step 5: Sort the operation priority index of each gesture from high to low, and select the gesture with the highest operation priority index for sandbox control.
[0102] In this embodiment, it is necessary to specifically explain a digital sandbox interactive system, the system comprising:
[0103] A gesture data acquisition module, used to collect hand motion data in the gesture recognition area, the hand motion data including hand image information, hand motion information and hand position information, and transmit the hand motion data to the data analysis module;
[0104] A data analysis module is used to receive the hand motion data transmitted by the gesture data acquisition module, analyze the hand motion data to obtain a correlation coefficient, wherein the correlation coefficient includes a hand image integrity coefficient, a motion stability coefficient, and an intention coefficient, and transmit the correlation coefficient to the data evaluation module;
[0105] A data evaluation module is used to receive the correlation coefficient transmitted by the data analysis module, and comprehensively evaluate to obtain an operation priority index, and transmit the operation priority index to the gesture selection module;
[0106] The gesture selection module is used to receive the operation priority index transmitted by the data evaluation module, and select a gesture for sandbox control according to the operation priority index.
[0107] Finally: The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
[0108] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A digital sandbox interaction method, characterized in that: The following steps are involved: Step 1: a camera device is set in the gesture recognition area, and a fixed time interval is set during the detection period to collect hand images in real time through the camera device, and the integrity of the hand image is identified through image processing technology, and the hand image integrity coefficient is calculated; Step 2: Calculate the motion stability coefficient through the hand images collected during the detection period; Step 3: Obtain the distance between each hand movement and the recognition area as the recognition distance, and collect the total duration of each hand movement. Calculate the intention coefficient based on the recognition distance and the total duration of the hand movement. The calculation formula is: , where IT is the intention coefficient, T is the total duration of the hand movement, represents the distance between the hand and the center of the recognition area at time t, It is expressed as the maximum allowed distance between the hand and the center of the recognition area; Step 4: The hand image integrity coefficient, action stability coefficient, and intention coefficient are weighted and summed to obtain the operation priority index, which is calculated as follows: , where OP represents the operation priority index, HI represents the hand image integrity coefficient, SW represents the action stability coefficient, and IT represents the intention coefficient. , , It is expressed as the weight coefficient of hand image integrity coefficient, action stability coefficient and intention coefficient; Step 5: Sort the operation priority index of each gesture from high to low, and select the gesture with the highest operation priority index for sandbox control; The steps of identifying the integrity of the hand image by image processing technology and calculating the hand image integrity coefficient are as follows: Step 1.1: Grayscale each collected image, apply Gaussian blur to remove noise, and use skin color detection method to segment the hand area; Step 1.2: Use the Canny edge detection algorithm to obtain the hand contour, and use morphological operations to process the contour to eliminate small holes and breakpoints; Step 1.3: Use a computer to calculate the bounding box area, the hand contour area, and the convex hull area through image processing technology; Step 1.4: Calculate the hand image contour area ratio based on the contour area and the convex hull area. The calculation formula is: , where I1 is the contour area ratio, A L Expressed as the contour area, A T It is expressed as the convex hull area; Step 1.5: Calculate the ratio of the hand contour area to the bounding box area to get the bounding box fill rate, which is calculated as follows: , where I2 is the bounding box filling rate, A L Expressed as the contour area, A B Expressed as bounding box area; Step 1.6: The edge continuity is evaluated by detecting the number of breakpoints on the contour, and the calculation formula is: , where I3 represents edge continuity, N b Expressed as the number of breakpoints on the contour, N MAX Expressed as the maximum allowed number of breakpoints; Step 1.7: Identify the number of fingers and detect finger integrity. The calculation formula is: , where I4 represents the finger integrity, N f Expressed as the number of detected fingers, E f Expressed as the expected number of fingers; Step 1.8: The hand image integrity is obtained by weighted summing the contour area ratio, bounding box fill rate, edge continuity, and finger integrity. The calculation formula is: , where H represents image completeness, I1 represents contour area ratio, I2 represents bounding box filling rate, I3 represents edge continuity, and I4 represents finger integrity. , , as well as They are respectively expressed as the weight coefficient of the contour area ratio, the weight coefficient of the bounding box filling rate, the weight coefficient of the edge continuity, and the weight coefficient of the finger integrity; Step 1.9: Calculate the mean of the image integrity of all images as the hand image integrity coefficient; The steps of obtaining the hand contour using the Canny edge detection algorithm are: Convert the input color image into a grayscale image and perform Gaussian filtering on the grayscale image; Calculate the horizontal gradient of each pixel and the vertical gradient , using the gradient strength formula Calculate the gradient strength using the gradient direction formula Calculate the gradient direction; Check each pixel in the direction of the gradient, keep the local maximum, and set the rest to zero; Set high and low thresholds to classify the gradient intensity image into three categories: strong edge, weak edge, and non-edge; Connect the weak edge with the strong edge. If the weak edge is connected to the strong edge, it is retained, otherwise it is suppressed to obtain the hand contour; The steps for calculating the motion stability coefficient are: Step 2.1: Use the sensor to capture the hand position in real time and record the coordinate data of the hand in the gesture recognition area over a period of time, and record it at time t i When the hand position is ; Step 2.2: Calculate the hand speed based on the change in hand position at each time interval. The calculation formula is: , where v i Represented as the hand at t i to i+1 hand speed during the time interval; Step 2.3: Calculate the hand acceleration based on the hand velocity in each time interval. The calculation formula is: ,in Represented as the hand at t i to i+1 hand acceleration during the time interval; Step 2.4: Calculate the standard deviation of hand speed based on the hand speed within the time interval. The calculation formula is: ,in is the standard deviation of hand speed, is the average value of hand velocity, and N is the total number of sampling points of hand position data; Step 2.5: Calculate the standard deviation of hand acceleration based on the hand acceleration within the time interval. The calculation formula is: ,in Expressed as the standard deviation of hand acceleration, is the average value of hand acceleration; Step 2.6: Calculate the motion stability coefficient based on the standard deviation of velocity and the standard deviation of acceleration. The calculation formula is: , where SW is the motion stability coefficient, is the standard deviation of hand speed, It is expressed as the standard of hand acceleration, and k is the weight coefficient; The step of obtaining the distance between each hand movement and the recognition area is: Use image processing technology to extract the coordinates of the hand center position , collect the center coordinates of the recognition area, denoted as ; Calculate the Euclidean distance between the hand position and the center of the recognition area to reflect the proximity between the hand position and the center of the recognition area. The calculation formula is: , where d is the distance.
2. A digital sandbox interaction method according to claim 1, characterized in that: The steps of segmenting the hand area using the skin color detection method are as follows: Convert the image from RGB color space to HSV color space; In the converted color space, set the threshold range for skin color; The pixels that meet the skin color threshold range are set as foreground, and the remaining pixels are set as background to generate a binary image; Morphological operations were applied to remove noise and small non-skin areas; In the binary image, connected regions are extracted, and the connected region with the largest area is selected as the hand region.
3. A digital sandbox interaction system, used to implement the digital sandbox interaction method according to claim 1 or 2, characterized in that: The system comprises: A gesture data acquisition module, used to collect hand motion data in the gesture recognition area, the hand motion data including hand image information, hand motion information and hand position information, and transmit the hand motion data to the data analysis module; A data analysis module is used to receive the hand motion data transmitted by the gesture data acquisition module, analyze the hand motion data to obtain a correlation coefficient, wherein the correlation coefficient includes a hand image integrity coefficient, a motion stability coefficient, and an intention coefficient, and transmit the correlation coefficient to the data evaluation module; A data evaluation module is used to receive the correlation coefficient transmitted by the data analysis module, and comprehensively evaluate to obtain an operation priority index, and transmit the operation priority index to the gesture selection module; The gesture selection module is used to receive the operation priority index transmitted by the data evaluation module, and select a gesture for sandbox control according to the operation priority index.
