A treadmill panoramic somatosensory motion system and method based on augmented reality

By integrating virtual scene construction and image processing modules on the treadmill to identify motion postures and trajectories, the problem of poor motion interaction effects in the treadmill's panoramic somatosensory motion system is solved, and a more natural and realistic motion interaction experience is achieved.

CN118331430BActive Publication Date: 2024-10-01SHENZHEN ZHONGXIN YUNCHUANG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410758877.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-13
Publication Date
2024-10-01
Estimated Expiration
2044-06-13

AI Technical Summary

Technical Problem

The existing panoramic somatosensory motion system of treadmills has poor motion interaction effect. Users cannot achieve natural interaction during exercise, and the sensors are bound and the interaction effect is poor.

Method used

A treadmill panoramic somatosensory motion system based on augmented reality is adopted, including a virtual scene building module, image denoising and background segmentation module, motion pose recognition module, motion trajectory calculation module and motion interaction module. Through panoramic image processing and motion data analysis, Construct a virtual scene and perform motion interaction to improve the realism and effect of motion interaction.

Benefits of technology

Through denoising and background segmentation processing, clear motion image frames are obtained, motion poses and trajectories are identified, and motion strategies are calculated to achieve more natural and realistic motion interaction and improve the motion interaction effect of the treadmill panoramic somatosensory motion system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118331430B_ABST
    Figure CN118331430B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of panoramic somatosensory technology, and discloses a treadmill panoramic somatosensory motion system and method based on augmented reality. The system includes a virtual scene construction module, an image denoising and background segmentation module, a motion posture recognition module, a motion trajectory calculation module and a motion interaction module. The system constructs a virtual scene of treadmill panoramic somatosensory; performs image denoising and background segmentation on the motion image frame sequence of the treadmill panoramic somatosensory to obtain a target image frame; calculates the motion joint information in the target image frame, and identifies the motion posture according to the motion joint information; performs motion modeling on the motion posture to obtain a motion posture sequence, and calculates the motion trajectory of the motion image frame sequence according to the motion posture sequence; calculates the motion strategy according to the motion trajectory, and uses the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene. The present invention can improve the motion interaction effect of the treadmill panoramic somatosensory motion system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of panoramic somatosensory technology, and in particular to a treadmill panoramic somatosensory motion system and method based on augmented reality. Background Art

[0002] Thanks to the development of virtual reality technology, fitness equipment and fitness systems based on virtual reality have developed rapidly in recent years. Treadmill panoramic somatosensory is an innovative fitness solution that combines sports science, human-computer interaction and virtual / augmented reality technology (VR / AR). Through panoramic somatosensory, the real-world running experience can be simulated, thereby improving the attractiveness and effectiveness of indoor treadmill exercise.

[0003] The existing treadmill somatosensory running system mainly uses the OpenGL (Open Graphics Library) graphics library to realize the drawing of the running virtual scene, and displays the speed, distance, heart rate and other motion status data in real time in the three-dimensional scene, or based on the OSG (Open Scene Graph) graphics library, uses sensor sampling data to feedback the runner's status in real time. However, a sensor needs to be bound during use, which hinders people's normal movement, and people only passively output various indicators of the body, without truly achieving the effect of natural motion interaction. Therefore, how to improve the motion interaction effect of the treadmill panoramic somatosensory motion system has become an urgent problem to be solved. Summary of the invention

[0004] The present invention provides a treadmill panoramic somatosensory motion system and method based on augmented reality, the main purpose of which is to solve the problem of poor motion interaction effect of the treadmill panoramic somatosensory motion system.

[0005] To achieve the above-mentioned purpose, the present invention provides a treadmill panoramic somatosensory motion system based on augmented reality, the system comprising a virtual scene construction module, an image denoising and background segmentation module, a motion posture recognition module, a motion trajectory calculation module and a motion interaction module, wherein:

[0006] The virtual scene construction module is used to obtain a panoramic image of the treadmill, identify a virtual moving target in the panoramic image, and construct a virtual scene of the treadmill according to the virtual moving target;

[0007] The image denoising and background segmentation module is used to collect the motion image frame sequence of the panoramic somatosensory image of the treadmill, perform image denoising and background segmentation on each motion image frame in the motion image frame sequence, and obtain a target image frame;

[0008] The motion posture recognition module is used to calculate the motion joint information in each of the target image frames, and recognize the motion posture of each of the motion image frames according to the motion joint information;

[0009] The motion trajectory calculation module is used to perform motion modeling on the motion posture to obtain a motion posture sequence of the motion image frame, and calculate the motion trajectory of the motion image frame sequence according to the motion posture sequence;

[0010] The motion interaction module is used to calculate the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, and use the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene.

[0011] Optionally, when identifying a virtual moving target in the panoramic image, the virtual scene construction module is specifically used to:

[0012] Performing median filtering on the panoramic image to obtain a filtered image;

[0013] Converting the filtered image into a binary image, and identifying a target area in the binary image;

[0014] A color histogram function of the target area is calculated, and a virtual moving target in the panoramic image is identified according to the histogram function.

[0015] Optionally, when identifying a virtual moving target in the panoramic image according to the histogram function, the virtual scene construction module is specifically used to:

[0016] Calculating a function distance between the histogram function and a preset target histogram function;

[0017] The function distance between the histogram function and the preset target histogram function is calculated using the following formula: in, Represents the histogram function With the preset target histogram function The function distance between Indicates The pixel value in the histogram function The function value in Indicates The pixel value is in the target histogram function The function value in ;

[0018] A virtual moving target in the panoramic image is determined according to the functional distance.

[0019] Optionally, when the image denoising and background segmentation module performs image denoising and background segmentation on each motion image frame in the motion image frame sequence to obtain a target image frame, the image denoising and background segmentation module is specifically used to:

[0020] Performing additive Gaussian noise on the motion image frame to obtain a Gaussian noisy image, and performing a first morphological calculation on the Gaussian noisy image to obtain a morphological image;

[0021] The first morphological calculation is performed on the Gaussian noise image using the following formula to obtain a morphological image: in, Represents the pixel point in the Gaussian noise image The morphological image after opening operation, Represents the pixel point in the Gaussian noise image The pixel value of represents the erosion operation, represents the dilation operation, Represents the pixel point in the Gaussian noise image Morphological images with closing operation;

[0022] Determine noise pixels in the motion image frame according to the morphological image, and perform a second morphological calculation on the noise pixels to obtain a denoised image;

[0023] The background of the denoised image is segmented using a preset threshold to obtain a target image frame.

[0024] Optionally, when the image denoising and background segmentation module performs the second morphological calculation on the noise pixel points to obtain the denoised image, it is specifically used to:

[0025] Performing an opening and closing operation and a closing and opening operation on the noise pixel points respectively to obtain an opening and closing operation pixel value and a closing and opening operation pixel value;

[0026] Calculating the pixel value average of the opening and closing operation pixel value and the closing and opening operation pixel value;

[0027] The pixel values ​​of the noise pixels are replaced by the pixel value mean to obtain a denoised image.

[0028] Optionally, when calculating the motion joint information in each of the target image frames, the motion posture recognition module is specifically used to:

[0029] Convolution and normalization are performed on each of the target image frames to obtain a normalized feature map, and multi-head self-attention calculation is performed on the normalized feature map to obtain an attention feature map;

[0030] Performing a residual connection between the attention feature map and the normalized feature map to obtain a residual feature map;

[0031] Performing full connection on the residual feature map to obtain a fully connected feature map, and performing residual connection on the fully connected feature map and the residual feature map to obtain a target feature map;

[0032] The motion joints are identified according to the target feature map to obtain the motion joint information in the target image frame.

[0033] Optionally, when the motion trajectory calculation module calculates the motion trajectory of the motion image frame sequence according to the motion posture sequence, it is specifically used to:

[0034] Extracting the joint coordinates of each motion joint in the motion posture sequence to obtain a joint coordinate sequence;

[0035] Calculate the trajectory vector sequence of the motion joint according to the joint coordinate sequence;

[0036] The motion trajectory of the motion image frame sequence is drawn according to the trajectory vector sequence and the joint coordinate sequence.

[0037] Optionally, when the motion interaction module calculates the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, it is specifically used to:

[0038] Linearly mapping the node coordinates of each motion joint in the motion trajectory to obtain position coordinate features;

[0039] Performing spatial feature encoding on the position coordinate feature to obtain a coding feature;

[0040] The position coordinate feature is encoded using the following formula to obtain the encoded feature: in, Indicates The encoded features of the layer, represents the attention mechanism, Representation layer normalization operation, Indicates The encoded features of the layer, Represents the total number of coding layers for spatial feature encoding, Represents the encoding feature;

[0041] A motion strategy corresponding to the motion image frame sequence is calculated according to the encoding feature.

[0042] Optionally, when the motion interaction module uses the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain the motion interaction scene, it is specifically used to:

[0043] Extracting a virtual motion joint in the virtual scene, and controlling the motion trajectory of the virtual motion joint according to the motion trajectory to obtain a trajectory interaction scene;

[0044] Setting a virtual motion strategy of the virtual scene according to the motion strategy to obtain a strategy interaction scene;

[0045] The virtual scene is subjected to scene interaction according to the trajectory interaction scene and the strategy interaction scene to obtain a motion interaction scene corresponding to the virtual scene.

[0046] In order to solve the above problems, the present invention also provides a treadmill panoramic somatosensory exercise method based on augmented reality, the method comprising:

[0047] Acquire a panoramic image of a treadmill, identify a virtual moving target in the panoramic image, and construct a virtual scene of the treadmill according to the virtual moving target;

[0048] Collecting the motion image frame sequence of the panoramic somatosensory image of the treadmill, performing image denoising and background segmentation on each motion image frame in the motion image frame sequence, and obtaining a target image frame;

[0049] Calculating motion joint information in each of the target image frames, and identifying the motion posture of each of the motion image frames according to the motion joint information;

[0050] Performing motion modeling on the motion posture to obtain a motion posture sequence of the motion image frames, and calculating a motion trajectory of the motion image frame sequence according to the motion posture sequence;

[0051] The motion strategy corresponding to the motion image frame sequence is calculated according to the motion trajectory, and the motion strategy and the motion trajectory are used to perform motion interaction on the virtual scene to obtain a motion interaction scene.

[0052] The embodiment of the present invention can ensure that the visual effect and interactivity of the virtual scene meet the requirements by constructing a treadmill panoramic somatosensory virtual scene according to the panoramic image of the treadmill panoramic somatosensory; image denoising and background segmentation are performed on the motion image frame sequence of the treadmill panoramic somatosensory, and the target image frame with noise information removed and structural detail information enhanced can be obtained; the motion posture of the target image frame is constructed, and the posture change of the user on the treadmill can be identified according to the motion posture, and the interaction is more natural, which is conducive to improving the effect of motion interaction; the motion trajectory of the motion image frame sequence is constructed, and the motion strategy corresponding to the motion image frame sequence is calculated according to the motion trajectory, and the virtual scene can be interactively moved according to the motion trajectory and the motion strategy, which can improve the sense of reality during the motion interaction, and meet the needs of the treadmill during the motion interaction, and effectively improve the motion interaction effect of the treadmill panoramic somatosensory motion system. Therefore, the treadmill panoramic somatosensory motion system and method based on augmented reality proposed by the present invention can improve the motion interaction effect of the treadmill panoramic somatosensory motion system. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 A system architecture diagram of a treadmill panoramic somatosensory motion system based on augmented reality provided by an embodiment of the present invention;

[0054] Figure 2 A system architecture diagram of a virtual scene construction module for identifying virtual moving targets in a panoramic image provided by an embodiment of the present invention;

[0055] Figure 3 A system architecture diagram of an image denoising and background segmentation module provided in an embodiment of the present invention when performing image denoising and background segmentation on each motion image frame in a motion image frame sequence;

[0056] Figure 4 A schematic diagram of a flow chart of a treadmill panoramic somatosensory exercise method based on augmented reality provided by an embodiment of the present invention;

[0057] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0058] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0059] like Figure 1, is a system architecture diagram of an augmented reality-based treadmill panoramic somatosensory motion system provided by an embodiment of the present invention.

[0060] The treadmill panoramic somatosensory motion system 100 based on augmented reality of the present invention can be set in a cloud server. In terms of implementation, it can be used as one or more service devices, or it can be installed as an application on the cloud (such as a server of a mobile service operator, a server cluster, etc.), or it can also be developed as a website. According to the functions implemented, the treadmill panoramic somatosensory motion system 100 based on augmented reality can include a virtual scene construction module 101, an image denoising and background segmentation module 102, a motion posture recognition module 103, a motion trajectory calculation module 104 and a motion interaction module 105. The module of the present invention can also be referred to as a unit, which is a series of computer program segments that can complete fixed functions and are stored in the memory of an electronic device.

[0061] In the following, in conjunction with specific embodiments, each component and specific workflow of the treadmill panoramic somatosensory motion system based on augmented reality are described respectively:

[0062] The virtual scene construction module 101 is used to obtain a panoramic image of a treadmill, identify a virtual moving target in the panoramic image, and construct a virtual scene of the treadmill according to the virtual moving target.

[0063] In an embodiment of the present invention, the treadmill panoramic somatosensory system is a somatosensory system pre-set on the treadmill for performing panoramic somatosensory exercise. The treadmill panoramic somatosensory system can realize natural motion interaction during running. The panoramic image is a motion image taken by the somatosensory system. The panoramic image can be taken by using a pre-set shooting device after the user turns on the treadmill.

[0064] In an optional embodiment, the virtual moving target is a moving object that can be generated or simulated in a panoramic image. It is an image generated by a computer based on a moving object in the real world, thereby obtaining a virtual scene when running, such as environmental information when running, target position, etc.

[0065] Specifically, see Figure 2 As shown, the virtual scene construction module 101 includes a median filtering module 201 , a target area recognition module 202 and a virtual moving target recognition module 203 .

[0066] In the embodiment of the present invention, the step of identifying a virtual moving target in the panoramic image includes:

[0067] The median filtering module 201 is used to perform median filtering on the panoramic image to obtain a filtered image;

[0068] The target region identification module 202 is used to convert the filtered image into a binary image and identify the target region in the binary image;

[0069] The virtual moving target identification module 203 is used to calculate the color histogram function of the target area and identify the virtual moving target in the panoramic image according to the histogram function.

[0070] In an embodiment of the present invention, median filtering replaces each pixel in a panoramic image with a median pixel value within a preset range, for example, the median pixel value of pixels within a 3x3 or 5x5 neighborhood. Median filtering can remove image noise in the panoramic image while retaining the edge and detail information of the image, thereby improving the accuracy of virtual moving target recognition.

[0071] Preferably, by comparing the grayscale value of each pixel in the filtered image with a preset grayscale value threshold, if the grayscale value of the pixel is greater than or equal to the grayscale value threshold, the grayscale value of the pixel is set to white (i.e., the grayscale value is 255, indicating the brightest); if the grayscale value of the pixel is less than the threshold, it is set to black (i.e., the grayscale value is 0, indicating the darkest). By binarizing the image, the amount of data to be processed can be simplified, while clearly highlighting specific features or contours in the panoramic image, which is conducive to the subsequent identification of the target area.

[0072] Specifically, the Canny edge detection operator can be used to identify the image edges in the filtered image as the target area where the virtual moving target may appear, and then the color histogram function of each target area is further calculated. The color histogram is used to describe the percentage of each color in each target area. The color histogram function calculates the total frequency of pixel values ​​in the target area, usually dividing each pixel value by the total number of pixels and expressing it in the form of probability.

[0073] In the embodiment of the present invention, the identifying the virtual moving target in the panoramic image according to the histogram function includes:

[0074] Calculating a function distance between the histogram function and a preset target histogram function;

[0075] A virtual moving target in the panoramic image is determined according to the functional distance.

[0076] Specifically, the function distance between the histogram function and the preset target histogram function is calculated using the following formula: in, Represents the histogram function With the preset target histogram function The function distance between Indicates The pixel value in the histogram function The function value in Indicates The pixel value is in the target histogram function The function value in .

[0077] In the embodiment of the present invention, the virtual scene is a simulated scene of the user when using a treadmill, and can be simulated more accurately according to the virtual motion target to improve the realism during exercise.

[0078] In the embodiment of the present invention, the step of constructing the virtual scene of the treadmill panoramic body perception according to the virtual motion target includes:

[0079] Extracting virtual motion features and depth image information of the virtual motion target in the panoramic image;

[0080] Constructing a three-dimensional model of the virtual motion target according to the virtual motion characteristics and the depth image information;

[0081] The three-dimensional model is subjected to scene rendering to obtain a virtual scene of the treadmill panoramic somatosensory perception.

[0082] In an embodiment of the present invention, the virtual motion feature is to extract the image feature of the virtual motion target in the panoramic image. The virtual motion feature can be extracted using a pre-built convolutional neural network. The depth image information can be acquired based on the depth image corresponding to the panoramic image acquired by the somatosensory system, that is, the depth information of each virtual motion target in the depth image. Then, a three-dimensional model of the virtual motion target is constructed using 3D modeling software, and scene rendering is performed to ensure that the visual effect and interactivity of the virtual scene meet the requirements.

[0083] The image denoising and background segmentation module 102 is used to collect the motion image frame sequence of the treadmill panoramic somatosensory image, perform image denoising and background segmentation on each motion image frame in the motion image frame sequence, and obtain a target image frame.

[0084] In an embodiment of the present invention, a motion image frame sequence is composed of each video frame corresponding to a motion video shot while exercising on a treadmill, for example, a video frame sequence corresponding to a 3-second motion video, a video frame sequence corresponding to a 5-second motion video, etc. Specifically, video frames in the motion video can be collected according to a specific frame rate of the motion video, and then sorted according to time to obtain a motion image frame sequence.

[0085] In an embodiment of the present invention, image denoising is to remove image noise in each motion image frame, which is conducive to obtaining a more accurate target image frame, and background segmentation is to separate the foreground object and the background from the motion image frame. For example, if the foreground object in the motion image frame is a user, the motion joint information in the target image frame can be more accurately calculated through background segmentation.

[0086] Specifically, participation Figure 3 As shown, the image denoising and background segmentation module 102 includes a first morphological calculation module 301 , a second morphological calculation module 302 and a background segmentation module 303 .

[0087] In the embodiment of the present invention, performing image denoising and background segmentation on each motion image frame in the motion image frame sequence to obtain a target image frame includes:

[0088] The first morphological calculation module 301 is used to perform additive Gaussian noise on the motion image frame to obtain a Gaussian noisy image, and perform a first morphological calculation on the Gaussian noisy image to obtain a morphological image;

[0089] The second morphological calculation module 302 is used to determine the noise pixels in the motion image frame according to the morphological image, and perform a second morphological calculation on the noise pixels to obtain a denoised image;

[0090] The background segmentation module 303 is used to perform background segmentation on the denoised image using a preset threshold to obtain a target image frame.

[0091] Preferably, additive Gaussian noise is to add additive Gaussian noise with a variance of 50 to each pixel in the motion image frame. Additive Gaussian noise can simulate noise interference in the real world, which is beneficial to the subsequent recognition of noise pixels.

[0092] The first morphological calculation includes performing an opening operation and a closing operation on the Gaussian noisy image to obtain a morphological image.

[0093] Specifically, the first morphological calculation is performed on the Gaussian noisy image using the following formula to obtain a morphological image: in, Represents the pixel point in the Gaussian noise image The morphological image after opening operation, Represents the pixel point in the Gaussian noise image The pixel value of represents the erosion operation, represents the dilation operation, Represents the pixel point in the Gaussian noise image Morphological image to be closed.

[0094] Among them, the pixel value difference between the pixel point in the Gaussian noise image and the pixel value after opening and closing operations can be expressed as , , and then compare , The size of the difference between the noise pixel and the set difference threshold determines the noise pixel point, for example, Greater than or equal to the difference threshold and is 0, or Greater than or equal to the difference threshold and If it is 0, the pixels in the Gaussian noisy image are noise pixels.

[0095] In the embodiment of the present invention, performing a second morphological calculation on the noise pixels to obtain a denoised image includes:

[0096] Performing an opening and closing operation and a closing and opening operation on the noise pixel points respectively to obtain an opening and closing operation pixel value and a closing and opening operation pixel value;

[0097] Calculating the pixel value average of the opening and closing operation pixel value and the closing and opening operation pixel value;

[0098] The pixel values ​​of the noise pixels are replaced by the pixel value mean to obtain a denoised image.

[0099] Specifically, the opening and closing operation uses a preset structural element to first open the noise pixels and then perform a closing operation. The closing and opening operation uses a preset structural element to first close the noise pixels and then perform an opening operation. The pixel value of the noise pixels is replaced by the obtained pixel value mean. The first morphological calculation and the second morphology can remove the noise information in the motion image frame and enhance the structural detail information in the motion image frame.

[0100] In an embodiment of the present invention, an image can be divided into foreground and background by setting one or more thresholds. For example, a color threshold is used to segment pixels in a denoised image into objects of a specific color to obtain the foreground of the denoised image, i.e., the target image frame.

[0101] The motion posture recognition module 103 is used to calculate the motion joint information in each of the target image frames, and recognize the motion posture of each of the motion image frames according to the motion joint information.

[0102] In an embodiment of the present invention, the motion joint information is the spatial information of the human body joints in the target image frame. The motion joint information can be used to determine the joint information of the user when exercising in the target image frame, and thus the motion posture of the user in each target image frame can be determined based on the motion joint information.

[0103] In the embodiment of the present invention, the step of calculating the motion joint information in each target image frame includes:

[0104] Convolution and normalization are performed on each of the target image frames to obtain a normalized feature map, and multi-head self-attention calculation is performed on the normalized feature map to obtain an attention feature map;

[0105] Performing a residual connection between the attention feature map and the normalized feature map to obtain a residual feature map;

[0106] Performing full connection on the residual feature map to obtain a fully connected feature map, and performing residual connection on the fully connected feature map and the residual feature map to obtain a target feature map;

[0107] The motion joints are identified according to the target feature map to obtain the motion joint information in the target image frame.

[0108] In an embodiment of the present invention, convolution and normalization are to convolve the target image frame to obtain a convolution feature map corresponding to the target image frame, and then normalize the convolution feature map to obtain a normalized feature map. Through multi-head self-attention, multiple heads can be used to jointly model information from various representation subspaces from different positions to obtain an attention feature map. Then, the residual feature map obtained by residual connection can learn different information about each joint point or joint point movement in the target image frame, such as the depth information of a joint point or the degree of influence of other joint point movements on it, so as to improve the accuracy of subsequent motion joint recognition.

[0109] In an embodiment of the present invention, feature information in the residual feature map can be further extracted through the fully connected feature map, and the fully connected feature map is residually connected with the residual feature map to obtain a target feature map with deeper and more comprehensive feature information. The target feature map is then used to perform activation calculations to identify motion joint information in each target image frame, such as joint categories, joint coordinates, etc.

[0110] In an embodiment of the present invention, the main joints of the human body during exercise, such as elbow joints, finger joints, knee joints, etc., can be identified through motion joint information, and the motion joints in the target image frame are connected according to the motion joint information to obtain the joint posture of the human body during exercise, that is, the motion posture of the user in each target image frame.

[0111] In an embodiment of the present invention, by identifying the motion posture of each motion image frame, the motion state of the user in each motion image frame in the motion image frame sequence can be determined, and then the posture changes of the user on the treadmill can be identified according to the motion posture of each frame, so that interaction can be performed more naturally during exercise, thereby improving the effect of motion interaction.

[0112] The motion trajectory calculation module 104 is used to construct a motion posture sequence of the motion image frame sequence according to the motion posture, and calculate the motion trajectory of the motion image frame sequence according to the motion posture sequence.

[0113] In an embodiment of the present invention, the motion posture corresponding to each motion image frame is sorted in time series to obtain a motion posture sequence. The motion trajectory is the motion trajectory of each motion joint in the motion image frame sequence. The motion information of each motion joint can be identified through the motion trajectory, and then the possible motion interaction information can be more accurately identified according to the motion trajectory, thereby improving the effect of motion interaction.

[0114] In an embodiment of the present invention, the step of calculating the motion trajectory of the motion image frame sequence according to the motion posture sequence includes:

[0115] Extracting the joint coordinates of each motion joint in the motion posture sequence to obtain a joint coordinate sequence;

[0116] Calculate the trajectory vector sequence of the motion joint according to the joint coordinate sequence;

[0117] The motion trajectory of the motion image frame sequence is drawn according to the trajectory vector sequence and the joint coordinate sequence.

[0118] In the embodiment of the present invention, the motion trajectory of the motion image frame sequence is the motion trajectory of each motion joint, which can be constructed by the change relationship of the joint coordinates of each motion joint, that is, it can be determined according to the vector angle of the joint coordinates. Among them, the trajectory vector is a two-dimensional direction vector constructed according to the joint coordinates, and the motion direction of the same motion joint in adjacent motion image frames can be calculated by the trajectory vector, and further the motion trajectory of each motion joint can be drawn.

[0119] In an embodiment of the present invention, the trajectory vector can reflect the movement direction between the joint coordinates of each moving joint. For example, the trajectory vector is the joint coordinates of the moving joint from the joint coordinates (a, b) to the joint coordinates (c, d), which means that the moving joint moves from the coordinates (a, b) to the coordinates (c, d). The joint coordinate sequence of each moving joint is connected by the trajectory vector to obtain the motion trajectory of each moving joint. Therefore, the motion trajectory of each moving joint in the motion image frame sequence can be drawn by the trajectory vector sequence.

[0120] In an embodiment of the present invention, the motion information of the user in the motion image frame sequence can be more accurately identified through the motion trajectory, for example, the changes in the user's posture when running, so that the user's motion state and interaction needs during exercise can be accurately identified, and better motion interaction effects can be obtained.

[0121] The motion interaction module 105 is used to calculate the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, and use the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene.

[0122] In the embodiment of the present invention, since the posture of the human body is composed of the torso as the main trunk, and the motion joints are not isolated, but are physically connected to each other, the motion relationship between different motion postures can be learned through the motion trajectory to obtain the user's motion strategy during exercise, for example, the user is walking, backward, running, accelerating, and moving at a constant speed, so as to better adapt to the user's running.

[0123] In an embodiment of the present invention, the step of calculating the motion strategy corresponding to the motion image frame sequence according to the motion trajectory includes:

[0124] Linearly mapping the node coordinates of each motion joint in the motion trajectory to obtain position coordinate features;

[0125] Performing spatial feature encoding on the position coordinate feature to obtain a coding feature;

[0126] A motion strategy corresponding to the motion image frame sequence is calculated according to the encoding feature.

[0127] In an embodiment of the present invention, linear mapping is to map the node coordinates of each motion joint to a high-dimensional space. Linear mapping can be performed using trainable linear projection to obtain the position coordinate information of each node coordinate, that is, spatial position embedding is performed on the coordinates of each motion joint. Spatial feature encoding is to integrate the motion information of all motion joints using a self-attention mechanism, and then the motion relationship between different motion postures can be learned through motion trajectories. The motion strategy of the motion image frame sequence is further classified using the encoded features to obtain the motion strategy corresponding to the motion image frame sequence.

[0128] Specifically, a fully connected layer can be set after the spatial feature encoding layer, and the encoded features can be classified through the activation function in the fully connected layer. For example, if the motion strategy is that the user is walking, it means that the user is walking in the motion image frame sequence. The motion mode of the treadmill can be set to walking to adapt to the user's user mode in real time.

[0129] The spatial feature encoding may be composed of multiple layers of encoders. Specifically, the spatial feature encoding of the position coordinate feature may be performed using the following formula to obtain the encoding feature: in, Indicates The encoded features of the layer, represents the attention mechanism, Representation layer normalization operation, Indicates The encoded features of the layer, Represents the total number of coding layers for spatial feature encoding, Represents the encoding feature.

[0130] In the embodiment of the present invention, the step of using the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene includes:

[0131] Extracting a virtual motion joint in the virtual scene, and controlling the motion trajectory of the virtual motion joint according to the motion trajectory to obtain a trajectory interaction scene;

[0132] Setting a virtual motion strategy of the virtual scene according to the motion strategy to obtain a strategy interaction scene;

[0133] The virtual scene is subjected to scene interaction according to the trajectory interaction scene and the strategy interaction scene to obtain a motion interaction scene corresponding to the virtual scene.

[0134] In an embodiment of the present invention, the virtual motion joints are the motion joints corresponding to the moving characters in the virtual scene, for example, the motion joints in the three-dimensional virtual characters. The motion of the moving characters in the virtual scene is controlled through motion trajectories, so that real-time motion interaction can be performed on the virtual motion targets in the treadmill virtual scene according to the actual motion trajectory of the user, thereby improving the sense of reality during motion interaction; the strategy scene interaction is to control the motion model of the treadmill according to the motion strategy, for example, the motion mode of the treadmill is controlled to be walking, or the user accelerates to run on the treadmill, etc., and the motion mode in the virtual motion scene is synchronously controlled at the same time, and the panoramic somatosensory system of the treadmill can be adaptively controlled in motion mode, which can ensure that the user's gait is natural and the posture is stable during somatosensory motion interaction, and meet the needs of the treadmill during motion interaction.

[0135] Reference Figure 4 FIG. 1 is a flow chart of a treadmill panoramic somatosensory exercise method based on augmented reality provided by an embodiment of the present invention. In this embodiment, the treadmill panoramic somatosensory exercise method based on augmented reality includes:

[0136] S1, obtaining a panoramic image of a treadmill, identifying a virtual moving target in the panoramic image, and constructing a virtual scene of the treadmill according to the virtual moving target;

[0137] S2, collecting the motion image frame sequence of the panoramic somatosensory of the treadmill, performing image denoising and background segmentation on each motion image frame in the motion image frame sequence, and obtaining a target image frame;

[0138] S3, calculating the motion joint information in each of the target image frames, and identifying the motion posture of each of the motion image frames according to the motion joint information;

[0139] S4, performing motion modeling on the motion posture to obtain a motion posture sequence of the motion image frame, and calculating a motion trajectory of the motion image frame sequence according to the motion posture sequence;

[0140] S5. Calculate the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, and use the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene.

[0141] An embodiment of the present invention further provides an electronic device of a treadmill panoramic somatosensory motion system based on augmented reality.

[0142] The electronic device may include a processor, a memory, a communication bus, and a communication interface, and may also include a computer program stored in the memory and executable on the processor, such as an augmented reality-based treadmill panoramic somatosensory exercise program.

[0143] In some embodiments, the processor may be composed of an integrated circuit, for example, it may be composed of a single packaged integrated circuit, or it may be composed of multiple packaged integrated circuits with the same or different functions, including one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and a combination of various control chips.

[0144] The memory includes at least one type of readable storage medium, and the readable storage medium includes a flash memory, a mobile hard disk, a multimedia card, a card-type memory (e.g., an SD or DX memory, etc.), a magnetic memory, a disk, an optical disk, etc. In some embodiments, the memory may be an internal storage unit of an electronic device, such as a mobile hard disk of the electronic device.

[0145] The communication bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. The bus is configured to realize connection and communication between the memory and at least one processor, etc.

[0146] The communication interface is used for communication between the above-mentioned electronic device and other devices, including a network interface and a user interface. Optionally, the network interface may include a wired interface and / or a wireless interface (such as a WI-FI interface, a Bluetooth interface, etc.), which is usually used to establish a communication connection between the electronic device and other electronic devices.

[0147] In the several embodiments provided by the present invention, it should be understood that the disclosed electronic device, apparatus and method can be implemented in other ways. For example, the apparatus embodiment described above is only illustrative, for example, the division of the modules is only a logical function division, and there may be other division methods in actual implementation.

[0148] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0149] In addition, each functional module in each embodiment of the present invention may be integrated into one processing unit, each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional modules.

[0150] It is obvious to those skilled in the art that the present invention is not limited to the details of the above exemplary embodiments, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0151] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention.

Claims

1. A treadmill panoramic somatosensory motion system based on augmented reality, characterized in that: The system includes a virtual scene construction module, an image denoising and background segmentation module, a motion posture recognition module, a motion trajectory calculation module and a motion interaction module, wherein: The virtual scene construction module is used to obtain a panoramic image of the treadmill, identify a virtual moving target in the panoramic image, and construct a virtual scene of the treadmill according to the virtual moving target; The image denoising and background segmentation module is used to collect the motion image frame sequence of the treadmill panoramic somatosensory, perform image denoising and background segmentation on each motion image frame in the motion image frame sequence, and obtain a target image frame; wherein, performing image denoising and background segmentation on each motion image frame in the motion image frame sequence to obtain a target image frame includes: Performing additive Gaussian noise on the motion image frame to obtain a Gaussian noisy image, and performing a first morphological calculation on the Gaussian noisy image to obtain a morphological image; The first morphological calculation is performed on the Gaussian noise image using the following formula to obtain a morphological image: in, Represents the pixel point in the Gaussian noise image The morphological image after opening operation, Represents the pixel point in the Gaussian noise image The pixel value of represents the erosion operation, represents the dilation operation, Represents the pixel point in the Gaussian noise image Morphological images with closing operation; The morphological image of the open operation in the morphological image is used as the open operation image and the morphological image of the closed operation is used as the closed operation image, and the open operation pixel value difference and the closed operation pixel value difference between each pixel point in the Gaussian noisy image and the corresponding pixel points of the open operation image and the closed operation image are calculated respectively; when the open operation pixel value difference is greater than or equal to a preset threshold and the closed operation pixel value difference is zero, or when the closed operation pixel value difference is greater than or equal to the threshold and the open operation pixel value difference is zero, the pixel point is used as a noise pixel point, and a second morphological calculation is performed on the noise pixel point to obtain a denoised image; the denoised image is subjected to background segmentation using a preset threshold to obtain a target image frame; The motion posture recognition module is used to calculate the motion joint information in each of the target image frames, and recognize the motion posture of each of the motion image frames according to the motion joint information; The motion trajectory calculation module is used to perform motion modeling on the motion posture to obtain a motion posture sequence of the motion image frame, and calculate the motion trajectory of the motion image frame sequence according to the motion posture sequence; The motion interaction module is used to calculate the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, and use the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain a motion interaction scene.

2. The treadmill panoramic somatosensory motion system based on augmented reality as claimed in claim 1, characterized in that: When identifying the virtual moving target in the panoramic image, the virtual scene construction module is specifically used to: Performing median filtering on the panoramic image to obtain a filtered image; Converting the filtered image into a binary image, and identifying a target area in the binary image; A color histogram function of the target area is calculated, and a virtual moving target in the panoramic image is identified according to the histogram function.

3. The augmented reality-based treadmill panoramic somatosensory motion system according to claim 2, characterized in that: When the virtual scene construction module identifies the virtual moving target in the panoramic image according to the histogram function, it is specifically used to: Calculating a function distance between the histogram function and a preset target histogram function; The function distance between the histogram function and the preset target histogram function is calculated using the following formula: in, Represents the histogram function With the preset target histogram function The function distance between Indicates The pixel value in the histogram function The function value in Indicates The pixel value is in the target histogram function The function value in ; A virtual moving target in the panoramic image is determined according to the functional distance.

4. The treadmill panoramic somatosensory motion system based on augmented reality as claimed in claim 1, characterized in that: When the image denoising and background segmentation module performs the second morphological calculation on the noise pixel points to obtain the denoised image, it is specifically used to: Performing an opening and closing operation and a closing and opening operation on the noise pixel points respectively to obtain an opening and closing operation pixel value and a closing and opening operation pixel value; Calculating the pixel value average of the opening and closing operation pixel value and the closing and opening operation pixel value; The pixel values ​​of the noise pixels are replaced by the pixel value mean to obtain a denoised image.

5. The treadmill panoramic somatosensory motion system based on augmented reality as claimed in claim 1, characterized in that: When calculating the motion joint information in each of the target image frames, the motion posture recognition module is specifically used to: Convolution and normalization are performed on each of the target image frames to obtain a normalized feature map, and multi-head self-attention calculation is performed on the normalized feature map to obtain an attention feature map; Performing a residual connection between the attention feature map and the normalized feature map to obtain a residual feature map; Performing full connection on the residual feature map to obtain a fully connected feature map, and performing residual connection on the fully connected feature map and the residual feature map to obtain a target feature map; The motion joints are identified according to the target feature map to obtain the motion joint information in the target image frame.

6. The augmented reality-based treadmill panoramic somatosensory motion system according to claim 1, characterized in that: When the motion trajectory calculation module calculates the motion trajectory of the motion image frame sequence according to the motion posture sequence, it is specifically used to: Extracting the joint coordinates of each motion joint in the motion posture sequence to obtain a joint coordinate sequence; Calculate the trajectory vector sequence of the motion joint according to the joint coordinate sequence; The motion trajectory of the motion image frame sequence is drawn according to the trajectory vector sequence and the joint coordinate sequence.

7. The treadmill panoramic somatosensory motion system based on augmented reality as claimed in claim 1, characterized in that: When the motion interaction module calculates the motion strategy corresponding to the motion image frame sequence according to the motion trajectory, it is specifically used to: Linearly mapping the node coordinates of each motion joint in the motion trajectory to obtain position coordinate features; Performing spatial feature encoding on the position coordinate feature to obtain a coding feature; The position coordinate feature is encoded using the following formula to obtain the encoded feature: in, Indicates The encoded features of the layer, represents the attention mechanism, Representation layer normalization operation, Indicates The encoded features of the layer, Represents the total number of coding layers for spatial feature encoding, Represents the encoding feature; A motion strategy corresponding to the motion image frame sequence is calculated according to the encoding feature.

8. The augmented reality-based treadmill panoramic somatosensory motion system according to claim 1, characterized in that: When the motion interaction module uses the motion strategy and the motion trajectory to perform motion interaction on the virtual scene to obtain the motion interaction scene, it is specifically used to: Extracting a virtual motion joint in the virtual scene, and controlling the motion trajectory of the virtual motion joint according to the motion trajectory to obtain a trajectory interaction scene; Setting a virtual motion strategy of the virtual scene according to the motion strategy to obtain a strategy interaction scene; The virtual scene is subjected to scene interaction according to the trajectory interaction scene and the strategy interaction scene to obtain a motion interaction scene corresponding to the virtual scene.

9. A treadmill panoramic somatosensory exercise method based on augmented reality, characterized in that: The method comprises: Acquire a panoramic image of a treadmill, identify a virtual moving target in the panoramic image, and construct a virtual scene of the treadmill according to the virtual moving target; The motion image frame sequence of the treadmill panoramic somatosensory image is collected, and each motion image frame in the motion image frame sequence is subjected to image denoising and background segmentation to obtain a target image frame; wherein the image denoising and background segmentation are performed on each motion image frame in the motion image frame sequence to obtain a target image frame, including: Performing additive Gaussian noise on the motion image frame to obtain a Gaussian noisy image, and performing a first morphological calculation on the Gaussian noisy image to obtain a morphological image; The first morphological calculation is performed on the Gaussian noise image using the following formula to obtain a morphological image: in, Represents the pixel point in the Gaussian noise image The morphological image after opening operation, Represents the pixel point in the Gaussian noise image The pixel value of represents the erosion operation, represents the dilation operation, Represents the pixel point in the Gaussian noise image Morphological images with closing operation; The morphological image of the open operation in the morphological image is used as the open operation image and the morphological image of the closed operation is used as the closed operation image, and the open operation pixel value difference and the closed operation pixel value difference between each pixel point in the Gaussian noisy image and the corresponding pixel points of the open operation image and the closed operation image are calculated respectively; when the open operation pixel value difference is greater than or equal to a preset threshold and the closed operation pixel value difference is zero, or when the closed operation pixel value difference is greater than or equal to the threshold and the open operation pixel value difference is zero, the pixel point is used as a noise pixel point, and a second morphological calculation is performed on the noise pixel point to obtain a denoised image; the denoised image is subjected to background segmentation using a preset threshold to obtain a target image frame; Calculating motion joint information in each of the target image frames, and identifying the motion posture of each of the motion image frames according to the motion joint information; Performing motion modeling on the motion posture to obtain a motion posture sequence of the motion image frames, and calculating a motion trajectory of the motion image frame sequence according to the motion posture sequence; The motion strategy corresponding to the motion image frame sequence is calculated according to the motion trajectory, and the motion strategy and the motion trajectory are used to perform motion interaction on the virtual scene to obtain a motion interaction scene.