Sleep monitoring method and related apparatus

By collaborating with the first and second electronic devices, and utilizing sensors and image recognition technology, it is possible to determine whether a user is using the first electronic device. This solves the problem of misjudgment in existing sleep monitoring devices and improves the accuracy of sleep state monitoring.

CN114762588BActive Publication Date: 2026-01-16HUAWEI TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110057952.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-15
Publication Date
2026-01-16
Estimated Expiration
2041-01-15

AI Technical Summary

Technical Problem

Existing sleep monitoring devices are prone to misjudging when users maintain a fixed posture for a long time but are not in a sleep state, resulting in inaccurate sleep quality monitoring.

Method used

By collaborating with the first and second electronic devices, multiple sensors and image recognition technologies are used to determine whether a user is using the first electronic device. Combined with physiological characteristic data and motion data, the accuracy of sleep state assessment is improved.

Benefits of technology

It reduces false alarms caused by users maintaining a fixed posture for extended periods without being asleep, and improves the accuracy of monitoring when users enter a sleep state and the accuracy of monitoring sleep quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114762588B_ABST
    Figure CN114762588B_ABST
Patent Text Reader

Abstract

The application discloses a sleep monitoring method and related devices, and relates to the field of artificial intelligence. In the method, a second electronic device worn on a first user and used for monitoring sleep quality can determine whether the first user enters a sleep state with the help of a first electronic device. Wherein, the second electronic device sends a request for determining whether the first user enters the sleep state to the first electronic device after predicting that the first user enters the sleep state. The first electronic device sends a message for indicating that the first user does not enter the sleep state to the second electronic device when determining that the first user uses the first electronic device. The method can reduce the misjudgment of monitoring whether the user enters the sleep state by the second electronic device alone, and improve the accuracy of monitoring the time when the user enters the sleep state.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of artificial intelligence, and in particular to a sleep monitoring method and related device. BACKGROUND

[0002] The quality of sleep is closely related to the health condition of a person. More and more electronic devices (such as a bracelet, a watch, etc.) have a sleep monitoring function to monitor the sleep quality of a person.

[0003] Sleep monitoring needs to determine whether a user enters a sleep state and whether the user wakes up. The current electronic device, for example, a bracelet, usually determines whether a user is in a sleep state by monitoring the motion state of itself and the heart rate variation of the user. However, in the scenario where a user keeps a fixed posture for a long time and is not in a sleep state, the above method is prone to misjudge the sleep state. For example, in the scenario where a user keeps a fixed posture to use a mobile phone before sleeping, the user does not enter a sleep state. However, the bracelet often determines that the user has entered a sleep state, thereby leading to inaccurate sleep quality monitoring. SUMMARY

[0004] The present application provides a sleep monitoring method and related device, which can determine whether a user enters a sleep state through cooperation of multiple electronic devices, thereby improving the accuracy of monitoring the time when a user enters a sleep state.

[0005] In a first aspect, the present application provides a sleep monitoring method. In the method, a first electronic device can receive a first request of a second electronic device. The first electronic device and the second electronic device have a binding relationship. The first request can be sent when the second electronic device is in a wearing state and monitors first data. The first data is consistent with the data of a user entering a sleep state. The first electronic device can determine whether a first user wearing the second electronic device is using the first electronic device, and send a first determination result or a second determination result to the second electronic device. The first determination result is that the first user is using the first electronic device, and the second determination result is that the first user is not using the first electronic device.

[0006] The above first electronic device can be a mobile phone, a tablet computer, a laptop computer, a handheld computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), smart glasses, and the like. The above second electronic device can be an electronic device for monitoring the sleep quality of a user. For example, a bracelet, a watch, and the like. The second electronic device can monitor the sleep quality of a user when it is in a wearing state.

[0007] The first data is data monitored by the second electronic device when the second electronic device is worn by the first user. The first data can include physiological characteristic data of the first user, motion data of the second electronic device. The physiological characteristic data can be, for example, heart rate data. The motion data of the second electronic device can be, for example, acceleration data, angular velocity data.

[0008] The first data is consistent with data of the user entering a sleep state, which can indicate that the second electronic device predicts that the first user enters a sleep state. The first data can be obtained through big data collection, and can reflect physiological characteristic data of a general user when wearing the second electronic device to enter a sleep state and motion data of the second electronic device. Alternatively, the second data can include physiological characteristic data of the first user when wearing the second electronic device to actually enter a sleep state and motion data of the second electronic device. By including the physiological characteristic data of the first user when wearing the second electronic device to actually enter a sleep state and the motion data of the second electronic device, the second electronic device can more accurately predict whether the first user enters a sleep state.

[0009] In combination with the first aspect, in some embodiments, the first electronic device can determine, under a first condition, that the first electronic device is used by a user and the user is the first user, and the first electronic device obtains a first determination result. The first condition can include one or more of the following: the first electronic device determines that it is in a non-stationary state, the first electronic device monitors user operation in a first time period, the first electronic device monitors that someone gazes at the screen of the first electronic device, and the first electronic device monitors that it runs an application for screen projection. The first electronic device can determine, under the first condition, that the first electronic device is used by a user and the user is not the first user, or the first electronic device determines that the first electronic device is not used by a user, and the first electronic device obtains a second determination result.

[0010] If the first electronic device is in a non-stationary state, the first electronic device can determine that a user is using the first electronic device. If the first electronic device monitors user operation in a first time period, the first electronic device can determine that a user is using the first electronic device. If the first electronic device detects that someone gazes at the screen of the first electronic device, the first electronic device can determine that a user is using the first electronic device. If the first electronic device runs an application for screen projection, the first electronic device can determine that a user is using the first electronic device.

[0011] In a possible implementation, when the first request is received, the first electronic device can first determine whether it is in a stationary state. If the first electronic device is in a non-stationary state and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If the first electronic device is in a stationary state, the first electronic device can further determine whether a user operation is monitored in the first time period. If a user operation is monitored in the first time period and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If no user operation is monitored in the first time period, the first electronic device can further monitor whether someone gazes at the screen of the first electronic device. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If it is monitored that no one gazes at the screen of the first electronic device, the first electronic device can obtain the second determination result. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is not the first user, the first electronic device can obtain the second determination result.

[0012] Optionally, if it is monitored that no one gazes at the screen of the first electronic device, the first electronic device can further monitor whether it runs an application for screen projection. If the application for screen projection is run and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If it is monitored that no one gazes at the screen of the first electronic device and the application for screen projection is not run, the first electronic device can obtain the second determination result.

[0013] In another possible implementation, when the first request is received, the first electronic device can first determine whether it is in a stationary state. If the first electronic device is in a non-stationary state and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If the first electronic device is in a stationary state, the first electronic device can further monitor whether someone gazes at the screen of the first electronic device. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If it is monitored that no one gazes at the screen of the first electronic device, the first electronic device can obtain the second determination result. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is not the first user, the first electronic device can obtain the second determination result.

[0014] In another possible implementation, when the first request is received, the first electronic device can first determine whether a user operation is monitored in the first time period. If a user operation is monitored in the first time period and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If no user operation is monitored in the first time period, the first electronic device can further monitor whether anyone gazes at the screen of the first electronic device. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If it is monitored that no one gazes at the screen of the first electronic device, the first electronic device can obtain the second determination result. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is not the first user, the first electronic device can obtain the second determination result.

[0015] In another possible implementation, when the first request is received, the first electronic device can monitor whether anyone gazes at the screen of the first electronic device. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is the first user, the first electronic device can obtain the first determination result. If it is monitored that no one gazes at the screen of the first electronic device, the first electronic device can obtain the second determination result. If it is monitored that someone gazes at the screen of the first electronic device and it is determined that the user is not the first user, the first electronic device can obtain the second determination result.

[0016] In some embodiments, the first electronic device can determine whether it is in a stationary state by using an acceleration sensor, a gyroscope sensor, or the like.

[0017] In some embodiments, the user operation can be a touch operation on the screen of the first electronic device, a user operation on a button of the first electronic device, an input operation of a voice instruction, an input operation of a gesture in the air, or the like.

[0018] In some embodiments, the first electronic device can determine whether anyone gazes at the screen of the first electronic device by using an eye gaze recognition model. The eye gaze recognition model can be a neural network model. Training data used to train the eye gaze recognition model can include image data of eye gaze at a screen and image data of eye gaze away from the screen. The trained eye gaze recognition model can identify features of an image of eye gaze at the screen, thereby determining whether anyone gazes at the screen of the first electronic device.

[0019] In some embodiments, the method for the first electronic device to determine that the user is the first user can include: the first electronic device can determine that the user of the first electronic device is the first user by capturing a first image through a camera and determining that the first image contains a face image of the first user. The camera that captures the first image can be a camera of the first electronic device or a camera of the projection device. The first electronic device can also determine whether the user of the first electronic device is the first user by capturing other biometric information (such as voiceprint information, fingerprint information, etc.).

[0020] In combination with the first aspect, in some embodiments, the first electronic device can establish a binding relationship with the second electronic device through Bluetooth pairing. Alternatively, the first electronic device can establish a binding relationship with the second electronic device in response to a first user operation. The first user operation can be used to indicate that the owner of the first electronic device is the first user. Alternatively, the first electronic device can establish a binding relationship with the second electronic device by logging into the same account.

[0021] Since the first electronic device and the second electronic device have the above binding relationship, the first electronic device can determine that the owner of the first electronic device and the user wearing the second electronic device are the same person. This can reduce the misjudgment of whether the user enters the sleep state when the user of the first electronic device and the user wearing the second electronic device are not the same person.

[0022] As can be seen from the above sleep monitoring method, when the second electronic device predicts that the first user enters the sleep state, the second electronic device can request the first electronic device to further confirm whether the first user enters the sleep state. The first electronic device can confirm whether the first user enters the sleep state by determining whether the first user is using the first electronic device. This can reduce the misjudgment of whether the user enters the sleep state when the user remains in a fixed posture for a long time but is not in the sleep state, and improve the accuracy of monitoring the time when the user enters the sleep state.

[0023] In combination with the first aspect, in some embodiments, the first electronic device monitors a user operation of unlocking the first electronic device within a second time period, and the first electronic device can send a first message to the second electronic device. The first message can be used to indicate that the first user is using the first electronic device. Alternatively, the first electronic device monitors a user operation of turning off an alarm within a second time period, and the user who turns off the alarm is the first user, and the first electronic device can send the above first message to the second electronic device.

[0024] The unlocking method can be a method of unlocking by using biometric information. The biometric information can be, for example, face information, voiceprint information, fingerprint information, and the like. When it is monitored that the biometric information belongs to the biometric information of the first user, the first electronic device can determine that the user of the unlocking is the first user.

[0025] The second time period can be a time period of a first duration from the first electronic device sending the second determination result to the second electronic device. Alternatively, the second time period can be a preset time period.

[0026] According to the above method, the second electronic device can determine whether the first user exits the sleep state with the help of the first electronic device. This can reduce the misjudgment of whether the first user exits the sleep state when the first user has woken up but has not gotten up, and improve the accuracy of sleep quality monitoring.

[0027] In a second aspect, the present application also provides a sleep monitoring method. In this method, the second electronic device monitors the first data when it is in a wearing state. The first data is consistent with the data of the user entering the sleep state. The second electronic device sends a first request to the first electronic device. The first electronic device and the second electronic device have a binding relationship. In the case of receiving the first determination result from the first electronic device, the second electronic device determines that the first user wearing the second electronic device has not entered the sleep state. The first determination result is the determination result of the first electronic device determining that the first user is using the first electronic device after receiving the first request.

[0028] The first data is the data monitored by the second electronic device when it is worn by the first user. The first data can include physiological characteristic data of the first user and motion data of the second electronic device. The physiological characteristic data can be, for example, heart rate data. The motion data of the second electronic device can be, for example, acceleration data and angular velocity data.

[0029] The first data consistent with the data of the user entering the sleep state can indicate that the second electronic device has preliminarily determined that the first user has entered the sleep state. The first data can be obtained by big data collection, and can reflect the physiological characteristic data of the general user wearing the second electronic device entering the sleep state and the motion data of the second electronic device. Alternatively, the second data can include the physiological characteristic data of the first user wearing the second electronic device actually entering the sleep state and the motion data of the second electronic device. By using the physiological characteristic data of the first user wearing the second electronic device actually entering the sleep state and the motion data of the second electronic device, the second electronic device can more accurately determine whether the first user has entered the sleep state.

[0030] In combination with the second aspect, in some embodiments, after determining that the first user does not enter the sleep state, the second electronic device can monitor the second data when in the wearing state, and determine whether the second data is consistent with the data of the user entering the sleep state. That is, the second electronic device can again predict whether the first user enters the sleep state. Wherein, after receiving the first determination result from the first electronic device, the second electronic device can perform a prediction every preset time period (such as 5 minutes, etc.), and request the first electronic device to determine whether the first user enters the sleep state when the prediction result is that the first user enters the sleep state.

[0031] The second data is the data of the first user, and the second data can include physiological characteristic data of the first user, motion data of the second electronic device.

[0032] In combination with the second aspect, in some embodiments, after determining that the first user does not enter the sleep state, the second electronic device can record the monitored physiological characteristic data of the user as data in the non-sleep state.

[0033] In combination with the second aspect, in some embodiments, the second electronic device determines that the first user enters the sleep state when receiving the second determination result from the first electronic device. The second determination result is the determination result of the first electronic device that the first user does not use the first electronic device after receiving the first request.

[0034] Further, after determining that the first user enters the sleep state, the second electronic device can record the monitored physiological characteristic data of the user as data in the sleep state.

[0035] As can be known from the above sleep monitoring method, when the second electronic device predicts that the first user enters the sleep state, the second electronic device can request the first electronic device to further confirm whether the first user enters the sleep state. The first electronic device can confirm whether the first user enters the sleep state by determining whether the first user is using the first electronic device. This can reduce the misjudgment of whether the user enters the sleep state due to the user maintaining a fixed posture for a long time but not being in the sleep state in the case of monitoring whether the user enters the sleep state by the second electronic device alone, and improve the accuracy of monitoring the time when the user enters the sleep state.

[0036] In combination with the second aspect, in some embodiments, the second electronic device can determine that the state of the first user detected by the second electronic device is the non-sleep state when receiving the first message from the first electronic device after detecting that the state of the first user is the sleep state. The first message can be used to indicate that the first user is using the first electronic device.

[0037] From the above method, the second electronic device can determine whether the first user exits the sleep state with the help of the first electronic device. This can reduce the misjudgment of whether the first user exits the sleep state when the first user has woken up but has not gotten out of bed, and improve the accuracy of sleep quality monitoring.

[0038] In a third aspect, the present application also provides a sleep monitoring method. In this method, the second electronic device monitors the first data when it is in a wearing state. The first data is consistent with the data of the user entering the sleep state. The second electronic device can send a first request to the first electronic device. The first electronic device has a binding relationship with the second electronic device. The first electronic device receives the first request of the second electronic device. The first electronic device can determine whether the first user wearing the second electronic device is using the first electronic device, and send the first determination result or the second determination result to the second electronic device. The first determination result is that the first user is using the first electronic device. The second determination result is that the first user is not using the first electronic device. In the case of receiving the first determination result, the second electronic device can determine that the first user has not entered the sleep state.

[0039] From the above sleep monitoring method, when the second electronic device preliminarily determines that the first user enters the sleep state, the second electronic device can request the first electronic device to further confirm whether the first user enters the sleep state. The first electronic device can confirm whether the first user enters the sleep state by determining whether the first user is using the first electronic device. This can reduce the misjudgment of whether the user enters the sleep state when the user maintains a fixed posture for a long time but is not in the sleep state, and improve the accuracy of monitoring the time when the user enters the sleep state.

[0040] In combination with the third aspect, in some embodiments, the first electronic device determines that the first electronic device is being used by the user and the user is the first user under the first condition, and the first electronic device obtains the first determination result. The first condition includes one or more of the following: the first electronic device determines that it is in a non-stationary state, the first electronic device monitors user operations within a first time period, the first electronic device monitors that someone's eyes are staring at the screen of the first electronic device, and the first electronic device monitors that it is running an application that has projection. The first electronic device determines that the first electronic device is being used by the user and the user is not the first user under the first condition, or the first electronic device determines that the first electronic device is not being used by the user, and the first electronic device obtains the second determination result.

[0041] In some embodiments, the method for determining that the user is the first user by the first electronic device can include: capturing, by the first electronic device, a first image through a camera, and determining that the first image contains a face image of the first user. The camera for capturing the first image can be a camera of the first electronic device or a camera of the screen projection device. The first electronic device can also determine whether the user of the first electronic device is the first user by capturing other biological feature information (such as voiceprint information, fingerprint information, etc.).

[0042] In some embodiments, the second electronic device can determine that the first user enters the sleep state upon receiving the second determination result.

[0043] In some embodiments, the first electronic device can establish a binding relationship with the second electronic device through Bluetooth pairing. Alternatively, the first electronic device can establish the binding relationship with the second electronic device in response to a first user operation. The first user operation can be used to indicate that the owner of the first electronic device is the first user. Alternatively, the first electronic device can establish the binding relationship with the second electronic device by logging into the same account.

[0044] Since the first electronic device and the second electronic device have the above binding relationship, the first electronic device can determine that the owner of the first electronic device and the user wearing the second electronic device are the same person. This can reduce the misjudgment of whether the user enters the sleep state when the user of the first electronic device and the user wearing the second electronic device are not the same person.

[0045] In some embodiments, the first electronic device can send a first message to the second electronic device when the first electronic device monitors a user operation of unlocking the first electronic device within a second time period. The first message can be used to indicate that the first user is using the first electronic device. Alternatively, the first electronic device can send the first message to the second electronic device when the first electronic device monitors a user operation of turning off an alarm within the second time period, and the user who turns off the alarm is the first user.

[0046] The unlocking method can be a method of unlocking by using biological feature information. The biological feature information can be, for example, face information, voiceprint information, fingerprint information, etc. When it is determined that the biological feature information monitored by the first electronic device belongs to the biological feature information of the first user, the first electronic device can determine that the user who unlocks the first electronic device is the first user.

[0047] The second time period can be a time period of a first duration from the first electronic device sending the second determination result to the second electronic device. Alternatively, the second time period can be a preset time period.

[0048] From the above method, the second electronic device can determine whether the first user exits the sleep state with the help of the first electronic device. This can reduce the misjudgment of the first user having woken up but not getting out of bed on the determination of whether the first user exits the sleep state, and improve the accuracy of sleep quality monitoring.

[0049] In a fourth aspect, the present application also provides a sleep monitoring method. In this method, the second electronic device receives a first message of the first electronic device when detecting that the state of the first user wearing the second electronic device is a sleep state, and can determine that the state of the first user detected by the second electronic device is a non-sleep state. The first electronic device has a binding relationship with the second electronic device. The first message can be sent by the first electronic device after monitoring a user operation of unlocking the first electronic device within a first monitoring time period.

[0050] The second electronic device determines that the detected state of the first user is a non-sleep state when receiving the first message can be to mark the detected state of the first user from a sleep state to a non-sleep state. That is to say, when receiving the first message, the second electronic device can determine that the first user has woken up. And the second electronic device can determine the time when the first message is received or the time when the first electronic device detects the user operation of unlocking as the time when the first user wakes up.

[0051] From the above method, the second electronic device can determine whether the first user exits the sleep state with the help of the first electronic device. This can reduce the misjudgment of the first user having woken up but not getting out of bed on the determination of whether the first user exits the sleep state, and improve the accuracy of sleep quality monitoring.

[0052] In combination with the fourth aspect, in some embodiments, the unlocking method can be a method of unlocking by using biometric information. The biometric information can be, for example, face information, voiceprint information, fingerprint information, and the like. When monitoring that the biometric information belongs to the biometric information of the first user, the first electronic device can determine that the user of unlocking is the first user.

[0053] In combination with the fourth aspect, in some embodiments, the second electronic device monitors the first data when in the wearing state. The first data is consistent with the data of the user entering the sleep state. The second electronic device can send a first request to the first electronic device. The second electronic device receives the determination result of the first electronic device indicating that the first user does not use the first electronic device, and can determine that the state of the first user detected by the second electronic device is to enter the sleep state.

[0054] In some embodiments of the fourth aspect, the first monitoring time period can be a time period in which the first electronic device estimates the first user to exit the sleep state. Optionally, the first monitoring time period can be a fixed time period, for example, from 5:00 am to 10:00 am.

[0055] In some embodiments of the fourth aspect, the first monitoring time period can be a time period of a first duration from when the first electronic device sends the second electronic device the result of the determination that the first user does not use the first electronic device.

[0056] The first monitoring time period can be the same as the second time period in the foregoing embodiments.

[0057] In some embodiments of the fourth aspect, the first electronic device can establish a binding relationship with the second electronic device through Bluetooth pairing. Alternatively, the first electronic device can establish a binding relationship with the second electronic device in response to a first user operation. The first user operation can be used to indicate that the owner of the first electronic device is the first user. Alternatively, the first electronic device can establish a binding relationship with the second electronic device by logging into the same account.

[0058] Since the first electronic device and the second electronic device have the binding relationship described above, the first electronic device can determine that the owner of the first electronic device and the user wearing the second electronic device are the same person. This can reduce the misjudgment that the user does not enter the sleep state when the user of the first electronic device and the user wearing the second electronic device are not the same person.

[0059] In some embodiments of the fourth aspect, after determining that the detected state of the first user is the non-sleep state, the second electronic device can also record the monitored physiological feature data of the user as data when the user is not in the sleep state.

[0060] In the fifth aspect, the present application also provides a sleep monitoring method. In the method, the first electronic device can monitor a user operation of unlocking the first electronic device in a first monitoring time period and send a first message to the second electronic device. The first message is used to indicate that the first user wearing the second electronic device uses the first electronic device. The first electronic device and the second electronic device have a binding relationship. The second electronic device can determine that the detected state of the first user is the non-sleep state when the first message is received while detecting that the state of the first user is the sleep state.

[0061] The second electronic device can determine that the detected state of the first user is the non-sleep state when receiving the first message, specifically, the second electronic device can mark the detected state of the first user from the sleep state to the non-sleep state. That is to say, when receiving the first message, the second electronic device can determine that the first user wakes up. In addition, the second electronic device can determine the time point when the first message is received or the time point when the first electronic device detects the unlocking user operation as the time point when the first user wakes up.

[0062] According to the above method, the second electronic device can determine whether the first user exits the sleep state by means of the first electronic device. This can reduce the misjudgment of whether the first user exits the sleep state when the first user has woken up but has not gotten up, and improve the accuracy of sleep quality monitoring.

[0063] In combination with the fifth aspect, in some embodiments, the second electronic device monitors the first data when in the wearing state, and the first data is consistent with the data of the user entering the sleep state. The second electronic device sends a first request to the first electronic device. The first electronic device receives the first request and determines whether the first user is using the first electronic device, and obtains a determination result indicating that the first user is not using the first electronic device. The first electronic device can send the determination result indicating that the first user is not using the first electronic device to the second electronic device. When receiving the determination result indicating that the first user is not using the first electronic device, the second electronic device can determine that the first user enters the sleep state.

[0064] In combination with the fifth aspect, in some embodiments, the first monitoring time period can be a time period in which the second electronic device estimates the first user to exit the sleep state.

[0065] In combination with the fifth aspect, in some embodiments, the first monitoring time period can be a time period of a first duration from when the first electronic device sends the determination result indicating that the first user is not using the first electronic device to the second electronic device.

[0066] In combination with the fifth aspect, in some embodiments, before the first electronic device sends the first message to the second electronic device, the first electronic device can also determine that the first electronic device is used by the user and the user is the first user under a first condition. The first condition includes one or more of the following: the first electronic device determines that it is in a non-stationary state, the first electronic device monitors user operations within a first time period, the first electronic device monitors that someone gazes at the screen of the first electronic device, and the first electronic device monitors that it runs an application program for projection.

[0067] In combination with the fifth aspect, in some embodiments, when it is determined that the first user exits the sleep state, the second electronic device can record the monitored physiological feature data of the user as data in a non-sleep state.

[0068] In some embodiments, the first electronic device can establish a binding relationship with the second electronic device through Bluetooth pairing. Alternatively, the first electronic device can establish the binding relationship with the second electronic device in response to a first user operation. The first user operation can be used to indicate that the owner of the first electronic device is the first user. Alternatively, the first electronic device can establish the binding relationship with the second electronic device by logging into the same account.

[0069] Since the first electronic device has the binding relationship with the second electronic device, the first electronic device can determine that the owner of the first electronic device and the user wearing the second electronic device are the same person. This can reduce the misjudgment of whether the user enters the sleep state when the user of the first electronic device and the user wearing the second electronic device are not the same person.

[0070] In a sixth aspect, the present application provides an electronic device. The electronic device is a first electronic device. The first electronic device can include a camera, a communication module, a memory, and a processor. The camera can be used to capture images. The communication module can be used to establish a communication connection with a second electronic device. The memory can be used to store a computer program. The processor can be used to call the computer program, so that the first electronic device executes any possible implementation method of the first aspect.

[0071] In a seventh aspect, the present application also provides an electronic device. The electronic device is a second electronic device. The second electronic device can include a communication module, a memory, and a processor. The communication module can be used to establish a communication connection with a first electronic device. The memory can be used to store a computer program. The processor can be used to call the computer program, so that the second electronic device executes any possible implementation method of the second aspect or executes any possible implementation method of the fourth aspect.

[0072] In an eighth aspect, the present application provides a sleep monitoring system, which can include the electronic device provided in the sixth aspect and the electronic device provided in the seventh aspect.

[0073] In a ninth aspect, the present application provides a chip applied to the electronic device provided in the sixth aspect or the electronic device provided in the seventh aspect. The chip includes one or more processors configured to call computer instructions to cause the electronic device provided in the sixth aspect to execute any possible implementation method of the first aspect, or to cause the electronic device provided in the seventh aspect to execute any possible implementation method of the second aspect or any possible implementation method of the fourth aspect.

[0074] In a tenth aspect, an embodiment of the present application provides a computer program product comprising instructions which, when executed on an electronic device, cause the electronic device of the sixth aspect to perform any possible implementation of the method of the first aspect, or cause the electronic device of the seventh aspect to perform any possible implementation of the method of the second aspect or any possible implementation of the method of the fourth aspect.

[0075] In an eleventh aspect, an embodiment of the present application provides a computer storage medium comprising computer instructions which, when executed on an electronic device, cause the electronic device of the sixth aspect to perform any possible implementation of the method of the first aspect, or cause the electronic device of the seventh aspect to perform any possible implementation of the method of the second aspect or any possible implementation of the method of the fourth aspect.

[0076] It can be understood that the electronic device of the sixth aspect, the electronic device of the seventh aspect, the sleep monitoring system of the eighth aspect, the chip of the ninth aspect, the computer program product of the tenth aspect and the computer readable storage medium of the eleventh aspect are all used to execute the method provided by the embodiments of the present application. Therefore, the beneficial effects that can be achieved are referable to the beneficial effects in the corresponding method, which will not be repeated here. BRIEF DESCRIPTION OF DRAWINGS

[0077] Figure 1 is a structural schematic diagram of a first electronic device 100 provided by an embodiment of the present application;

[0078] Figure 2 is a schematic diagram of a sleep monitoring scene provided by an embodiment of the present application;

[0079] Figure 3 is a flowchart of a sleep monitoring method provided by an embodiment of the present application;

[0080] Figure 4 is a flowchart of another sleep monitoring method provided by an embodiment of the present application;

[0081] Figure 5 is a flowchart of another sleep monitoring method provided by an embodiment of the present application;

[0082] Figure 6 is a flowchart of another sleep monitoring method provided by an embodiment of the present application. DETAILED DESCRIPTION

[0083] The technical solutions in the embodiments of the present application will be described clearly and exhaustively below with reference to the drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " represents the meaning of or, for example, A / B can represent A or B; the "and / or" in the text only describes the association relationship of the associated objects, which means that there can be three relationships, for example, A and / or B, which can represent: A alone, A and B together, and B alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.

[0084] Hereinafter, the terms "first" and "second" are only for descriptive purposes, and cannot be understood as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Therefore, the features defined with "first" and "second" can explicitly or implicitly include one or more of the features, and in the description of the embodiments of the present application, unless otherwise specified, the meaning of "multiple" is two or more than two.

[0085] The present application provides a sleep monitoring method, which can monitor whether a user enters a sleep state through cooperation of a first electronic device and a second electronic device. The sleep state can refer to the form exhibited by a person when sleeping. The sleep state can include a sleep-onset stage, a light sleep stage and a deep sleep stage. The user in the sleep state keeps a fixed posture for a long time or has a small amplitude of posture change. Moreover, the heart rate of the user in the sleep state fluctuates around the resting heart rate. The first electronic device can be a mobile phone, a tablet computer, a laptop computer, a handheld computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), smart glasses and the like. The second electronic device is an electronic device for monitoring the sleep quality of the user. The sleep quality monitoring can include determining the total duration of the user in the sleep state and the time length of the sleep-onset stage, the light sleep stage and the deep sleep stage in the sleep state and the like. The second electronic device can be, for example, an electronic device such as a bracelet, a watch and the like. That is, the user can monitor his own sleep quality by wearing the second electronic device. The present application does not limit the specific types of the first electronic device and the second electronic device.

[0086] In the sleep monitoring method, the second electronic device is worn on the first user. The sleep model is stored in the second electronic device. The second electronic device can use the sleep model to predict whether the first user enters the sleep state according to data collected by the acceleration sensor, the heart rate sensor and the like. When the second electronic device determines that the first user enters the sleep state, the second electronic device can send a request to the first electronic device to confirm whether the first user enters the sleep state. Further, the first electronic device can detect whether the first user uses the first electronic device. If it is determined that the first user uses the first electronic device, the first electronic device can notify the second electronic device that the first user uses the first electronic device. The second electronic device can determine that the first user does not enter the sleep state according to the notification. Otherwise, the first electronic device can notify the second electronic device that the first user does not use the first electronic device. The second electronic device can determine that the second user enters the sleep state according to the notification.

[0087] According to the above method, when the second electronic device determines that the first user enters the sleep state, the second electronic device can request the first electronic device to further confirm whether the first user enters the sleep state. This can reduce the misjudgment of whether the user enters the sleep state when the user maintains a fixed posture for a long time without being in the sleep state, and improve the accuracy of monitoring the time when the user enters the sleep state.

[0088] Figure 1 An exemplary structure diagram of a first electronic device 100 provided by an embodiment of the present application is shown.

[0089] As Figure 1As shown, the first electronic device 100 can include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headset jack 170D, a sensor module 180, a key 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 can include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0090] It can be understood that the structure shown in the embodiments of the present application does not constitute a specific limitation on the first electronic device 100. In other embodiments of the present application, the first electronic device 100 can include more or fewer components than shown, or combine certain components, or split certain components, or different arrangement of components. The components shown can be implemented in hardware, software, or a combination of software and hardware.

[0091] The processor 110 can include one or more processing units, for example: the processor 110 can include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units can be independent devices, or can be integrated in one or more processors.

[0092] The controller can be the nerve center and command center of the first electronic device 100. The controller can generate operation control signals according to instruction operation codes and timing signals, and complete the control of fetching instructions and executing instructions.

[0093] The processor 110 can also have a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory can hold instructions or data that the processor 110 has just used or is using repeatedly. If the processor 110 needs to use the instructions or data again, it can call them directly from the memory. This avoids repeated access and reduces the waiting time of the processor 110, thus improving the efficiency of the system.

[0094] The USB interface 130 is an interface that conforms to the USB standard specification, and can be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the first electronic device 100, and can also be used to transmit data between the first electronic device 100 and a peripheral device. It can also be used to connect earphones to play audio through the earphones. The interface can also be used to connect other electronic devices, such as AR devices, etc.

[0095] The charging management module 140 is used to receive charging input from a charger.

[0096] The power management module 141 is used to connect the battery 142 and the charging management module 140 to the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140 to power the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, and the wireless communication module 160, etc.

[0097] The wireless communication function of the first electronic device 100 can be realized through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor, and the baseband processor, etc.

[0098] The antenna 1 and the antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the first electronic device 100 can be used to cover a single or multiple communication frequency bands.

[0099] The mobile communication module 150 can provide a solution for wireless communication including 2G / 3G / 4G / 5G, etc. applied to the first electronic device 100. The mobile communication module 150 can include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive an electromagnetic wave by the antenna 1, and perform filtering, amplification, etc. on the received electromagnetic wave, and transfer the processed electromagnetic wave to the modem processor to be demodulated. The mobile communication module 150 can also amplify a signal modulated by the modem processor, and radiate the amplified signal as an electromagnetic wave through the antenna 1. In some embodiments, at least part of the function modules of the mobile communication module 150 can be disposed in the processor 110. In some embodiments, at least part of the function modules of the mobile communication module 150 can be disposed in the same device as at least part of the modules of the processor 110.

[0100] The wireless communication module 160 can provide a solution for wireless communication including wireless local area networks (WLAN) (e.g., wireless fidelity (Wi-Fi) network), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, etc. applied to the first electronic device 100. The wireless communication module 160 can be one or more devices integrated with at least one communication processing module. The wireless communication module 160 receives an electromagnetic wave via the antenna 2, performs frequency modulation and filtering on the electromagnetic wave signal, and transmits the processed signal to the processor 110. The wireless communication module 160 can also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and radiate the processed signal as an electromagnetic wave through the antenna 2.

[0101] In some embodiments, the antenna 1 of the first electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the first electronic device 100 can communicate with a network and other devices through wireless communication technology.

[0102] The first electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, etc. The GPU is a microprocessor for image processing, which is connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 can include one or more GPUs that execute program instructions to generate or change display information.

[0103] The display 194 is configured to display images, videos, and the like. In some embodiments, the first electronic device 100 can include one or N displays 194, where N is a positive integer greater than 1.

[0104] The first electronic device 100 can implement the photographing function through the ISP, the camera 193, the video codec, the GPU, the display 194, and the application processor, and the like.

[0105] The ISP is configured to process the data fed back by the camera 193. For example, when taking a photo, the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing to convert it into an image visible to the naked eye. The ISP can also optimize the algorithm for the noise, brightness, and skin color of the image. The ISP can also optimize the exposure, color temperature, and other parameters of the shooting scene. In some embodiments, the ISP can be arranged in the camera 193.

[0106] The camera 193 is configured to capture still images or videos. An object generates an optical image through a lens and projects it onto a photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into a standard RGB, YUV, or the like format image signal. In some embodiments, the first electronic device 100 can include one or N cameras 193, where N is a positive integer greater than 1.

[0107] The digital signal processor is configured to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the first electronic device 100 selects a frequency point, the digital signal processor is configured to perform Fourier transform on the frequency point energy, and the like.

[0108] The video codec is configured to compress or decompress digital videos. The first electronic device 100 can support one or more video codecs. In this way, the first electronic device 100 can play or record videos in multiple encoding formats, such as moving picture experts group (MPEG) 1, MPEG 2, MPEG 3, MPEG 4, and the like.

[0109] An NPU (Neural Processing Unit) is a neural network (NN) computing processor that, by borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, rapidly processes input information and can continuously learn on its own. Through an NPU, intelligent cognitive applications can be realized in a first electronic device 100, such as image recognition, facial recognition, speech recognition, and text understanding.

[0110] The external storage interface 120 can be used to connect an external storage card, such as a Micro SD card, to expand the storage capacity of the first electronic device 100.

[0111] The internal memory 121 can be used to store computer executable program code, which includes instructions. The processor 110 executes various functional applications and data processing of the first electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of the first electronic device 100 (such as audio data, phonebook, etc.).

[0112] The first electronic device 100 can implement audio functions, such as music playback and recording, through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, and an application processor.

[0113] Audio module 170 is used to convert digital audio information into analog audio signal output, and also to convert analog audio input into digital audio signal. Audio module 170 can also be used for encoding and decoding audio signals.

[0114] The loudspeaker 170A, also known as a "loudspeaker", is used to convert audio electrical signals into sound signals.

[0115] The receiver 170B, also known as the "earpiece", is used to convert audio electrical signals into sound signals.

[0116] The microphone 170C, also known as a "microphone" or "voice transducer," is used to convert sound signals into electrical signals.

[0117] The 170D headphone jack is used to connect wired headphones.

[0118] The pressure sensor 180A is configured to sense a pressure signal and convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be disposed on the display screen 194. The pressure sensor 180A can be of various types, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, etc. The capacitive pressure sensor can include at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes. The first electronic device 100 determines the intensity of the force according to the change in capacitance. When a touch operation is applied to the display screen 194, the first electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The first electronic device 100 can also calculate the position of the touch according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations applied to the same touch position but with different touch operation intensities can correspond to different operation instructions. For example, when a touch operation with a touch operation intensity less than a first pressure threshold is applied to a short message application icon, an instruction to view a short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold is applied to the short message application icon, an instruction to create a new short message is executed.

[0119] The gyroscope sensor 180B can be configured to determine the motion attitude of the first electronic device 100. In some embodiments, the angular velocity of the first electronic device 100 around three axes (i.e., x, y, and z axes) can be determined by the gyroscope sensor 180B. The gyroscope sensor 180B can be used for anti-shake photography. For example, when the shutter is pressed, the gyroscope sensor 180B detects the angle of shaking of the first electronic device 100, calculates the distance that needs to be compensated by the lens module according to the angle, and lets the lens offset the shaking of the first electronic device 100 by reverse movement to achieve anti-shake. The gyroscope sensor 180B can also be used for navigation and motion sensing game scenarios.

[0120] The barometric pressure sensor 180C is configured to measure air pressure.

[0121] The magnetic sensor 180D includes a Hall sensor.

[0122] The acceleration sensor 180E can detect the acceleration of the first electronic device 100 in various directions (generally three axes). When the first electronic device 100 is stationary, the acceleration sensor 180E can detect the magnitude and direction of gravity. The acceleration sensor 180E can also be used to identify the attitude of the first electronic device 100 and applied to landscape / portrait screen switching, pedometer applications, etc.

[0123] The distance sensor 180F is configured to measure distance.

[0124] The proximity light sensor 180G can include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The first electronic device 100 detects infrared reflected light from a nearby object using the photodiode. When sufficient reflected light is detected, it can be determined that there is an object near the first electronic device 100. When insufficient reflected light is detected, the first electronic device 100 can determine that there is no object near the first electronic device 100.

[0125] The ambient light sensor 180L is used to sense ambient light brightness. The first electronic device 100 can adaptively adjust the display screen 194 brightness according to the sensed ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust white balance when taking a picture. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the first electronic device 100 is in a pocket to prevent accidental touch.

[0126] The fingerprint sensor 180H is used to collect a fingerprint. The first electronic device 100 can use the collected fingerprint characteristics to implement fingerprint unlocking, access application lock, fingerprint photograph, fingerprint answer incoming call, etc.

[0127] The temperature sensor 180J is used to detect temperature.

[0128] The touch sensor 180K, also referred to as a "touch panel". The touch sensor 180K can be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 together form a touch screen, also referred to as a "touch screen". The touch sensor 180K is used to detect a touch operation acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the touch event type. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180K can also be disposed on the surface of the first electronic device 100, which is different from the position where the display screen 194 is located.

[0129] The bone conduction sensor 180M can obtain a vibration signal. In some embodiments, the bone conduction sensor 180M can obtain a vibration signal of a human body sound part vibration bone block. The bone conduction sensor 180M can also contact the human body pulse to receive a blood pressure pulsation signal. In some embodiments, the bone conduction sensor 180M can also be disposed in a headset to form a bone conduction headset. The audio module 170 can analyze a voice signal based on the vibration signal of the sound part vibration bone block obtained by the bone conduction sensor 180M to implement a voice function. The application processor can analyze heart rate information based on the blood pressure pulsation signal obtained by the bone conduction sensor 180M to implement a heart rate detection function.

[0130] The keys 190 include a power-on key, a volume key, and the like. The first electronic device 100 can receive a key input and generate a key signal input related to user settings and function control of the first electronic device 100.

[0131] The motor 191 can generate a vibration prompt.

[0132] The indicator 192 can be an indicator light and can be used to indicate a charging state, a power change, and can also be used to indicate a message, a missed call, a notification, and the like.

[0133] The SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into or pulled out of the SIM card interface 195 to achieve contact and separation with the first electronic device 100. The first electronic device 100 can support one or N SIM card interfaces, and N is a positive integer greater than 1. In some embodiments, the first electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the first electronic device 100 and cannot be separated from the first electronic device 100.

[0134] The structure of the second electronic device 200 can refer to the structure of the first electronic device 100 shown in the structure diagram of the first electronic device 100, and the embodiments of the present application do not repeat them. Figure 1

[0135] In subsequent embodiments of the present application, the first electronic device 100 is a mobile phone, and the second electronic device 200 is a bracelet, which are used to specifically introduce the sleep monitoring method provided by the present application.

[0136] Figure 2 An example of a sleep monitoring scenario related to the present application is shown.

[0137] As shown in Figure 2 The first user wears the bracelet 200. The first user lies on the bed and uses the mobile phone 100 in a fixed posture. The bracelet 200 can use a sleep model to predict that the first user has entered a sleep state according to data collected by an acceleration sensor, a heart rate sensor, and the like. The bracelet 200 can request the mobile phone 100 to further confirm whether the first user has entered a sleep state. The mobile phone 100 can confirm whether the first user has entered a sleep state by judging whether the first user is using the mobile phone 100. If it is determined that the first user is using the mobile phone 100, the mobile phone 100 can send a message to the bracelet 200 indicating that the first user is using the mobile phone 100. When receiving the message, the bracelet 200 can determine that the first user has not entered a sleep state. If it is determined that the first user is not using the mobile phone 100, the mobile phone 100 can send a message to the bracelet indicating that the first user is not using the mobile phone 100. When receiving the message, the bracelet 200 can determine that the first user has entered a sleep state.

[0138] ​The mobile phone 100 can monitor whether the mobile phone 100 is in a static state, whether a user operation acting on the mobile phone 100 is monitored within a preset time, and whether the first user's eye gazes at the screen of the mobile phone 100, to determine whether the first user uses the mobile phone 100.

[0139] For example, the mobile phone 100 can determine whether the mobile phone 100 is in a static state by using data collected by an acceleration sensor and a gyroscope sensor. If it is determined that the mobile phone 100 is in a non-static state (i.e., the posture of the mobile phone 100 changes), the mobile phone 100 can determine that a user uses the mobile phone 100. Further, the mobile phone 100 can determine whether the user using the mobile phone 100 is the first user.

[0140] If it is determined that the mobile phone 100 is in a static state, the mobile phone 100 can monitor whether a user operation acting on the mobile phone 100 is monitored within a preset time. This can reduce the misjudgment of whether the user enters a sleep state in a scenario in which the mobile phone 100 is in a static state but is still used by a user. If a user operation is monitored within the preset time, the mobile phone 100 can determine that a user uses the mobile phone 100. Further, the mobile phone 100 can determine whether the user using the mobile phone 100 is the first user. The length of the preset time is not limited in the embodiment of the present application.

[0141] If no user operation is monitored within the preset time, the mobile phone 100 can monitor whether an eye gazes at the screen of the mobile phone 100. This can reduce the misjudgment of whether the user enters a sleep state in a scenario in which the mobile phone is in a static state and no user operation is monitored within the preset time, but is still used by a user (for example, a scenario in which the mobile phone is in a static state and plays a video). If an eye gazes at the screen of the mobile phone 100, the mobile phone 100 can determine whether the user gazing at the screen is the first user. If no eye gazes at the screen of the mobile phone 100 or the user gazing at the screen of the mobile phone 100 is not the first user, the mobile phone 100 can determine that the first user does not use the mobile phone 100.

[0142] The implementation method of the bracelet 200 for predicting whether the first user enters a sleep state by using a sleep model and the implementation method of the mobile phone 100 for determining whether the user using the mobile phone 100 is the first user will be described in subsequent embodiments, which will not be described here.

[0143] In the embodiment of the present application, the mobile phone 100 and the bracelet 200 have a binding relationship.

[0144] In a possible implementation, the mobile phone 100 and the bracelet 200 can establish a binding relationship through Bluetooth pairing. The mobile phone 100 can mark the bracelet 200 as a bracelet worn by the owner of the mobile phone 100, for example, the mobile phone 100 can add an owner tag to the bracelet 200 when storing the Bluetooth address of the bracelet 200. When receiving a request from the bracelet 200 for determining whether the first user enters a sleep state, the mobile phone 100 can detect whether the first user is using the mobile phone 100. When receiving a request for determining whether a user enters a sleep state from a bracelet without an owner tag, the mobile phone 100 can not process the request.

[0145] In another possible implementation, the mobile phone 100 can establish a binding relationship with the bracelet 200 in response to a first user operation. The first user operation can be used to indicate that the owner of the mobile phone 100 and the user wearing the bracelet 200 are the same user. Specifically, the mobile phone 100 can manage the bracelet with which a communication connection is established. The mobile phone 100 can include a sleep assistance function in a setting option for managing the bracelet. In response to the first user operation, the mobile phone 100 can enable the sleep assistance function in the setting option for managing the bracelet 200. When the sleep assistance function is enabled, the bracelet 200 can request the mobile phone 100 to further confirm whether the owner of the mobile phone 100 enters a sleep state after the bracelet 200 predicts that the user wearing the bracelet 200 enters a sleep state.

[0146] In another possible implementation, the mobile phone 100 and the bracelet 200 can establish a binding relationship by associating with the same account (for example, a Huawei account). That is, the account logged in on the mobile phone 100 and the bracelet 200 is the same account. Because the mobile phone 100 and the bracelet 200 have a binding relationship, the mobile phone 100 can assist the bracelet 200 in monitoring whether the user (that is, the first user) wearing the bracelet 200 enters a sleep state by determining whether the owner (that is, the first user) is using the mobile phone. In this way, the use of the mobile phone 100 by a person other than the user wearing the bracelet 200 can be reduced, and the misjudgment of whether the user enters a sleep state can be reduced.

[0147] The embodiments of the present application do not limit the manner in which the mobile phone 100 and the bracelet 200 establish a binding relationship.

[0148] Because the present application involves the application of a neural network, the following introduces related terms of the neural network that may be involved in the embodiments of the present application.

[0149] 1. Neural network

[0150] The neural network can be composed of neural units, and a neural unit can refer to an operation unit with x s and an intercept 1 as input. The output of the operation unit can refer to the following formula (1):

[0151]

[0152] where s = 1, 2, …, n, n is a natural number greater than 1, W s is the weight of x s , b is the bias of the neural unit. f is the activation function of the neural unit, which is used to introduce non-linear characteristics into the neural network to convert the input signal in the neural unit into an output signal. The output signal of the activation function can be used as the input of the next convolutional layer. The activation function can be a sigmoid function. The neural network is a network formed by connecting many single neural units as described above, i.e. the output of one neural unit can be the input of another neural unit. The input of each neural unit can be connected to the local receptive field of the previous layer to extract the features of the local receptive field, and the local receptive field can be a region composed of several neural units.

[0153] 2. Loss function

[0154] In the process of training the neural network, because it is desired that the output of the neural network is as close as possible to the value that is truly intended to be predicted, the weight vector of each layer of the neural network can be updated according to the difference between the predicted value of the current network and the target value that is truly intended to be predicted (of course, there is usually an initialization process before the first update, i.e. the parameters of each layer of the neural network are pre-configured), for example, if the predicted value of the network is too high, the weight vector is adjusted to make it predict lower, and the adjustment is continuously made until the neural network can predict the target value that is truly intended to be predicted or a value very close to it. Therefore, it is necessary to define in advance “how to compare the difference between the predicted value and the target value”, which is the loss function or the objective function, which are important equations for measuring the difference between the predicted value and the target value. Among them, taking the loss function as an example, the higher the output value (loss) of the loss function, the greater the difference, and then the training of the neural network becomes a process of trying to minimize this loss.

[0155] 3. Backpropagation algorithm

[0156] The convolutional neural network can adopt a back propagation (BP) algorithm to correct the size of the parameters in the initial super-resolution model in the training process, so that the reconstruction error loss of the super-resolution model becomes smaller and smaller. Specifically, the forward transmission of the input signal until the output generates an error loss, and the error loss information is propagated backward to update the parameters in the initial super-resolution model, so as to make the error loss converge. The back propagation algorithm is a back propagation movement dominated by error loss, aiming to obtain the optimal parameters of the super-resolution model, such as the weight matrix.

[0157] The following specifically introduces a sleep monitoring method provided by an embodiment of the present application.

[0158] Figure 3 An exemplary flowchart of a sleep monitoring method provided by an embodiment of the present application is shown. As shown in the flowchart, the method can include steps S101-S108. Among them: Figure 3

[0159] S101, the bracelet 200 predicts that the first user enters a sleep state by using a sleep model.

[0160] The sleep model can be a trained neural network model.

[0161] In some embodiments, the bracelet 200 can collect acceleration data in real time through an acceleration sensor, and collect heart rate data of the first user in real time through a heart rate sensor. Based on the above acceleration data and heart rate data, the bracelet 200 can use the sleep model to predict whether the first user enters a sleep state. Among them, when the user is in a sleep state, the posture change of the bracelet 200 is usually small or even unchanged within a certain period of time. The posture of the bracelet 200 is different when it is worn on the user to keep still and placed on the desktop to keep still. And after the user enters a sleep state, the heart rate will usually gradually decrease. Therefore, combined with the acceleration data and heart rate data detected by the bracelet 200, the bracelet 200 can predict whether the user enters a sleep state.

[0162] ​The training data used to train the sleep model can include acceleration data and heart rate data of the bracelet 200 when the user is actually in a sleep state, and acceleration data and heart rate data of the bracelet 200 when the user is actually in a non-sleep state. The data can be collected through big data. That is, the data can be acceleration data and heart rate data of a general user when the user is in a sleep state and in a non-sleep state when wearing the bracelet 200. Alternatively, the data can be acceleration data and heart rate data of a first user when the user is in a sleep state and in a non-sleep state when wearing the bracelet 200. The sleep model trained by the data of the first user can better predict whether the first user enters a sleep state.

[0163] The trained sleep model can identify features of the acceleration data and heart rate data of the bracelet 200 when the first user is actually in a sleep state, and thus predict whether the first user enters a sleep state. That is, when the acceleration data monitored by the bracelet 200 is consistent with the acceleration data of the user when the user is actually in a sleep state, and the heart rate data monitored by the bracelet 200 is consistent with the heart rate data of the user when the user is actually in a sleep state, the bracelet 200 can predict that the first user enters a sleep state.

[0164] In some embodiments, the bracelet 200 can also use the sleep model to predict whether the first user enters a sleep state based on angular velocity data collected by a gyroscope sensor, ambient light data collected by an ambient light sensor, and ambient sound data collected by a microphone.

[0165] The training data used to train the sleep model and the method of training the sleep model are not limited in the embodiments. The method of predicting whether the first user enters a sleep state by the bracelet 200 can also refer to the method of determining whether the first user enters a sleep state by an electronic device such as a bracelet in the prior art.

[0166] S102, the bracelet 200 sends a request to the mobile phone 100 to confirm whether the first user enters a sleep state.

[0167] S103, the mobile phone 100 determines whether it is in a stationary state.

[0168] The mobile phone 100 in a non-stationary state can indicate that the user is using the mobile phone 100. The mobile phone 100 in a stationary state cannot directly indicate that the user is not using the mobile phone 100. For example, in the scenario where the user places the mobile phone 100 on a mobile phone holder to use the mobile phone 100, the mobile phone 100 is in a stationary state, but is still used by the user.

[0169] When receiving the request from the bracelet 200 for confirming whether the first user enters the sleep state, the mobile phone 100 can determine whether it is in the stationary state by the acceleration data collected by the acceleration sensor.

[0170] If it is determined that it is in the stationary state, the mobile phone 100 can perform the following step S104.

[0171] If it is determined that it is in the non-stationary state, the mobile phone 100 can perform the following step S106.

[0172] The method for the mobile phone 100 to determine whether it is in the stationary state is not limited in the embodiments of the present application. For example, the mobile phone 100 can also determine whether it is in the stationary state by the angular velocity data collected by the gyroscope sensor.

[0173] The mobile phone 100 can reduce the misjudgment of whether the first user enters the sleep state by monitoring whether the first user enters the sleep state by determining whether it is in the stationary state, in the scenario that the mobile phone 100 is in the stationary state but still used by the first user.

[0174] S104, the mobile phone 100 determines whether the user operation is monitored within the preset time.

[0175] The fact that the mobile phone 100 monitors the user operation within the preset time can indicate that the mobile phone 100 is used by the user. The fact that the mobile phone 100 does not monitor the user operation within the preset time cannot directly indicate that the mobile phone 100 is not used by the user. For example, the length of the above-mentioned preset time is 10 minutes, in the scenario that the user places the mobile phone 100 on the mobile phone support and watches the video for 30 minutes, the mobile phone 100 can not receive the user operation in the process of playing the video, but is still used.

[0176] The above-mentioned user operation can be, for example, the touch operation on the screen of the mobile phone 100, the user operation on the button of the mobile phone 100, the input operation of the voice instruction, the input operation of the air gesture, and the like. The specific type of the above-mentioned user operation is not limited in the embodiments of the present application.

[0177] If the user operation is not monitored within the preset time, the mobile phone 100 can perform the following step S105.

[0178] If the user operation is monitored within the preset time, the mobile phone 100 can perform the following step S106.

[0179] The length of the above-mentioned preset time is not limited in the embodiments of the present application.

[0180] In the case that the mobile phone 100 is in the stationary state, the mobile phone 100 monitors whether the first user enters the sleep state by judging whether the user operation is monitored within the preset time, which can reduce the scenario that the mobile phone 100 is in the stationary state, no user operation is monitored within the preset time, but the mobile phone 100 is still used by the first user (for example, the scenario that the mobile phone plays a video in the stationary state), and misjudges whether the first user enters the sleep state.

[0181] In S105, the mobile phone 100 judges whether the eyes of a person are gazing at the screen.

[0182] The mobile phone 100 can capture the image by using the front camera. Based on the image, the mobile phone 100 can use the eye gaze recognition model to judge whether the eyes of a person are gazing at the screen.

[0183] The eye gaze recognition model can be a neural network model.

[0184] The training data used to train the eye gaze recognition model can include image data of the eyes of a person gazing at the screen and image data of the eyes of a person not gazing at the screen. The trained eye gaze recognition model can identify the features of the image of the eyes of a person gazing at the screen, so as to judge whether the eyes of a person are gazing at the screen of the mobile phone 100. The method for training the eye gaze recognition model can refer to the training method of the neural network model in the prior art, which will not be described herein.

[0185] In some embodiments, the front camera used to capture the image can be a low-power camera. For example, an infrared camera. The low-power camera can be in the working state in real time. The type of the front camera is not limited in the embodiments of the present application.

[0186] In some embodiments, when it is determined that there is no user operation acting on the mobile phone 100 within the preset time period, the mobile phone 100 can start the front camera to capture the image. Alternatively, when the request for confirming whether the first user enters the sleep state is received from the bracelet 200, the mobile phone 100 can start the front camera. The time when the mobile phone 100 starts the front camera is not limited in the embodiments of the present application.

[0187] If it is identified that the eyes of a person are gazing at the screen, the mobile phone 100 can perform the following step S106.

[0188] If it is identified that the eyes of a person are not gazing at the screen, the mobile phone 100 can perform the following step S108.

[0189] The mobile phone 100 monitors whether the first user enters the sleep state by judging whether a person's eyes gaze at the screen, which can reduce the scenario that the mobile phone 100 is in the static state, no user operation in the preset time, but is not used by the first user (for example, the mobile phone is in the static state to play a video, but the first user falls asleep in the video playing process), and misjudges whether the first user enters the sleep state.

[0190] In S106, the mobile phone 100 judges whether the user of the mobile phone 100 is the first user.

[0191] In any of the following cases: the mobile phone 100 judges that the mobile phone 100 is in the non-static state, the mobile phone 100 judges that the mobile phone 100 is in the static state but monitors the user operation in the preset time, the mobile phone 100 judges that the mobile phone 100 is in the static state and does not monitor the user operation in the preset time but identifies that a person's eyes gaze at the screen of the mobile phone 100, the mobile phone 100 can determine that the user uses the mobile phone 100. Further, the mobile phone 100 can judge whether the user is the first user.

[0192] In a possible implementation, the mobile phone 100 can judge whether the user is the first user by face recognition.

[0193] The mobile phone 100 can compare the face image collected through the front camera with the face image of the owner of the mobile phone 100 stored in the mobile phone 100 to judge whether the user of the mobile phone 100 is the first user. The face image of the owner of the mobile phone 100 stored in the mobile phone 100 can be the face image used for face recognition to unlock the mobile phone 100. The embodiments of the present application do not limit the method of the mobile phone 100 to compare whether the face image collected through the front camera and the face image of the owner of the mobile phone 100 stored in the mobile phone 100 are the face images of the same user.

[0194] Optionally, the mobile phone 100 can also judge whether the user of the mobile phone 100 is the first user by the method of voiceprint recognition, fingerprint recognition and other biometric identification. The embodiments of the present application do not limit the specific method of judging whether the user of the mobile phone 100 is the first user.

[0195] If it is judged that the user of the mobile phone 100 is the first user, the mobile phone 100 can execute the following step S107.

[0196] If it is judged that the user of the mobile phone 100 is not the first user, the mobile phone 100 can execute the following step S108.

[0197] In the case that the mobile phone 100 is determined to be used by the user, the mobile phone 100 detects whether the first user enters the sleep state by identifying whether the user is the first user, so that the user of the mobile phone 100 and the first user wearing the bracelet 200 are not the same person, and the first user entering the sleep state is misjudged.

[0198] In S107, the mobile phone 100 sends the first judgment result to the bracelet 200, indicating that the first user uses the mobile phone 100.

[0199] If it is determined that the mobile phone 100 is used by the user, and the user is the first user, the mobile phone 100 can determine that the first user uses the mobile phone 100. Then, the mobile phone 100 can send the first judgment result to the bracelet 200, indicating that the first user uses the mobile phone 100.

[0200] In some embodiments, after receiving the first judgment result from the mobile phone 100, the bracelet 200 can again use the sleep model to predict whether the first user enters the sleep state, and request the mobile phone 100 to confirm whether the first user enters the sleep state. Wherein, when it is determined that the first user is in the sleep state, the bracelet 200 can use the sleep model to predict whether the first user enters the sleep state every preset time period (such as 5 minutes, etc.).

[0201] In some embodiments, after receiving the first judgment result from the mobile phone 100, the bracelet 200 can record the monitored data (such as heart rate data) as data of the first user in the non-sleep state.

[0202] In S108, the mobile phone 100 sends the second judgment result to the bracelet 200, indicating that the first user does not use the mobile phone 100.

[0203] If it is determined that no one's eyes gaze at the screen of the mobile phone 100, or it is determined that the mobile phone 100 is used by the user but the user is not the first user, the mobile phone 100 can determine that the first user does not use the mobile phone 100. Then, the mobile phone 100 can send the second judgment result to the bracelet 200, indicating that the first user does not use the mobile phone 100.

[0204] When receiving the second judgment result from the mobile phone 100, the bracelet 200 can determine the time when the second judgment result is received as the time when the first user enters the sleep state. Or, the bracelet 200 can determine the time when it predicts that the first user enters the sleep state as the time when the first user enters the sleep state. The embodiment of the present application does not specially limit the bracelet 200 to determine the time when the first user enters the sleep state. The bracelet 200 can record the monitored data (such as heart rate data) after the time when the first user enters the sleep state as data of the first user in the sleep state.

[0205] By Figure 3As shown in the sleep monitoring method, the wristband 200 can use the mobile phone 100 to confirm whether the first user has entered a sleep state. This reduces misjudgments of whether the first user has entered a sleep state when the wristband 200 is used alone to monitor whether the first user has entered a sleep state, because the first user may maintain a fixed posture for a long time without being asleep, thus improving the accuracy of monitoring the time when the first user enters a sleep state. Therefore, the wristband 200 can improve the accuracy of sleep quality monitoring.

[0206] Furthermore, after determining that it is in a non-stationary state, the mobile phone 100 can directly determine whether the user of the mobile phone 100 is the first user. In this way, the mobile phone 100 does not need to execute steps S104 and S105, thereby saving power consumption. Similarly, after determining that no user operation has been detected within a preset time, the mobile phone 100 can directly determine whether the user of the mobile phone 100 is the first user. This way, the mobile phone 100 does not need to execute step S105, thereby saving power consumption.

[0207] In some embodiments, the execution order of steps S103 and S104 can be interchanged. That is, after receiving a request from the wristband 200 to confirm whether the first user has entered a sleep state, the mobile phone 100 can first determine whether there is user operation within a preset time. If it is determined that there is user operation within the preset time, the mobile phone 100 can execute step S106. If it is determined that there is no user operation within the preset time, the mobile phone 100 can further determine whether it is in a stationary state. If it is determined that it is in a stationary state, the mobile phone 100 can execute step S105. If it is determined that it is not in a stationary state, the mobile phone 100 can execute step S106.

[0208] In other embodiments, after receiving a request from the wristband 200 to confirm whether the first user has entered a sleep state, the mobile phone 100 can simultaneously execute steps S103, S104, and S105 to determine whether the mobile phone 100 is being used by a user. If it is determined that the mobile phone 100 is being used by a user, the mobile phone 100 can further execute step S106 to determine whether the user is the first user. Otherwise, the mobile phone 100 can execute step S108 to instruct the wristband 200 to instruct the first user to enter a sleep state.

[0209] Figure 4 A flowchart of another sleep monitoring method provided in an embodiment of this application is shown as an example.

[0210] like Figure 4 As shown, the method may include steps S201 to S207. Wherein:

[0211] S201 and Bracelet 200 use a sleep model to predict when the first user enters a sleep state.

[0212] S202, the bracelet 200 sends a request to the mobile phone 100 to confirm whether the first user enters a sleep state.

[0213] The steps S201 and S202 can refer to steps S101 and S102 in the method shown in Figure 3

[0214] S203, the mobile phone 100 judges whether it is in a static state.

[0215] The method that the mobile phone 100 judges whether it is in a static state can refer to step S203 in the method shown in Figure 3

[0216] When it is judged that it is in a static state, the mobile phone 100 can execute step S204. That is, the mobile phone 100 can judge whether someone gazes at the screen.

[0217] When it is judged that it is in a non-static state, the mobile phone 100 can execute step S205.

[0218] S204, the mobile phone 100 judges whether someone gazes at the screen.

[0219] S205, the mobile phone 100 judges whether the user of the mobile phone 100 is the first user.

[0220] S206, the mobile phone 100 sends a first judgment result to the bracelet 200 to indicate that the first user uses the mobile phone 100.

[0221] S207, the mobile phone 100 sends a second judgment result to the bracelet 200 to indicate that the first user does not use the mobile phone 100.

[0222] The steps S204-S207 can refer to steps S105-S108 in the method shown in Figure 3 , which will not be repeated here.

[0223] Figure 5 An exemplary flow chart of another sleep monitoring method provided by the embodiments of the application is shown.

[0224] As shown in Figure 5 , the method can include steps S301-S307. Wherein:

[0225] S301, the bracelet 200 uses a sleep model to predict that the first user enters a sleep state.

[0226] S302, the bracelet 200 sends a request to the mobile phone 100 to confirm whether the first user enters a sleep state.

[0227] ​​The steps S301 and S302 can refer to the steps S101 and S102 in the method shown in Figure 3 The steps S101 and S102 in the method shown in

[0228] S303, the mobile phone 100 judges whether the user operation is monitored within the preset time.

[0229] The method that the mobile phone 100 judges whether the user operation is monitored within the preset time can refer to the step S204 in the method shown in Figure 3

[0230] When it is judged that the user operation is not monitored within the preset time, the mobile phone 100 can execute the step S304. That is, the mobile phone 100 can judge whether the eyes of a person are fixed on the screen.

[0231] When it is judged that the user operation is monitored within the preset time, the mobile phone 100 can execute the step S305.

[0232] S304, the mobile phone 100 judges whether the eyes of a person are fixed on the screen.

[0233] S305, the mobile phone 100 judges whether the user of the mobile phone 100 is the first user.

[0234] S306, the mobile phone 100 sends the first judgment result to the bracelet 200, indicating that the first user uses the mobile phone 100.

[0235] S307, the mobile phone 100 sends the second judgment result to the bracelet 200, indicating that the first user does not use the mobile phone 100.

[0236] The steps S304 to S307 can refer to the steps S105 to S108 in the method shown in Figure 3 The steps S105 to S108 in the method shown in, which will not be described here.

[0237] Figure 6 An exemplary flow chart of another sleep monitoring method provided by the embodiments of the present application is shown.

[0238] As shown in Figure 6 The method can include steps S401 to S406. Wherein:

[0239] S401, the bracelet 200 predicts that the first user enters a sleep state by using a sleep model.

[0240] S402, the bracelet 200 sends a request to the mobile phone 100 to confirm whether the first user enters a sleep state.

[0241] The steps S401 and S402 can refer to the steps S101 and S102 in the method shown in Figure 3 The steps S101 and S102 in the method shown in​

[0242] S403, the mobile phone 100 judges whether a person's eyes are gazing at the screen.

[0243] S404, the mobile phone 100 judges whether the user of the mobile phone 100 is the first user.

[0244] S405, the mobile phone 100 sends the first judgment result to the bracelet 200, indicating that the first user is using the mobile phone 100.

[0245] S406, the mobile phone 100 sends the second judgment result to the bracelet 200, indicating that the first user is not using the mobile phone 100.

[0246] The steps S403-S406 can refer to the steps S105-S108 in the method shown in Figure 3 The steps S105-S108 in the method shown in

[0247] In some embodiments, when receiving the request from the bracelet 200 for determining whether the first user enters the sleep state, the mobile phone 100 can monitor whether it is running an application for screen projection. The mobile phone 100 running the application for screen projection can indicate that the user is using the mobile phone 100. When monitoring that it is running the application for screen projection, the mobile phone 100 can detect whether the user of the mobile phone 100 is the first user. In a possible implementation, the mobile phone 100 can send a message for collecting images to a screen projection device, such as a television. When receiving the message for collecting images, the screen projection device can collect images of the area where the screen projection device is watched, and send the images to the mobile phone 100. The mobile phone 100 can judge whether the images from the screen projection device contain the face image of the first user.

[0248] The face image of the first user contained in the images collected by the screen projection device can indicate that the first user is watching the content played on the screen projection device through the mobile phone 100 for screen projection. That is, the first user does not enter the sleep state. When judging that the face image of the first user is contained in the images collected by the screen projection device, the mobile phone 100 can send the first judgment result in the foregoing embodiments to the bracelet 200, indicating that the first user is using the mobile phone 100.

[0249] The face image of the first user not contained in the images collected by the screen projection device can indicate that the first user is not included in the users who use the mobile phone 100 for screen projection and watch the content played on the screen projection device. When judging that the face image of the first user is not contained in the images collected by the screen projection device, the mobile phone 100 can send the second judgment result in the foregoing embodiments to the bracelet 200, indicating that the first user is not using the mobile phone 100.

[0250] In the application scenario of the phone 100 projecting a screen, the phone 100 can monitor that it is in a stationary state, has no user operation in a preset time, and has no eye gaze. However, the first user does not enter a sleep state, but watches the projection device. The above method can monitor whether the phone 100 runs a projection application, and monitor whether the first user enters a sleep state by means of the image collected by the projection device in the case where the phone 100 runs a projection application. This can reduce the false judgment of whether the first user enters a sleep state when the phone 100 is in a stationary state, has no user operation in a preset time, and has no eye gaze, but is still used by the first user.

[0251] In some embodiments, when receiving a request from the bracelet 200 for determining whether the first user enters a sleep state, the phone 100 can request other electronic devices with image collection devices (such as cameras), for example, a television, to collect images. When obtaining the images collected by the electronic devices with image collection devices, the phone 100 can determine whether the images contain the first user and determine the state of the first user. In this way, the phone 100 can monitor whether the first user enters a sleep state and send the monitoring result to the bracelet 200.

[0252] For example, the phone 100 can send a message of collecting images to the television. The television can send the images collected by the camera to the phone 100. The images collected by the camera of the television containing the face image of the first user can indicate that the first user is watching the television. That is, the first user enters a sleep state. If the phone 100 determines that the images from the television contain the face image of the first user, the phone 100 can send the first determination result in the foregoing embodiments to the bracelet 200, indicating that the first user is using the phone 100.

[0253] The application embodiments do not limit the way of establishing a communication connection between the phone 100 and the electronic devices with image collection devices such as televisions. The above communication connection methods can be, for example, Bluetooth connection, Wi-Fi network connection, and the like.

[0254] In some embodiments, the bracelet 200 can establish a communication connection with other electronic devices with image collection devices. When it is predicted that the first user enters a sleep state, the bracelet 200 can send a message of collecting images to the electronic devices with image collection devices. The electronic devices with image collection devices can send the collected images to the bracelet 200. The bracelet 200 can determine the state of the first user according to the images to determine whether the first user enters a sleep state. Alternatively, the bracelet 200 can send the images to the electronic device with stronger processing capability, for example, the phone 100, which establishes a communication connection with the bracelet 200. The phone 100 can determine the state of the first user according to the received images to determine whether the first user enters a sleep state.

[0255] The embodiments of the present application do not limit the way that the bracelet 200 and the electronic device with the image acquisition device establish a communication connection.

[0256] In some embodiments, the bracelet 200 can determine whether the first user exits the sleep state (i.e., the first user wakes up) with the help of the mobile phone 100.

[0257] Specifically, the mobile phone 100 can send a message indicating that the first user exits the sleep state to the bracelet 200 when the mobile phone 100 first detects a user operation of unlocking the mobile phone 100 within a second time period. When receiving the message indicating that the first user exits the sleep state, the bracelet 200 can determine the time when the user operation of unlocking the mobile phone 100 is detected as the time when the first user exits the sleep state. In combination with the time when the first user enters the sleep state determined by the sleep monitoring method in the foregoing embodiments, the bracelet 200 can determine the total duration of the sleep state of the first user and evaluate the sleep quality of the first user within the time period from entering the sleep state to exiting the sleep state.

[0258] In particular, the unlocking method can be a method of unlocking by using biometric information. The biometric information can be, for example, face information, voiceprint information, fingerprint information, and the like. When it is detected that the biometric information belongs to the biometric information of the first user, the mobile phone 100 can determine that the user who unlocks is the first user.

[0259] The second time period can be a period of time (such as 12 hours) during which the mobile phone 100 sends the second determination result indicating that the first user does not use the mobile phone 100 to the bracelet 200. Alternatively, the second time period can be a preset time period, for example, a time period from 5 am to 10 am. The second time period can also be a time period in which the bracelet 200 estimates that the first user exits the sleep state. The bracelet 200 can estimate the time period in which the first user exits the sleep state according to the data of the first user detected multiple times.

[0260] Optionally, the mobile phone 100 can determine whether the user who turns off the alarm of the mobile phone 100 is the first user when the mobile phone 100 monitors the user operation of turning off the alarm of the mobile phone 100 in the second time period. If the user who turns off the alarm of the mobile phone 100 is determined to be the first user, the mobile phone 100 can send a message to the bracelet 200 to indicate that the first user exits the sleep state. When receiving the message indicating that the first user exits the sleep state, the bracelet 200 can determine the time when the user operation of turning off the alarm of the mobile phone 100 is monitored as the time when the first user exits the sleep state. The embodiments of the present application do not limit the method of the mobile phone 100 to determine whether the user who turns off the alarm of the mobile phone 100 is the first user. For example, the mobile phone 100 can determine whether the user who turns off the alarm is the first user by using the method of biometric information recognition such as face recognition, voiceprint recognition, and fingerprint recognition.

[0261] Optionally, the mobile phone 100 can also determine whether the first user uses the mobile phone 100 in the second time period by using the method shown in the foregoing Figures 3-6 If it is determined that the first user uses the mobile phone 100, the mobile phone 100 can send a message to the bracelet 200 to indicate that the first user exits the sleep state. The embodiments of the present application do not limit the implementation method of the mobile phone 100 to determine whether the first user exits the sleep state.

[0262] The method of determining whether the first user uses the mobile phone 100 by monitoring the user operation of unlocking, monitoring the user operation of turning off the alarm, and the method shown in the foregoing Figures 3-6 The mobile phone 100 can also determine whether the mobile phone 100 is used by the first user by using other methods, and then assist the bracelet 200 to determine whether the first user exits the sleep state.

[0263] The bracelet 200 can determine whether the first user exits the sleep state by using the sleep model in the foregoing embodiments based on the acceleration data and the heart rate data. However, in some application scenarios (for example, the application scenario in which the first user lies on the bed to use the mobile phone after waking up), the first user has exited the sleep state, but the change amount of the posture of the bracelet 200 is small or even the posture remains unchanged. Therefore, the result determined by the bracelet 200 by using the sleep model is often that the first user is still in the sleep state. This reduces the accuracy of sleep quality monitoring. The method of determining whether the first user exits the sleep state by the bracelet 200 with the help of the mobile phone 100 can reduce the misjudgment of whether the first user exits the sleep state when the first user has woken up but has not got up, and improve the accuracy of sleep quality monitoring.

[0264] The above-described embodiments are only used to illustrate the technical solutions of the present application, but not limit the present application; although the present application is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: it can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for part of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A sleep monitoring method, characterized by, The method comprises: The first electronic device receives a first request of the second electronic device; the first request is sent when the second electronic device is in a wearing state and first data is monitored, and the first data is consistent with data of a user entering a sleep state; If the first electronic device has a binding relationship with the second electronic device, the first electronic device determines that a first user wearing the second electronic device is the owner of the first electronic device; The first electronic device judges whether the first user is using the first electronic device, and sends a first judgment result or a second judgment result to the second electronic device; the first judgment result is that the first user is using the first electronic device, and the second judgment result is that the first user is not using the first electronic device.

2. The method of claim 1, wherein, The first electronic device judges whether the first user is using the first electronic device, specifically comprising: The first electronic device judges that the first electronic device is being used by a user and the user is the first user under a first condition, and the first electronic device obtains the first judgment result; the first condition includes one or more of the following: the first electronic device judges that it is in a non-stationary state, the first electronic device monitors user operations in a first time period, the first electronic device monitors that someone's eyes are staring at the screen of the first electronic device, and the first electronic device monitors that it is running an application for screen projection; The first electronic device judges that the first electronic device is being used by a user and the user is not the first user under the first condition, or the first electronic device judges that the first electronic device is not being used by a user, and the first electronic device obtains the second judgment result.

3. The method of claim 2, wherein, The first electronic device judges that the user is the first user, specifically comprising: The first electronic device acquires a first image through a camera and judges that the first image contains a face image of the first user.

4. The method according to any one of claims 1-3, characterized in that, The first data includes one or more of the following: physiological characteristic data of a user, and motion data of the second electronic device.

5. The method according to any one of claims 1 to 3, characterized in that, The method further comprises: The first electronic device monitors, in a second time period, a user operation of unlocking the first electronic device, and sends a first message to the second electronic device, the first message being used to indicate that the first user is using the first electronic device; or The first electronic device monitors, in the second time period, a user operation of closing an alarm, and the user closing the alarm is the first user, and the first electronic device sends the first message to the second electronic device.

6. The method of claim 4, wherein, The method further comprises: The first electronic device monitors, in a second time period, a user operation of unlocking the first electronic device, and sends a first message to the second electronic device, the first message being used to indicate that the first user is using the first electronic device; or The first electronic device monitors a user operation of closing the alarm clock in the second time period, and the user closing the alarm clock is the first user, and the first electronic device sends the first message to the second electronic device.

7. The method of claim 5, wherein, The second time period is a first time period from the first electronic device sending the second determination result to the second electronic device, or the second time period is a preset time period.

8. The method of claim 6, wherein, The second time period is a first time period from the first electronic device sending the second determination result to the second electronic device, or the second time period is a preset time period.

9. The method according to any one of claims 1-3, 6-8, characterized in that, The method further comprises: The first electronic device and the second electronic device establish a binding relationship through Bluetooth pairing; or The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or The first electronic device and the second electronic device establish a binding relationship by logging in the same account.

10. The method of claim 4, wherein, The method further comprises: The first electronic device and the second electronic device establish a binding relationship through Bluetooth pairing; or The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or The first electronic device and the second electronic device establish a binding relationship by logging in the same account.

11. The method of claim 5, wherein, The method further comprises: The first electronic device and the second electronic device establish a binding relationship through Bluetooth pairing; or The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or The first electronic device and the second electronic device establish a binding relationship by logging in the same account.

12. A sleep monitoring method characterized by, The method comprises: The second electronic device monitors the first data when it is in a wearing state, and the first data is consistent with the data of the user entering the sleep state; The second electronic device sends a first request to the first electronic device; The first electronic device receives the first request of the second electronic device; If the first electronic device and the second electronic device have a binding relationship, the first electronic device determines that the first user wearing the second electronic device is the owner of the first electronic device; The first electronic device determines whether the first user is using the first electronic device, and sends a first determination result or a second determination result to the second electronic device; the first determination result is that the first user is using the first electronic device, and the second determination result is that the first user is not using the first electronic device; In the case of receiving the first determination result, the second electronic device determines that the first user has not entered the sleep state.

13. The method of claim 12, wherein, The first electronic device determines whether the first user is using the first electronic device, specifically comprising: The first electronic device determines whether the first user is using the first electronic device, specifically comprising: The first electronic device judges that the first electronic device is used by a user and the user is the first user under a first condition, and the first electronic device obtains the first judgment result; the first condition includes one or more of the following: the first electronic device judges that it is in a non-stationary state, the first electronic device monitors user operation in a first time period, the first electronic device monitors that someone gazes at the screen of the first electronic device, and the first electronic device monitors that it runs an application for screen projection. The first electronic device judges that the first electronic device is used by a user and the user is not the first user under the first condition, or the first electronic device judges that the first electronic device is not used by a user, and the first electronic device obtains the second judgment result.

14. The method of claim 13, wherein, The first electronic device judges that the user is the first user, specifically including: The first electronic device collects a first image through a camera and judges that the first image contains a face image of the first user.

15. The method according to any one of claims 12-14, characterized in that, The method further includes: In the case where the second judgment result is received, the second electronic device determines that the first user enters a sleep state.

16. The method according to any one of claims 12-14, characterized in that, The method further includes: The first electronic device monitors user operation of unlocking the first electronic device in a second time period, the first electronic device sends a first message to the second electronic device, and the first message is used to indicate that the first user is using the first electronic device; or The first electronic device monitors user operation of closing an alarm in the second time period, and the user closing the alarm is the first user, and the first electronic device sends the first message to the second electronic device.

17. The method of claim 15, wherein, The method further includes: The first electronic device monitors user operation of unlocking the first electronic device in a second time period, the first electronic device sends a first message to the second electronic device, and the first message is used to indicate that the first user is using the first electronic device; or The first electronic device monitors user operation of closing an alarm in the second time period, and the user closing the alarm is the first user, and the first electronic device sends the first message to the second electronic device.

18. The method of any one of claims 12-14, 17, wherein, The method further includes: The first electronic device and the second electronic device establish a binding relationship through Bluetooth pairing; or The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or The first electronic device and the second electronic device establish a binding relationship by logging in to the same account.

19. The method of claim 15, wherein, The method further includes: The first electronic device and the second electronic device establish a binding relationship through Bluetooth pairing; or The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or The first electronic device and the second electronic device establish a binding relationship by logging in to the same account. The first electronic device and the second electronic device establish a binding relationship by logging in the same account.

20. The method of claim 16, wherein, The method further includes: The first electronic device and the second electronic device establish a binding relationship by Bluetooth pairing; or, The first electronic device establishes a binding relationship with the second electronic device in response to a first user operation, and the first user operation is used to indicate that the owner of the first electronic device is the first user; or, The first electronic device and the second electronic device establish a binding relationship by logging in the same account.

21. An electronic device, the electronic device being a first electronic device, comprising: It includes: a camera, a communication module, a memory, and a processor; The camera is used to collect images; the communication module is used to establish a communication connection with the second electronic device; The memory is used to store a computer program; and the processor is used to call the computer program, so that the first electronic device executes the method of any one of claims 1-11.

22. A sleep monitoring system, characterized by The system includes a second electronic device and the first electronic device of claim 21, wherein The second electronic device is configured to send a first request to the first electronic device after monitoring the first data in the wearing state, and the first data is consistent with the data of the user entering the sleep state. The first electronic device is configured to receive the first request. The first electronic device is further configured to determine that the first user wearing the second electronic device is the owner of the first electronic device when the first electronic device and the second electronic device have a binding relationship. The first electronic device is further configured to determine whether the first user is using the first electronic device and send the first determination result or the second determination result to the second electronic device; the first determination result is that the first user is using the first electronic device, and the second determination result is that the first user is not using the first electronic device. The second electronic device is further configured to determine that the first user has not entered the sleep state when the first determination result is received.

23. A computer storage medium, comprising, It includes: computer instructions; when the computer instructions run on an electronic device, the electronic device executes the method of any one of claims 1-11.

24. A computer program product, characterised in that, When the computer program product runs on an electronic device, the electronic device executes the method of any one of claims 1-11.

Citation Information

Patent Citations

  • Mobile phone state switching method and system based on face detection and eyeball tracking

    CN104092822A

  • Sleep state detection method, device and system

    CN105433904A