Game behavior detection method and device, electronic equipment and computer storage medium
Through game behavior detection methods, users' posture feature data and standard posture data are obtained, and users are evaluated and guided to perform standardized health care exercises, solving the fatigue problems caused by users watching videos or playing games for a long time, and achieving fatigue relief and fun improvement.
Patent Information
- Application Number
- CN202510834544.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-20
- Publication Date
- 2025-08-01
AI Technical Summary
Users can easily cause physical fatigue and damage by watching videos or playing games for a long time, increasing the chance of disease.
Through game behavior detection methods, users' posture feature data and standard posture data within the preset time period are obtained, users' health care exercise effects are evaluated, and users are guided to perform health care exercises in a more standardized way to relieve fatigue and increase fun.
Effectively alleviate users' physical fatigue, reduce the chance of disease, and improve the fun and standardization of health care exercises.
Smart Images

Figure CN120393434A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of in-vehicle applications, and particularly to a game behavior detection method, device, electronic device, and computer storage medium. Background Art
[0002] With the continuous development of the new energy vehicle technology field, users not only pay attention to the quality of the vehicle but also the comfort of riding in the vehicle. Based on this, in order to improve the user's riding experience during a long journey, currently, multiple display screens are configured in the vehicle, and users can watch videos or play games through the multiple display screens or mobile devices.
[0003] However, if users watch videos or play games for a long time, it is easy to cause physical fatigue and damage to users, thus increasing the probability of physical diseases. Summary of the Invention
[0004] In view of this, this application provides a game behavior detection method, device, electronic device, and computer storage medium, which can solve the problem in the prior art that if users watch videos or play games for a long time, it is easy to cause physical fatigue and damage to users.
[0005] The first aspect of this application discloses a game behavior detection method, and the method includes: In response to a game running instruction, obtain first posture feature data and first standard posture data within a preset time period. The first posture feature data represents the movement trajectory between a first body part and a second body part when a first user performs a health care exercise. The first standard posture data represents the movement trajectory between a third body part and a fourth body part in a standard posture. The first body part is the same as the third body part, and the second body part is the same as the fourth body part; in response to a game end instruction, based on the first posture feature data and the first standard posture data within the preset time period, determine a game result corresponding to the first user.
[0006] Compared with the related art, the embodiments of this application have at least the following advantages: Guide users to perform health care exercises in the form of a game, and based on the comparison between the user's action posture and the standard posture, evaluate the effect of the user performing health care exercises in the form of a game, prompting the user to perform health care exercises in a more standardized manner to relieve the physical fatigue and damage of the first user, reduce the probability of physical diseases, and increase the fun during health care exercises.
[0007] In some possible implementation manners, determining a game result corresponding to the first user based on the first posture feature data and the first standard posture data within the preset time period includes: determining a plurality of first actual movement vectors based on the first posture feature data, where the first actual movement vectors are vectors formed according to the first key points of the first body part and the second key points of the second body part; determining a plurality of first standard movement vectors based on the first standard posture data, where the first standard movement vectors are vectors formed according to the third key points of the third body part and the fourth key points of the fourth body part, the positions of the first key points on the first body part are the same as the positions of the third key points on the third body part, and the positions of the second key points on the second body part are the same as the positions of the fourth key points on the fourth body part; determining a game result corresponding to the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors, where the game result is obtained by performing a matching calculation based on the similarity between the plurality of first actual movement vectors and the plurality of first standard movement vectors.
[0008] In some possible implementation manners, determining a game result corresponding to the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors includes: determining a health exercise intensity score of the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors, where the health exercise intensity score is a value calculated according to the magnitudes of the plurality of first actual movement vectors and the plurality of first standard movement vectors; determining a health exercise score of the first user based on the health exercise intensity score and the action matching degree score between the plurality of first actual movement vectors and the plurality of first standard movement vectors.
[0009] In some possible implementation manners, determining the health exercise intensity score of the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors includes: obtaining a plurality of actual component vectors of the plurality of first actual movement vectors perpendicular to the plane where the face of the first user is located; obtaining a plurality of standard component vectors of the plurality of first standard movement vectors perpendicular to the plane where the face of the user is located in the standard posture; determining the health exercise intensity score of the first user based on the plurality of actual component vectors and the plurality of standard component vectors.
[0010] In some possible implementation manners, the game behavior detection method further includes: determining the similarity between a plurality of the first actual movement vectors and a plurality of the first standard movement vectors; determining an action matching degree score between the plurality of the first actual movement vectors and the plurality of the first standard movement vectors based on the similarity between the plurality of the first actual movement vectors and the plurality of the first standard movement vectors.
[0011] In some possible implementation manners, the game behavior detection method further includes: determining a difference vector between a plurality of the first actual movement vectors and a plurality of the first standard movement vectors; if the difference vector is not within a preset posture deviation range, outputting health care exercise guidance content to guide the first user to perform health care exercises.
[0012] In some possible implementation manners, the determining manner of the posture deviation range includes: obtaining the spatial region where the first user is located; determining the region size of the spatial region to obtain the posture deviation range matching the region size.
[0013] In some possible implementation manners, before obtaining the first posture feature data within a preset time period in response to a game running instruction, the method includes: obtaining the sitting duration of the first user; generating a game start confirmation message when the sitting duration is greater than a preset duration threshold, where the game start confirmation message is used to remind the first user whether to start a game matching the health care exercise; generating the game running instruction in response to a game confirmation operation for confirming to start the health care exercise game.
[0014] A second aspect of the present application discloses a game behavior detection device, where the device includes: an obtaining module, configured to obtain first posture feature data and first standard posture data within a preset time period in response to a game running instruction, where the first posture feature data represents the movement trajectory between a first body part and a second body part when the first user performs a health care exercise, and the first standard posture data represents the movement trajectory between a third body part and a fourth body part in a standard posture when a second user performs the health care exercise, where the first body part is the same as the third body part, and the second body part is the same as the fourth body part; a determining module, configured to determine a game result corresponding to the first user based on the first posture feature data and the first standard posture data within the preset time period in response to a game end instruction.
[0015] A third aspect of the present application discloses an electronic device, where the electronic device includes a processor and a memory, the memory is used to store instructions, and the processor is used to call the instructions in the memory so that the electronic device executes the game behavior detection method as described above.
[0016] The fourth aspect of the present application discloses a computer storage medium, including computer instructions, which when running on an electronic device, cause the electronic device to execute the game behavior detection method as described above.
[0017] It can be understood that the device provided in the second aspect, the electronic device provided in the third aspect, and the computer storage medium provided in the fourth aspect all correspond to the method provided in the first aspect. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be elaborated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 It is a flowchart of steps of a game behavior detection method according to an embodiment of the present application.
[0019] Figure 2 It is a sub - flowchart of a step in the game behavior detection method according to an embodiment of the present application.
[0020] Figure 3 It is another flowchart of steps of the game behavior detection method according to an embodiment of the present application.
[0021] Figure 4 It is a schematic diagram of functional modules of a game behavior detection device according to an embodiment of the present application.
[0022] Figure 5 It is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0023] In order to more clearly understand the above - mentioned objects, features, and advantages of the present application, the present application will be described in detail below with reference to the drawings and specific embodiments. It should be noted that, without conflict, the embodiments of the present application and the features in the embodiments can be combined with each other.
[0024] Many specific details are set forth in the following description in order to fully understand the present application. The described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments.
[0025] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present application belongs. The terms used in the specification of the present application herein are only for the purpose of describing specific embodiments, and are not intended to limit the present application.
[0026] Further, it should be noted that in this text, the term "including", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, such that a process, method, article or device comprising a series of elements not only includes those elements but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising an..." does not exclude the presence of additional identical elements in the process, method, article or device comprising such element.
[0027] In this application, "at least one" means one or more, and "a plurality" means two or more than two. "And / or" describes the association relationship of associated objects and indicates that three relationships may exist. For example, A and / or B may represent: A exists alone, A and B exist simultaneously, and B exists alone, where A and B may be singular or plural. The terms "first", "second", "third", "fourth", etc. (if any) in the specification, claims and drawings of this application are used to distinguish similar objects, rather than to describe a specific order or sequence.
[0028] In the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design solution described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or having more advantages than other embodiments or design solutions. Rather, the use of words such as "exemplary" or "for example" is intended to present relevant concepts in a specific manner.
[0029] The embodiments of this application provide a game behavior detection method, an electronic device and a computer storage medium.
[0030] The game behavior detection method of this application can be applied to one or more electronic devices. The electronic device is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to a processor, a microprogrammed control unit (MCU), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), a digital signal processor (DSP), an embedded device, etc. The electronic device may be a vehicle-mounted processor, such as a vehicle controller, etc., but is not limited thereto.
[0031] The electronic device can be configured in a vehicle and communicatively connected to in-vehicle sensors in the vehicle. The in-vehicle sensors can be, but are not limited to, image sensors, radar sensors, pressure sensors, etc. The sensors can be used to collect internal environment data and vehicle state data of the vehicle, and transmit the internal environment data and vehicle state data to the electronic device. Among them, the vehicle can be a fuel vehicle or a new energy vehicle, and the specific type of the vehicle is not limited in this application.
[0032] In other embodiments, the electronic device can also be configured in other devices other than vehicles. For example, the electronic device can also be configured in a display device in a room, and the display device can be a computer, etc. The embodiments of this application are described by taking the electronic device configured in a vehicle as an example.
[0033] The internal environment data can reflect the situation of the passengers in the vehicle. The internal environment data can include, but is not limited to, the inner side image and point cloud data of the vehicle collected by the in-vehicle sensors. The vehicle state data can reflect the current state of the vehicle. For example, the driving speed of the vehicle and the force data of the cockpit, etc.
[0034] The game behavior detection method of the embodiments of this application can guide the user located in the vehicle to perform health care exercises, and trigger the vehicle to execute corresponding game operations. Thus, while alleviating the physical fatigue of the user, it can also increase the interest of health care exercises.
[0035] The game behavior detection method includes: in response to a game running instruction, obtaining first pose feature data and first standard pose data within a preset time period. The first pose feature data represents the movement trajectory between a first body part and a second body part when the first user performs a health care exercise. The first standard pose data represents the movement trajectory between a third body part and a fourth body part in a standard pose. The first body part of the first user is the same as the third body part of the second user, and the second body part of the first user is the same as the fourth body part of the second user; in response to a game end instruction, determining a game result corresponding to the first user based on the first pose feature data and the first standard pose data within the preset time period.
[0036] The embodiments of this application guide the user to perform health care exercises in the form of a game, and can evaluate the effect of the user performing health care exercises in the form of a game based on the comparison between the user's action posture and the standard posture, prompting the user to perform health care exercises in a more standardized manner, so as to relieve the physical fatigue and injuries of the first user, reduce the occurrence probability of physical diseases, and increase the interest during health care exercises.
[0037] Please refer to Figure 1 , the embodiments of this application provide a game behavior detection method. The game behavior detection method includes the following steps: Step 101: In response to a game running instruction, obtain first posture feature data and first standard posture data within a preset time period.
[0038] In some embodiments, the first posture feature data represents the movement trajectory between a first body part and a second body part when a first user performs a health care exercise. The first standard posture data represents the movement trajectory between a third body part and a fourth body part in a standard posture. For example, the first standard posture data represents the standard posture formed when a second user performs a health care exercise. At this time, it is the movement trajectory between the third body part and the fourth body part in the standard posture.
[0039] In this embodiment, the first body part of the first user is the same as the third body part of the second user, and the second body part of the first user is the same as the fourth body part of the second user. The first user is a passenger in a vehicle, and the second user is a model. That is, obtain the movement trajectory of the first user performing a health care exercise and the movement trajectory of the model performing a health care exercise within a preset time period.
[0040] In this embodiment, taking the health care exercise as eye exercises, the first body part is the hand of the first user, the second body part is the head of the first user, the third body part is the hand of the second user, and the fourth body part is the head of the second user as an example. In other embodiments, the health care exercise in the embodiments of the present application can also be other exercises except eye exercises, such as shoulder exercises. The first body part can also be the shoulder, and the second body part is the hand. The present application does not limit the type of the health care exercise and the specific names of the first body part and the second body part.
[0041] Specifically, the first posture feature data represents the movement trajectory between a first key point of the first body part and a second key point of the second body part. The first standard posture data represents the movement trajectory between a third key point of the third body part and a fourth key point of the fourth body part. The position of the first key point on the first body part of the first user is the same as the position of the third key point on the third body part of the second user, and the position of the second key point on the second body part of the first user is the same as the position of the fourth key point on the fourth body part of the second user.
[0042] Correspondingly, the first key point includes but is not limited to the fingertip, finger joint, and wrist joint. The second key point includes but is not limited to the center of the eyebrows, the corners of the eyes, the outer corners of the eyes, and the tip of the nose. The preset time period can be the time period from the start of the health care exercise game to the end of a health care exercise game, or the preset time period can also be other specified time periods. The present application does not limit the specific content of the first key point and the second key point, as well as the specific value of the preset time period, which can be set according to the actual situation.
[0043] Since the embodiments of the present application are described by taking eye exercises as an example, the first key point in this embodiment can be the fingertip, and the second key point can be the key points of the eyes. For example, the key points of the eyes can include but are not limited to Tianying Point, Jingming Point, Taiyang Point, and Sibai Point. Similarly, the third key point is the fingertip of the second user, and the fourth key point is the key points of the eyes of the second user.
[0044] In some embodiments, in order to improve the operation efficiency of the game behavior detection method of the embodiments of the present application, before performing step 101, the following operations can also be performed: obtaining the sitting posture duration of the first user located in the vehicle. When the sitting posture duration is greater than the preset duration threshold, generating a game operation instruction. When the sitting posture duration is not greater than the preset duration threshold, no game operation instruction is generated. Among them, the preset duration threshold can be half an hour, 1 hour, or 1.5 hours, which can be set according to actual needs. The force data of the seat where the first user is located can be determined through the vehicle state data collected by the in-vehicle sensor, and thus, according to the force data, the sitting posture duration of the first user can be determined.
[0045] When the sitting posture duration of the first user in the vehicle is greater than the preset duration threshold, it indicates that the first user has been sitting in the vehicle for a long time. To avoid the first user from experiencing physical fatigue, a game movement instruction can be generated. Then, the game behavior detection method of the embodiments of the present application is executed to guide the first user to do eye exercises to help the first user relieve eye fatigue.
[0046] Specifically, when the sitting posture duration is greater than the preset duration threshold, a game start confirmation message is generated. The game start confirmation message is used to remind the first user whether to start a game matching the health care exercise. For example, the game start confirmation message includes a confirmation start button and a confirmation not to start button. When the first user clicks the confirmation start button, the vehicle responds to the game confirmation operation of confirming the start of the health care exercise and generates a game operation instruction. When the first user clicks the confirmation not to start button, the vehicle does not generate a game operation instruction.
[0047] In some instances, the game start confirmation message can be a pop-up window or a button icon displayed on the in-vehicle entertainment display screen, or it can be a voice message. The type of the game start confirmation message is not specifically limited in this embodiment.
[0048] Furthermore, it can also be that when the sitting posture duration is greater than the preset duration threshold, the image information containing the first user is further collected, and the image information is analyzed to obtain the age data of the first user. If the age data is not greater than the preset age threshold, a game operation instruction is generated. Among them, the preset age threshold can be 10 years old or 16 years old, which can be set according to the actual situation.
[0049] Meanwhile, after performing image analysis on the image information, the status information of the first user can also be obtained. The status information includes that the first user is in a waking state and the first user is in a sleeping state. When the age data is within the preset age threshold and the status information indicates that the first user is in a waking state, a game running instruction is generated.
[0050] When the sitting duration is greater than the preset duration threshold, the age data is not greater than the preset age threshold, and the status information indicates that the first user is in a waking state, it indicates that the first user is a child and the child is in a waking state (possibly reading a book or playing with electronic products). To avoid the situation where the child's body gets fatigued due to reading a book or playing with electronic products for a long time, the game behavior detection method of the present application embodiment is executed to guide the child to do eye exercises to help the child relieve eye fatigue and thus prevent the child's vision from declining.
[0051] In other embodiments, the preset age threshold may further include a first age threshold and a second age threshold. Among them, the first age threshold may be 25 years old or 30 years old, and the second age threshold may be 40 years old or 45 years old. If the sitting duration is greater than the preset duration threshold, the age data is greater than the first age threshold, and the age data is less than the second age threshold, it indicates that the first user is a young person. Due to reasons such as work pressure, the young person needs to look down at the computer or mobile phone for a long time. To avoid the situation of physical fatigue, a game running instruction is generated. Thus, the young person is guided to do eye exercises to help the young person relieve eye fatigue and thus prevent the young person's vision from declining.
[0052] Step 102: In response to the game end instruction, based on the first pose feature data and the first standard pose data within a preset time period, determine the game result corresponding to the first user.
[0053] In some embodiments, to ensure the user's game experience, the game generally sets a corresponding duration. When the game ends, a game end instruction can be generated. For example, taking eye exercises as an example, it can be set that the game ends after performing a complete set of eye exercises. Based on the game behavior of the first user within the preset time period, determine the game result corresponding to the first user.
[0054] In some embodiments, the game may also have multiple levels, and each level corresponds to a corresponding time. If the current level ends, a game end instruction can be generated. Based on the game behavior of the first user in the current level, determine the game result corresponding to the first user.
[0055] In some embodiments, the game result may be one or more of the score of the game, the level / title obtained of the game ability, whether the game is cleared, etc. The embodiments of the present application do not limit the specific manifestation form of the game result. In some embodiments, the game result corresponding to the first user can be determined by comparing the first posture feature data within a preset time period with the first standard posture data.
[0056] In some embodiments, in order to ensure the game effect of the user, the first posture feature data may also be set as the movement trajectory between the first body part and the second body part when the first user performs a health care exercise after a period of health care exercise guidance and at the time point after the game starts. For example, it can be set that the health care exercise game includes a guidance stage and a game stage. The guidance stage plays the health care exercise guidance content to facilitate the first user's action learning of the health care exercise. After the guidance stage, the game stage is carried out, and the game effect of the user's health care exercise is evaluated only in the game stage. The game stage may or may not play the health care exercise guidance content. Correspondingly, the first posture feature data may be the posture feature data in the game stage.
[0057] Compared with the related art, the embodiments of the present application have at least the following advantages: In response to the game operation instruction, the user is guided to perform a health care exercise in a game manner, and the effect of the user's health care exercise in a game manner can be evaluated based on the comparison between the user's action posture and the standard posture. Based on the game effect, the user is urged to perform the health care exercise in a more standardized manner to relieve the physical fatigue and injury of the first user, reduce the occurrence probability of physical diseases, and increase the interest during the health care exercise.
[0058] Please refer to Figure 2 , Figure 2 which is another flow schematic diagram of the game behavior detection method provided by the embodiments of the present application, and is used to determine the game result corresponding to the first user based on the first posture feature data and the first standard posture data. Figure 2 These are the execution steps when the first posture feature data and the first standard posture data are vectors. In other embodiments, the first posture feature data and the first standard posture data may also be data formed by multiple discrete points, as long as it is ensured that the movement trajectory of the user during the health care exercise can be obtained based on the data formed by the multiple discrete points.
[0059] The specific steps include: Step 201: Determine a plurality of first actual movement vectors based on the first posture feature data.
[0060] Among them, the first actual movement vector is a vector formed according to the first key point of the first body part and the second key point of the second body part when the first user performs a health care exercise. Specifically, in one embodiment, the first actual movement vector may be a vector formed from the first key point to the second key point. In other embodiments, the first actual movement vector may also be a vector formed from the second key point to the first key point.
[0061] Step 202: Determine a plurality of first standard movement vectors based on the first standard posture data.
[0062] Among them, the first standard movement vector is a vector formed according to the third key point of the third body part and the fourth key point of the fourth body part.
[0063] Specifically, in one embodiment, the first standard movement vector may be a vector formed from the third key point to the fourth key point.
[0064] In other embodiments, the first standard movement vector may be a vector formed from the fourth key point to the third key point.
[0065] This application does not limit the specific directions of the first actual movement vector and the first standard movement vector, as long as it is ensured that the starting point of the first actual movement vector at the position of the first user is the same as the starting point of the first standard movement vector at the position of the second user, and the ending point of the first actual movement vector at the position of the first user is the same as the ending point of the first standard movement vector at the position of the second user.
[0066] Within a preset time period, different first actual movement vectors and first standard movement vectors corresponding to different time points within the preset time period can be obtained. That is to say, both the first actual movement vector and the first standard movement vector in this embodiment are position vectors that change with the time point.
[0067] In this embodiment, when the first key point is the fingertip and the second key point is the eye key point, the first actual movement vector is a vector formed by the fingertip and the eye key point of the first user. The first standard movement vector is a vector formed by the fingertip and the eye key point of the second user.
[0068] That is to say, the first actual movement vector is a vector from the fingertip of the first user to the eye key point of the first user, and the first characterization movement vector is a vector from the fingertip of the second user to the eye key point of the second user.
[0069] Specifically, the steps for determining the first actual movement vector include: obtaining, within a preset time period, the first key point of the first body part and the second key point of the second body part when the first user performs a health care exercise; establishing a body coordinate system based on the second key point and obtaining the part coordinates of the first key point in the body coordinate system; performing coordinate transformation on the part coordinates to obtain the first actual movement vector in the earth coordinate system.
[0070] Within the preset time period, different first actual movement vectors corresponding to different time points can be obtained. That is to say, the first actual movement vector in this embodiment is a position vector that changes continuously with the time point, and the first actual movement vector represents the movement trajectory of the first body part relative to the second body part.
[0071] In this embodiment, the second key point can be selected to establish a head coordinate system. For example, taking the center of the eyebrows as the origin, the line from the left ear to the right ear as the X-axis, the line from the chin to the top of the head as the Y-axis, and the line from the face to the back of the head as the Z-axis, the head coordinate system is obtained. This head coordinate system moves and rotates with the movement of the head, but always takes the head as the reference.
[0072] The part coordinates (i.e., three-dimensional coordinates) of the first key point in the head coordinate system are determined through the internal environment data. This part coordinate represents the movement of the hand relative to the head, excluding the interference of the head's own movement. For the convenience of subsequent calculations, coordinate transformation is performed on the part coordinates to obtain the first actual movement vector in the earth coordinate system. The first actual movement vector in this embodiment represents the movement trajectory of the hand relative to the head when the first user performs an eye exercise.
[0073] In this way, by establishing a fixed head coordinate system to eliminate the influence of head movement and then converting the hand movement to the earth coordinate system, the movement law of the hand in the real environment can be observed more clearly.
[0074] Similarly, the first standard movement vector can be determined by referring to the method of the first actual movement vector. Since the first standard posture data represents the movement trajectory between the third body part and the fourth body part in the standard posture, the first standard movement vector can be pre-calculated and stored in the vehicle. For example, both the first standard posture data and the first standard movement vector can be saved in the game file of the health care exercise. After the vehicle installs the game of this health care exercise, the vehicle stores the first standard posture data and the first standard movement vector.
[0075] Step 203: Determine the game result corresponding to the first user based on multiple first actual movement vectors and multiple first standard movement vectors.
[0076] In some embodiments, the game result can be calculated based on the matching degree between the health care exercise intensity and actions between multiple first actual movement vectors and multiple first standard movement vectors. For example, the game result is a health care exercise score, and the health care exercise score can be obtained by weighting the health care exercise intensity score and the action matching degree score.
[0077] In this embodiment, determining the game result corresponding to the first user based on multiple first actual movement vectors and multiple first standard movement vectors may specifically include: (1) Based on multiple first actual movement vectors and multiple first standard movement vectors, determine the health care exercise intensity of the first user, and the health care exercise intensity is determined according to the magnitude of multiple first actual movement vectors and multiple first standard movement vectors.
[0078] (2) Based on the health care exercise intensity and the action matching degree between multiple first actual movement vectors and multiple first standard movement vectors, determine the game result corresponding to the first user.
[0079] In some embodiments, taking the game result as the health care exercise score as an example, determining the game result corresponding to the first user based on multiple first actual movement vectors and multiple first standard movement vectors may specifically include: determining the health care exercise intensity score of the first user based on multiple first actual movement vectors and multiple first standard movement vectors; determining the health care exercise score of the first user based on the health care exercise intensity and the action matching degree score between multiple first actual movement vectors and multiple first standard movement vectors.
[0080] In some embodiments, the action matching degree score can be determined in the following manner: determine the similarity between multiple first actual movement vectors and multiple first standard movement vectors; based on the similarity between multiple first actual movement vectors and multiple first standard movement vectors, determine the action matching degree score between multiple first actual movement vectors and multiple first standard movement vectors.
[0081] In some embodiments, determining the health care exercise intensity score of the first user based on multiple first actual movement vectors and multiple first standard movement vectors may specifically include: (1) Obtain multiple actual component vectors of multiple first actual movement vectors perpendicular to the plane where the first user's face is located.
[0082] In this embodiment, the actual component vector is a sub-vector of the first actual movement vector, and the actual component vector is related to the pressing force of the hand relative to the head when the first user does eye exercises.
[0083] (2) Obtain multiple standard sub-vectors where multiple second standard movement vectors are perpendicular to the plane where the user's face is located in the standard posture.
[0084] Similarly, the standard sub-vector is a sub-vector of the second standard movement vector, and the standard sub-vector is related to the pressing force of the hand relative to the head when the second user does eye exercises.
[0085] (3) Determine the health care exercise intensity score of the first user based on multiple actual sub-vectors and multiple standard sub-vectors.
[0086] In some embodiments, the health care exercise intensity score can be determined based on the magnitudes of multiple actual sub-vectors and multiple standard sub-vectors.
[0087] Wherein, the health care exercise intensity score is a value calculated based on the magnitudes of multiple actual sub-vectors and multiple standard sub-vectors.
[0088] In some embodiments, calculate multiple differences between the actual sub-vector and the standard sub-vector. Calculate the average value of the multiple differences. Based on the average value and the standard sub-vector, calculate the health care exercise intensity score.
[0089] In this embodiment, the health care exercise intensity score can be calculated according to the following formula: , Wherein, S1 represents the health care exercise intensity score, represents the actual sub-vector, represents the standard sub-vector, avg.() is the average value function, and ABS() is the absolute value function.
[0090] In some embodiments, by calculating the similarity between the first actual movement vector and the first standard movement vector, determine the action matching degree score based on the similarity, and then calculate the health care exercise score based on the health care exercise intensity score and the action matching degree score.
[0091] In this embodiment, the Dynamic Time Warping (DTW) algorithm can be used to calculate the similarity between the first actual movement vector and the first standard movement vector.
[0092] The DTW algorithm uses the method of dynamic programming to find the optimal matching path between two time series, so that they can be aligned as much as possible on the time axis, thereby calculating the similarity metric between them. It allows the time series to stretch and distort on the time axis to adapt to different speed and rhythm changes, overcoming the problems of traditional methods such as the Euclidean distance being sensitive to the length and speed of the time series.
[0093] In other embodiments, algorithms other than the DWT algorithm can also be used to calculate the similarity between the first actual motion vector and the first standard motion vector, and the present application does not limit this.
[0094] Further, based on the health exercise intensity score and the action matching degree score, calculating the health exercise score may specifically include: calculating the first product of the health exercise intensity score and the first preset coefficient. Calculating the second product of the action matching degree score and the second preset coefficient. Taking the sum of the first product and the second product as the health exercise score.
[0095] Wherein, the sum of the first preset coefficient and the second preset coefficient is equal to the preset total value, the first preset coefficient is related to the hand strength of the first user when doing health exercises, and the second preset coefficient is related to the action matching degree of the first user when doing health exercises.
[0096] In this embodiment, the preset total value is 1. In other embodiments, the preset total value can also be 2, 3, or 5, which can be set according to actual detection requirements.
[0097] It should be noted that if more importance is attached to the hand strength of the user when doing health exercises, the first preset coefficient can be set to be greater than the second preset coefficient. If more importance is attached to the action matching degree of the user when doing health exercises, the first preset coefficient can be set to be less than the second preset coefficient. If both the hand strength and the action matching degree of the user when doing health exercises are emphasized, the first preset coefficient can be set to be equal to the second preset coefficient.
[0098] The present application first calculates the health exercise intensity score based on the obtained actual sub-vector and standard sub-vector, so that the hand strength of the first user when doing health exercises can be represented by the health exercise intensity score. Then, calculate the similarity between the first actual motion vector and the first standard motion vector, and determine the action matching degree score based on the similarity, so as to represent the action matching degree of the first user when doing health exercises through the action matching degree score. Finally, calculate the health exercise score based on the health exercise intensity score and the action matching degree score to represent the overall performance of the first user when doing health exercises.
[0099] Please refer to Figure 3 , another embodiment of the present application provides a game behavior detection method. Compared with Figure 1 , the game behavior detection method of the present application can also output health exercise guidance content to implement the health exercise teaching of users and guide users to do health exercises more standardly. The game behavior detection method includes the following steps: Step 301, in response to the game running instruction, obtain the first pose feature data and the first standard pose data within a preset time period.
[0100] Step 301 of the embodiments of the present application is similar to Step 101 of the foregoing embodiments. To avoid repetition, it will not be elaborated here.
[0101] Step 302: Determine the difference data between the first attitude feature data and the first standard attitude data.
[0102] In some embodiments, the difference data between the first attitude feature data and the first standard attitude data can also be calculated to facilitate subsequent judgment on whether the actions of the first user's health care exercise are standardized based on the difference data.
[0103] In some embodiments, it can also be evaluated whether the first user is doing eye exercises through the difference data.
[0104] In some embodiments, determining the difference data between the first attitude feature data and the first standard attitude data may specifically include: determining the difference vectors between multiple first actual movement vectors and multiple first standard movement vectors. That is, the difference vectors between multiple first actual movement vectors and multiple first standard movement vectors are used to represent the difference data between the first attitude feature data and the first standard attitude data.
[0105] Step 303: If the difference data is not within the preset attitude deviation range, output health care exercise guidance content to guide the first user to do health care exercises.
[0106] In some embodiments, if the difference data is not within the preset attitude deviation range, it indicates that the actions of the first user's health care exercise are less standardized. At this time, the health care exercise guidance content can be output to guide the first user to do health care exercises. The health care exercise guidance content can be superimposed and displayed on the game screen in the form of a small window. In other embodiments, the health care exercise guidance content can also be played in the form of voice. The present application does not limit the output manner of the health care exercise guidance content.
[0107] In some embodiments, if the difference data is within the preset attitude deviation range, it indicates that the actions of the first user's health care exercise are more standardized. At this time, the health care exercise guidance content may not be output.
[0108] In some embodiments, the health care exercise guidance content can also exist along with the game screen of the health care exercise all the time.
[0109] In some embodiments, the attitude deviation range can be obtained based on the less standardized actions with small amplitudes that occur when the first user is doing health care exercises. In order to enable the attitude deviation range to adapt to the needs of the first user to do health care exercises in different scenarios, the endpoint values of the attitude deviation range can be adjusted.
[0110] Specifically, due to the different sizes of the spaces where users are located, the range of motion deviations allowed for users to perform health care exercises can also be different. That is, the spatial area where the first user is located can be obtained, the area size of the spatial area can be determined, and the range of pose deviations matching the area size can be obtained.
[0111] It can be understood that when the range of motion of the first user during health care exercises is relatively large, the difference between the two endpoint values of the range of pose deviations can be relatively small. When the range of motion of the first user during health care exercises is relatively small, the difference between the two endpoint values of the range of pose deviations can be relatively large. In this way, it can meet the health care exercise requirements in different scenarios.
[0112] That is to say, when the first user is in a vehicle, since the space in the vehicle is relatively small, the difference between the two endpoint values of the range of pose deviations can be set relatively large. When the first user is in a room and the space of the room is relatively large, the difference between the two endpoint values of the range of pose deviations can be set relatively small.
[0113] Step 304, in response to the game end instruction, based on the first pose feature data and the first standard pose data within a preset time period, determine the game result corresponding to the first user.
[0114] Step 304 in the embodiments of the present application is similar to step 102 in the foregoing embodiments. To avoid repetition, it will not be elaborated here.
[0115] In some embodiments, to ensure the user's game experience, it can also be set that only when the difference data is within the preset range of pose deviations, the game effect of the user's health care exercises will be evaluated. For example, only when the difference data is within the preset range of pose deviations, the health care exercise score will be calculated.
[0116] Specifically, after determining the difference data between the first pose feature data and the first standard pose data, the game behavior detection method may further specifically include: (1) If the difference data is within the preset range of pose deviations, obtain the second pose feature data.
[0117] In some embodiments, taking eye exercises as an example of health care exercises, when the difference data is within the range of pose deviations, it indicates that when the first user is doing eye exercises, the distance between the first user's hand and the first user's eyes is within the specified range, and the first user's actions during the health care exercises are relatively standard. The second pose feature data can be obtained starting from the preset sampling frequency until the game ends. Among them, the preset sampling frequency can be 30fps or 40fps, and the present application does not limit the specific value of the preset sampling frequency.
[0118] Conversely, when the difference data is not within the posture deviation range, it indicates that the first user may not be doing eye exercises, or the first user's eye exercise movements are not standardized. In such a case, health exercise guidance content and standard reminder information can be output to remind the first user to do relatively standardized eye exercises following the health exercise guidance content.
[0119] Among them, the standard reminder message can be displayed through the display device in the vehicle to remind the first user to do relatively standardized eye exercises following the health exercise guidance content. At the same time, the voice device in the vehicle can also be combined to prompt the first user on how to make correct movements and prompt again after a period of time without completion.
[0120] In some embodiments, the difference data may include multiple difference vectors. When all the multiple difference vectors are within the movement deviation range, second posture feature data is obtained. Or, when some of the multiple difference vectors are within the movement deviation range, second posture feature data is obtained. Among them, it can be set that the ratio between the number of difference vectors within the movement deviation range and the total number of difference vectors is greater than a preset ratio. The preset ratio can be 80%, 85% or 90%, which can be set according to the actual situation.
[0121] (2) In response to the game end instruction, based on the second posture feature data and the second standard posture data within the preset game time period, determine the game result corresponding to the first user.
[0122] In some embodiments, the preset game time period can be the time period from the start of obtaining the second posture feature data to the end of the game.
[0123] In some embodiments, multiple second actual movement vectors can be determined based on the second posture feature data, and multiple second standard movement vectors can be determined based on the second standard posture data. The determination methods of the second actual movement vectors and the second standard movement vectors can refer to the determination methods of the first actual movement vectors and the first standard movement vectors above, which will not be elaborated here.
[0124] In some embodiments, the game result corresponding to the first user can be determined based on multiple second actual movement vectors and multiple second standard movement vectors. Take the game result as a health exercise score as an example. The health exercise score is a numerical value obtained by matching and calculating the strength and similarity between multiple second actual movement vectors and multiple second movement vectors. After obtaining the health exercise score, corresponding game operations can also be performed based on the health exercise score. In this embodiment, performing corresponding game operations based on the health exercise score includes: if the health exercise score is within a preset score range, generating a successful clearance message for the current level; if the health exercise score is not within the preset score range, generating a failed clearance message for the current level. Among them, the preset score range can be set to 90 points to 100 points or 85 points to 100 points, which can be set according to the actual situation.
[0125] In some embodiments, in order to increase the fun of the health-care exercise game, corresponding game control operations can also be performed based on the first posture feature data / the second posture feature data. Taking the execution of corresponding game control operations based on the second posture feature data as an example.
[0126] Specifically, different game control operations can be designed based on the second posture feature data corresponding to different time points. For example, in a game scenario of interstellar exploration, if the second posture feature data represents the motion trajectory of the first user kneading the Tianying acupoint, a missile can be launched at a target with the shape of a spaceship. If the second posture feature data represents the motion trajectory of the first user squeezing and pressing the Qingming acupoint, the spaceship's flight angle and posture can be adjusted.
[0127] In some embodiments, performing the corresponding game control operation based on the second gesture feature data may include: performing the corresponding game control operation based on the second actual movement vector.
[0128] For example, when the second actual movement vector indicates that the first user presses and rubs the Tianying acupoint clockwise, a missile can be launched at a target with a local shape of a spaceship. When the second actual movement vector indicates that the first user presses and rubs the Tianying acupoint counterclockwise, multiple missiles can be launched at a target with a local shape of a spaceship.
[0129] In some embodiments, the health-promoting exercise can be paired with one or more games. A game may have multiple levels, each with a corresponding time limit. When the current level ends, a health-promoting exercise score can be calculated based on the first user's gaming behavior in the current level, thereby determining whether the first user has successfully completed the level and increasing the fun of the health-promoting exercise. Specifically, in response to a command to end the current level of the game, multiple second actual movement vectors and multiple second standard movement vectors within the gaming time period of the current level are obtained. The second actual movement vectors are compared with the second standard movement vectors, and based on the comparison results, a determination is made as to whether the current level has been successfully completed.
[0130] In some embodiments, a corresponding game scene and display format of game results can be designed for health care exercises through a display device in the vehicle. The game scene includes multiple levels, and the first user is attracted to participate in the health care exercise through animations, sound effects and level challenges in the game.
[0131] For example, when the health and fitness score is within the preset score range, it means that the first user has passed the level, and fireworks special effects can be played, and the voice device in the vehicle can be combined to broadcast: "Perfect! Get 108 points and unlock the new planet map!"
[0132] If the health and exercise score is outside the preset range, the user has failed the level, and the incorrect area is highlighted (e.g., a red circle marks the unpressed Jingming acupoint). Furthermore, the first and second vibration units in the cabin can generate vibrations to alert the user that they are about to enter a specific teaching mode for an incorrect scenario.
[0133] Furthermore, the eye exercise game can be run for a set duration. After the game duration ends, the first user's health and exercise score is synchronized to the in-car account and a report is generated on the mobile device. For example, "Today's eye exercise compliance rate is 92%. It is recommended to increase eye exercise practice tomorrow." The mobile device can be a portable computer, smartphone, or smart bracelet.
[0134] like Figure 4 As shown, the present application further provides a gaming behavior detection device 30. The gaming behavior detection device 30 includes: an acquisition module 301 and a determination module 303.
[0135] Among them, the acquisition module 301 is used to respond to the game running instruction to obtain the first posture feature data and the first standard posture data within a preset time period, the first posture feature data represents the motion trajectory between the first body part and the second body part when the first user performs health care exercise, and the first standard posture data represents the motion trajectory between the third body part and the fourth body part under the standard posture, the first body part is the same as the third body part, and the second body part is the same as the fourth body part.
[0136] The determination module 302 is configured to determine, in response to a game end instruction, a game result corresponding to the first user based on the first posture feature data and the first standard posture data within a preset time period.
[0137] The above modules may be programmable software instructions stored in a memory and callable and executed by a processor. It is understood that in other embodiments, the above modules may also be program instructions or firmware fixed in the processor.
[0138] Please refer to Figure 5 , Figure 5 , which is a schematic diagram of the hardware structure of the electronic device 1000 provided in the embodiment of the present application. As Figure 5 shown, the electronic device 1000 may include a processor 1001 and a memory 1002. The memory 1002 is used to store one or more computer programs 1003. The one or more computer programs 1003 are configured to be executed by the processor 1001. The one or more computer programs 1003 include instructions, and the above instructions can be used to implement the above method in the electronic device 1000.
[0139] It can be understood that the structure illustrated in this embodiment does not constitute a specific limitation on the electronic device 1000. In other embodiments, the electronic device 1000 may include more or fewer components than shown, or combine certain components, or split certain components, or have different component arrangements.
[0140] The processor 1001 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 1001 is a cache memory. This memory can save the instructions or data that the processor 1001 has just used or recycled. If the processor 1001 needs to use the instruction or data again, it can directly call it from this memory. This avoids repeated accesses, reduces the waiting time of the processor 1001, and thus improves the efficiency of the system.
[0141] In some embodiments, the processor 1001 may include one or more interfaces. The interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a SIM interface, and / or a USB interface, etc.
[0142] In some embodiments, the processor 1001 is used to execute acceleration schemes such as single instruction multiple data (SIMD) and very long instruction word (VLIW).
[0143] In some embodiments, the memory 1002 may include high-speed random access memory, and may also include non-volatile memory, such as a hard disk, internal memory, plug-in hard disk, Smart Media Card (SMC), Secure Digital (SD) card, Flash Card, at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage devices.
[0144] This embodiment also provides a vehicle in which computer instructions are stored. When these instructions run on an electronic device, the electronic device is caused to execute the above-mentioned related method steps to implement the method in the above embodiment.
[0145] Among them, the electronic device and the vehicle provided in this embodiment are both used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be elaborated here.
[0146] In practical applications, the above functions can be allocated to different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.
[0147] In several embodiments provided in this application, the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are illustrative. For example, the division of the module or unit is a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection between each other can be through some interfaces. The indirect coupling or communication connection of the device or unit can be in an electrical, mechanical or other form.
[0148] The unit described as a separated component may or may not be physically separated. The component displayed as a unit may be a physical unit or multiple physical units, that is, it may be located in one place, or may be distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0149] In addition, each functional unit in various embodiments of this application can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
[0150] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiments of the present application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions for causing a device (which can be a single-chip microcomputer, a chip, etc.) or a processor to execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs.
[0151] As described above, the above are only the specific implementation manners of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions within the technical scope disclosed in the present application should be covered within the protection scope of the present application.
Claims
1. A game behavior detection method, characterized in that, The method includes: In response to a game running instruction, obtaining first pose feature data and first standard pose data within a preset time period, where the first pose feature data represents the movement trajectory between a first body part and a second body part when a first user performs a health care exercise, the first standard pose data represents the movement trajectory between a third body part and a fourth body part in a standard pose, the first body part is the same as the third body part, and the second body part is the same as the fourth body part; In response to a game end instruction, determining a game result corresponding to the first user based on the first pose feature data and the first standard pose data within the preset time period.
2. The game behavior detection method according to claim 1, wherein The determining the game result corresponding to the first user based on the first pose feature data and the first standard pose data within the preset time period includes: Based on the first pose feature data, determining a plurality of first actual movement vectors, where the first actual movement vectors are vectors formed according to a first key point of the first body part and a second key point of the second body part; Based on the first standard pose data, determining a plurality of first standard movement vectors, where the first standard movement vectors are vectors formed according to a third key point of the third body part and a fourth key point of the fourth body part, the position of the first key point on the first body part is the same as the position of the third key point on the third body part, and the position of the second key point on the second body part is the same as the position of the fourth key point on the fourth body part; Based on the plurality of first actual movement vectors and the plurality of first standard movement vectors, determining a game result corresponding to the first user, where the game result is obtained by performing a matching calculation based on the similarity between the plurality of first actual movement vectors and the plurality of first standard movement vectors.
3. The game behavior detection method according to claim 2, characterized in that The determining the game result corresponding to the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors includes: Based on the plurality of first actual movement vectors and the plurality of first standard movement vectors, determining a health care exercise intensity score for the first user, where the health care exercise intensity score is a value calculated based on the magnitudes of the plurality of first actual movement vectors and the plurality of first standard movement vectors; Based on the health care exercise intensity score and the action matching degree score between the plurality of first actual movement vectors and the plurality of first standard movement vectors, determining a health care exercise score for the first user.
4. The game behavior detection method according to claim 3, wherein, The determining the health care exercise intensity score for the first user based on the plurality of first actual movement vectors and the plurality of first standard movement vectors includes: Obtaining a plurality of actual component vectors of the plurality of first actual movement vectors perpendicular to the plane where the face of the first user is located; Obtaining a plurality of standard component vectors of the plurality of first standard movement vectors perpendicular to the plane where the face of the user is located in the standard pose; Based on the plurality of actual component vectors and the plurality of standard component vectors, determining the health care exercise intensity score for the first user.
5. The game behavior detection method according to claim 3, wherein The method further includes: Determine the similarity between multiple said first actual movement vectors and multiple said first standard movement vectors; Based on the similarity between multiple said first actual movement vectors and multiple said first standard movement vectors, determine the action matching degree score between multiple said first actual movement vectors and multiple said first standard movement vectors.
6. The game behavior detection method according to claim 2, characterized in that, The method further includes: Determine the difference vector between multiple said first actual movement vectors and multiple said first standard movement vectors; If the difference vector is not within the preset posture deviation range, output health care exercise guidance content to guide the first user to do health care exercises.
7. The game behavior detection method according to claim 6, wherein The determination method of the posture deviation range includes: Obtain the spatial area where the first user is located; Determine the area size of the spatial area to obtain the posture deviation range matching the area size.
8. The game behavior detection method according to claim 1, characterized in that Before obtaining the first posture feature data within a preset time period in response to the game running instruction, the method includes: Obtain the sitting duration of the first user; When the sitting duration is greater than a preset duration threshold, generate a game start confirmation message for reminding the first user whether to start a game matching the health care exercise; In response to the game confirmation operation of confirming to start the health care exercise, generate the game running instruction.
9. A game behavior detection device, characterized in that, The device includes: An acquisition module, configured to obtain first posture feature data and first standard posture data within a preset time period in response to a game running instruction, where the first posture feature data represents the movement trajectory between a first body part and a second body part when the first user does a health care exercise, and the first standard posture data represents the movement trajectory between a third body part and a fourth body part in a standard posture when a second user does the health care exercise, the first body part is the same as the third body part, and the second body part is the same as the fourth body part; A determination module, configured to determine the game result corresponding to the first user based on the first posture feature data and the first standard posture data within the preset time period in response to a game end instruction.
10. An electronic device, characterized in that, The electronic device includes a processor and a memory, the memory is used to store instructions, and the processor is used to call the instructions in the memory so that the electronic device executes the game behavior detection method according to any one of claims 1 to 8.
11. A computer storage medium, characterized in that, Including computer instructions, when the computer instructions run on an electronic device, the electronic device is caused to execute the game behavior detection method according to any one of claims 1 to 8.