Dynamic threshold setting method and system for CSI (Channel State Information) human memory identification technology
By dynamically setting the judgment threshold threshold in CSI human-in-one identification technology, combining the basic threshold and fixed threshold, the problem that fixed threshold is difficult to compatible with different environments is solved, detection sensitivity and stability are improved, and the industrial application of CSI algorithm is supported.
Patent Information
- Application Number
- CN202411334181.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-01-17
AI Technical Summary
In the existing CSI human inventory identification technology, the fixed judgment threshold is difficult to compatible with different routers and user environments, resulting in misjudgment problems and difficult to ensure detection sensitivity and stability.
By setting the basic threshold vAv and fixed threshold v0 in the unmanned state, the final judgment threshold vt is calculated, which is used to determine whether the environment is moved and dynamically adjust the threshold to adapt to different routers and environments.
It improves the sensitivity of human mobile detection and stability of unmanned state in different routers and user environments, and supports the industrial application of CSI algorithms.
Smart Images

Figure CN119324754A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of smart home technology, and in particular to a method and system for setting a dynamic threshold value of a CSI human presence recognition technology. Background Art
[0002] In recent years, as major WiFi chip manufacturers have begun to open up the CSI data (i.e., L-LTF data during the communication process) in WiFi modules, application manufacturers have the opportunity to use this data to develop related software applications. Since CSI data reflects channel changes, it is currently mainly used to detect spatial state changes, i.e., human presence recognition.
[0003] Channel state information (CSI) includes specific indicators, such as carrier signal strength, amplitude, phase, and signal delay. These indicators reveal the signal scattering, reflection, and power attenuation of the carrier as the transmission distance changes. It can be used to measure the channel state of wireless networks in Wi-Fi communications. By analyzing and studying the changes in CSI, the changes in the physical environment that cause the channel state changes can be inferred, that is, non-contact intelligent perception can be achieved. CSI is extremely sensitive to environmental changes. In addition to sensing environmental changes caused by large movements such as walking and running of people or animals, it can also capture subtle movements caused by small movements such as breathing and chewing of people or animals in static environments.
[0004] CSI data is a multi-dimensional data set (the dimension is determined by the number of subcarriers selected by the algorithm) that changes with time. By constructing a time domain matrix in time-sharing mode, mathematical statistical analysis is performed on the amplitude characteristics of a large amount of data, and the changes in the matrix eigenvalues over time are observed to determine changes in environmental conditions.
[0005] However, in the actual user environment, on the one hand, due to the different brands of routers and the differences in hardware design levels, the fluctuation range of the characteristic value change rate of CSI data generated by different routers in the unmanned state is actually different; on the other hand, due to the different sizes of the environmental spaces of different users and the different RSSI (WiFi signal strength) of the routers, the characteristic value change rates calculated in the unmanned state are also different. Therefore, using a fixed threshold for judging human movement will have a good effect on a certain router and environment, but there will be a more serious problem of misjudgment in other routers and environments. For example, in an unmanned environment, the CSI data of a router of a certain brand fluctuates greatly, and the fluctuation of its characteristic value change rate has exceeded the threshold for human movement, thus causing misjudgment. Conversely, if the threshold is set high, it may happen that the characteristic value change rate caused by human movement in some routers and environments with better performance cannot exceed the threshold, reducing the sensitivity of detection. The solution of fixed threshold is difficult to be compatible with various situations. Summary of the invention
[0006] In order to solve the above technical problems, the purpose of the present invention is to provide a dynamic threshold setting method and system for CSI human presence recognition technology, so that under different routers and user environments, there can be relatively ideal human motion detection sensitivity and stability of the unmanned state, providing an effective support for the industrial application of the CSI algorithm.
[0007] The present invention solves the above problems through the following technical solutions:
[0008] A dynamic threshold setting method for CSI human presence recognition technology, comprising:
[0009] Before performing human presence detection, first perform a basic threshold v in the unmanned state for the specific router and environment. Av and a fixed threshold v 0 The setting of the basic threshold v AV and a fixed threshold v 0 Calculate the final decision threshold v t , to pass the final decision threshold v t Determine whether there is anyone moving in the current environment; the specific formula is:
[0010] v t =v Av +v 0 ;
[0011] Among them, v 0 Indicates the fixed threshold value of the rate of change when someone is moving; v AV Indicates the basic threshold in the unmanned state.
[0012] As a further improvement, the basic threshold v Av The setting method is:
[0013] When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed;
[0014] Start the CSI human presence recognition algorithm through software, count the values of all eigenvalue change rates v of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time, and then average them, and take the average value as the basic threshold v AV .
[0015] As a further improvement, the basic threshold v AV The calculation method is:
[0016] Use all eigenvalues to construct an m*n matrix, calculate the variance of each row, i.e., the m eigenvalues, and obtain n variances v n , n is 1 to n; then take n variances v n The average value of; the formula is:
[0017]
[0018] Among them, v AV Indicates the basic threshold value in the unmanned state; v n Representing the rate of change v of all eigenvalues, construct an m*n matrix with the nth variance of m eigenvalues in each row.
[0019] As a further improvement, the x ≥ 30 seconds.
[0020] As a further improvement, all eigenvalue change rates v are collected by the host computer while ensuring that there is no one in the environment.
[0021] As a further improvement, the basic threshold v Av The setting method is:
[0022] When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed;
[0023] Start the CSI human presence recognition algorithm through software, count the values of all eigenvalue change rates v of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time, then take the maximum y values and average them, and take the average value as the basic threshold v AV .
[0024] As a further improvement, the dynamic threshold setting method performs a final decision threshold v when the router is used for the first time and when the router and / or the environment changes. t calibration.
[0025] In addition, the present invention also solves the above-mentioned problem through the following technical solutions:
[0026] A dynamic threshold setting system for CSI human presence recognition technology comprises a router, a WiFi module with built-in CSI human presence recognition algorithm software and a host computer, wherein the router is connected to the WiFi module via WiFi, and the WiFi module is connected to the host computer via TYPE-C. The dynamic threshold setting method for CSI human presence recognition technology as described above is implemented through the WiFi module with built-in CSI human presence recognition algorithm software, and the presence or absence of a person is displayed through a demonstration interface of the host computer.
[0027] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0028] (1) The present invention provides a dynamic threshold setting method and system for CSI human presence identification technology, which can achieve relatively ideal human motion detection sensitivity and stability of the unmanned state in different router and user environments, providing an effective support for the industrial application of the CSI algorithm.
[0029] (2) The present invention uses the basic threshold v in the unmanned state Av and a fixed threshold v 0 The setting of the basic threshold v AV and a fixed threshold v 0 Calculate the final decision threshold v t , to pass the final decision threshold v t It can determine whether there is someone moving in the current environment and is compatible with various routers and user environments, thereby improving the sensitivity and stability of detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 A schematic diagram of a CSI human presence recognition algorithm of the present invention;
[0031] Figure 2 A schematic diagram of a dynamic threshold setting system connection for a CSI human presence recognition technology. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical solutions and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be described in more detail below in conjunction with the drawings in the preferred embodiments of the present application. In the drawings, the same or similar reference numerals throughout represent the same or similar parts or parts with the same or similar functions. The described embodiments are part of the embodiments of the present application, not all of the embodiments. The embodiments described below with reference to the drawings are exemplary and are intended to be used to explain the present application, and should not be construed as limitations on the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.
[0033] In the description of the present application, it should be noted that, unless otherwise expressly provided and limited, in the description of the present application, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or display comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or displays.
[0034] The following will be combined Figure 1-2 , a method and system for setting a dynamic threshold of a CSI human presence recognition technology involved in an embodiment of the present application are described in detail. It should be noted that the following embodiments are only used to explain the present application and do not constitute a limitation on the present application.
[0035] Embodiment 1:
[0036] Refer to the attached Figure 1 ,A CSI human presence recognition algorithm utilizes the original L-LTF data in the WiFi communication process, extracts it and constructs a matrix of CSI data. The eigenvalues of these data constitute of the matrix for example, 20 data are taken and change with the change of the WiFi space state. The CSI data is continuous in time and is detected through a sliding window. Therefore, it is possible to judge whether there is a person in the WiFi transmission space by observing the changes of these matrix eigenvalues.
[0037] When the spatial state does not change, the CSI data is stable, and the eigenvalue of the CSI data construction matrix formed by the CSI data is stable.
[0038] When the spatial state changes, the CSI data changes accordingly, which is reflected in the eigenvalues of the CSI data construction matrix, that is, the mean of the eigenvalues changes over a period of time.
[0039] First, calculate the maximum eigenvalue e=max(eigen(A)) of the CSI data construction matrix A;
[0040] Then calculate the rate of change over a period of time Among them, e i Indicates i The eigenvalues of matrices; n is a set decision interval, which is a fixed value such as 20, that is, 20 matrices are judged once.
[0041] When the change rate v is greater than a certain threshold value, such as 0.01, it can be judged that someone is moving in the room; conversely, if the change rate v is less than the set threshold value, it is judged to be an unmanned state.
[0042] The CSI human presence recognition algorithm cannot meet the different brands of routers and hardware design levels when used in a real user environment. It also does not take into account the different sizes of environmental spaces for different users and the different RSSI (WiFi signal strength) of routers, which also leads to different eigenvalue change rates v calculated in the unmanned state.
[0043] Embodiment 2:
[0044] Combined with Figure 2 As shown, a dynamic threshold setting method for CSI human presence recognition technology includes: before performing human presence detection, firstly, a basic threshold v in an unmanned state is set for a specific router and environment. Av and a fixed threshold v 0 The setting of the basic threshold v AV and a fixed threshold v 0 Calculate the final decision threshold v t , to pass the final decision threshold v t Determine whether there is anyone moving in the current environment.
[0045] When the change rate v is greater than the final decision threshold v t If the change rate v is less than the final decision threshold v, it can be judged that someone is moving in the room; otherwise, t When , it is judged as no one state.
[0046] This method can achieve relatively ideal human motion detection sensitivity and stability in the unmanned state under different router and user environments, providing an effective support for the industrial application of the CSI human presence recognition algorithm.
[0047] In a specific embodiment, a dynamic threshold setting method for CSI human presence recognition technology includes the following steps:
[0048] When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed;
[0049] Start the CSI human presence recognition algorithm through software and count the change rates of all eigenvalues of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time v The value is then averaged and the average value is taken as the basic threshold v AV , plus a fixed rate of change value, i.e., a fixed threshold value v 0 , as the final decision threshold v for each specific router and environment to determine whether someone is moving t .
[0050] Preferably, in this embodiment, x is 30 seconds, and of course it can be other time lengths. When ensuring that there is no one in the environment, the host computer collects all the characteristic value change rates v output by the CSI human presence recognition algorithm within 30 seconds. Specifically, the change rates of all characteristic values output within 30 seconds are about 500.
[0051] Final decision threshold v t , the specific calculation method is:
[0052] 1.1. Count and average the values of all characteristic value change rates v within x time to obtain the basic threshold value v AV ;
[0053] First, we construct a 50×10 matrix with 500 eigenvalues and calculate the variance of each row, i.e., the 50 eigenvalues, to obtain 10 variances v n , n is 1 to 10; then take 10 variances v n The average value of .
[0054] The main purpose is to find the dynamic range center value of the characteristic value change rate under different routers and environments to ensure that no false positives are made when no one is present. Fixed thresholds may lead to false positives in some routers, and taking the average value is just one way.
[0055] The specific formula is:
[0056]
[0057] Among them, v AV Indicates the basic threshold value in the unmanned state; v n Representing the rate of change v of all eigenvalues, construct an m*n matrix with the nth variance of m eigenvalues in each row.
[0058] 1.2. Using the basic threshold v AV and a fixed threshold v 0 Calculate the final decision threshold v t ; The specific formula is:
[0059] v th =v Av +v0 ;
[0060] Among them, v 0 represents the fixed threshold value of the rate of change generated when a person moves. In the CSI human presence recognition algorithm of this embodiment, the fixed threshold value v 0 The value is 0.006.
[0061] In the CSI human presence recognition algorithm mentioned in this application, the fixed threshold v 0 Can be set to 0.006, according to the fixed threshold v 0 Different values are used. In addition to the final decision threshold v in the unmanned state when it is used for the first time t In addition to calibration, users can also actively initiate the final decision threshold v in the unmanned state through the APP according to the changes in the router or environment. t Of course, the CSI human presence recognition algorithm of this embodiment is not limited to the CSI human presence recognition algorithm in Embodiment 1, and other existing CSI human presence recognition algorithms are still applicable.
[0062] Embodiment 3, a method for setting a dynamic threshold value of a CSI human presence recognition technology, is different from Embodiment 2 in that the basic threshold value v Av The setting methods are different, and the specific steps include:
[0063] When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed;
[0064] Start the CSI human presence recognition algorithm through software, count the values of all eigenvalue change rates v of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time, then take the maximum y values and average them, and take the average value as the basic threshold v AV .
[0065] Furthermore, the dynamic threshold setting method performs a final decision threshold v when the router is used for the first time and when the router and / or the environment changes. t calibration.
[0066] Embodiment 4,
[0067] Refer to the attached Figure 2A dynamic threshold setting system for CSI human presence recognition technology includes a router, a WiFi module with built-in CSI human presence recognition algorithm software, and a host computer, wherein the router is connected to the WiFi module via WiFi, and the WiFi module is connected to the host computer via TYPE-C. The dynamic threshold setting method for CSI human presence recognition technology described in Examples 2 and 3 is implemented through the WiFi module with built-in CSI human presence recognition algorithm software, and the presence or absence of a person is displayed through a demonstration interface of the host computer.
[0068] Although the present invention is described herein with reference to the illustrative embodiments of the present invention, the above embodiments are only preferred embodiments of the present invention, and the embodiments of the present invention are not limited to the above embodiments. It should be understood that those skilled in the art can design many other modifications and embodiments, which will fall within the scope and spirit of the principles disclosed in this application.
Claims
1. A dynamic threshold setting method for CSI human presence recognition technology, characterized in that: include: Before performing human presence detection, first perform a basic threshold v in the unmanned state for the specific router and environment. Av and the setting of fixed threshold v0, and using the basic threshold v AV And the fixed threshold v0 calculates the final decision threshold v t , to pass the final decision threshold v t Determine whether there is anyone moving in the current environment; the specific formula is: v t =v Av +v0; Among them, v0 represents the fixed threshold of the rate of change generated when someone moves; v AV Indicates the basic threshold in the unmanned state.
2. According to claim 1, a dynamic threshold setting method for CSI human presence recognition technology is characterized in that: The basic threshold v Av The setting method is: When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed; Start the CSI human presence recognition algorithm through software, count the values of all eigenvalue change rates v of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time, and then average them, and take the average value as the basic threshold v AV .
3. According to claim 2, a dynamic threshold setting method for CSI human presence recognition technology is characterized in that: The basic threshold v AV The calculation method is: Use all eigenvalues to construct an m*n matrix, calculate the variance of each row, i.e., the m eigenvalues, and obtain n variances v n , n is 1 to n; then take n variances v n The average value of; the formula is: Among them, v AV Indicates the basic threshold value in the unmanned state; v n Representing the rate of change v of all eigenvalues, construct an m*n matrix with the nth variance of m eigenvalues in each row.
4. According to claim 2, a dynamic threshold setting method for CSI human presence recognition technology is characterized in that: The x≥30 seconds.
5. According to claim 2, a dynamic threshold setting method for CSI human presence recognition technology is characterized in that: All eigenvalue change rates v are collected by the host computer while ensuring that there is no one in the environment.
6. According to claim 1, a dynamic threshold setting method for CSI human presence recognition technology is characterized in that: The basic threshold v Av The setting method is: When the WiFi module with built-in CSI human presence recognition algorithm software is used for the first time, after the installation location is determined and connected to the router, an unmanned environment scan is performed; Start the CSI human presence recognition algorithm through software, count the values of all eigenvalue change rates v of the phase or amplitude matrix given by the CSI human presence recognition algorithm within x time, then take the maximum y values and average them, and take the average value as the basic threshold v AV .
7. The method for setting a dynamic threshold of a CSI human presence recognition technology according to claim 2 or 6, characterized in that: The dynamic threshold setting method performs a final decision threshold value v when the router is used for the first time, or when the router and / or the environment changes. t calibration.
8. A dynamic threshold setting system for CSI human presence recognition technology, characterized in that: The invention comprises a router, a WiFi module with built-in CSI human presence recognition algorithm software and a host computer, wherein the router is connected to the WiFi module via WiFi, and the WiFi module is connected to the host computer via TYPE-C. The dynamic threshold setting method of the CSI human presence recognition technology as claimed in claim 1 is implemented by the WiFi module with built-in CSI human presence recognition algorithm software, and the presence or absence of a person is displayed through the demonstration interface of the host computer.