CSI Frequency Domain Fingerprint-Based Passive Indoor Human Detection

Passive indoor personnel detection technology is now a hot topic. Existing methods have been greatly influenced by environmental changes, and there are problems with the accuracy and robustness of detection. Passive personnel detection based on Wi-Fi not only solves the above problems, but also has the advantages of being low cost and easy to implement, and can be better applied to elderly care and safety monitoring. In this paper, we propose a passive indoor personnel detection method based on Wi-Fi, which we call FDF-PIHD (Frequency Domain Fingerprint-based Passive Indoor Human Detection). Through this method, fine-grained physical layer Channel State Information (CSI) can be extracted to generate feature fingerprints so as to help determine the state in the scene by matching online fingerprints with offline fingerprints. In order to improve accuracy, we combine the detection results of three receiving antennas to obtain the final test result. The experimental results show that the detection rates of our proposed scheme all reach above 90%, no matter whether the scene is human-free, stationary or a moving human presence. In addition, it can not only detect whether there is a target indoors, but also determine the current state of the target.


Introduction
With the rapid development of network technology, wireless signals are basically everywhere.Since Wi-Fi is easy to use and low cost, indoor personnel detection based on Wi-Fi has become very popular.Passive personnel detection does not require the target to carry a specific device, which leads to a wide range of prospects in geriatric surveillance [1,2], fire search and rescue, security detection [3], smart homes, and so on.At the same time, it can also be applied to technologies like indoor positioning and tracking [4,5].
In indoor environments, wireless signals reach the receiving end through multiple paths including reflection, diffraction, and scattering.The received signal is the fusion of wireless signals transmitted through different paths, each of which has different time delay, signal attenuation and phase change.Passive indoor personnel detection can be achieved through the analysis of wireless signal changes under different situations.In general, passive indoor personnel detection is based on two main metrics in Wi-Fi signals: RSSI [6] (Received Signal Strength Indicator) and CSI [7] (Channel State Information).CSI is more fine-grained and stable than RSSI, but it requires specialized equipment to gain accurate CSI signals, which becomes a hindrance in initial research.In 1999, OFDM technology [8] (Orthogonal Frequency Division Multiplexing) was adopted as the physical layer standard in IEEE 802.11a.Due to its high transmission quality and anti-transmission interference, OFDM has been widely used in the communication process.Researchers can get a sample version of CFR on different sub-carriers (CSI) by modifying firmware, so recent research has turned to using finer-grained CSI information.Current intrusion detection technologies still have some problems that need to be improved.Some methods cannot detect immobile targets and some of the algorithms are too complicated to be applied.Therefore, passive indoor personnel detection technology needs further study.
Since the fingerprint model [9] is currently the mainstream technology due to its advantages such as small consumption, simple parameter acquisition and high precision, this paper proposes the passive indoor personnel detection based on CSI fingerprints.Specifically, the scheme is divided into two phases, offline and online.In the offline phase, we extract CSI and generate characteristic fingerprints based on the impact of different indoor wireless signals.Then, we match the online fingerprints with the offline fingerprints to determine the state in the scene, and employ a voting scheme that combines the detection results of three receiving antennas to output the final decision.
The main contributions of this paper are summarized as follows: 1. Considering that existing passive personnel detection methods rely on a target's mobility and suffer from environmental changes, low robustness and detection accuracy, we use the highly sensitive CSI information to design a method based on the frequency domain fingerprint, combining the results of multi antenna voting to improve the detection accuracy.2. Through experiments, we find that the detection rate is above 90%, no matter whether the scene is human-free, stationary or a moving human presence, which verifies the effectiveness of this scheme.
The rest of this paper is organized as follows.Section 2 introduces the related work.Section 3 presents some preliminaries.The overall design of passive intrusion detection is presented in Section 4.
We also analyze the CSI frequency domain fingerprint under different states.The experimental verification and analysis are presented in Section 5. Finally, conclusions and future work are derived in Section 6.

Related Work
The traditional intrusion detection system relies on special devices such as video surveillance [6].Due to the low accuracy of detection with a single visible light camera, Wang et al. [10] fused two kinds of video data based on visible light and infrared imaging equipment, and proposed a fusion of two-channel video personnel detection systems based on neural network technology.In addition to video surveillance, acoustic [7] or infrared technology [11] can also be used to identify intrusion to some extent.Choi et al. [12] estimated the amount of change in the acoustic signature in the house through the acoustic wave propagation function and then judged whether it was an intruder.Because the body temperature is similar to the constant temperature, and bodies will always emit heat, Cheng et al. [13] used a pyroelectric infrared sensor to detect the body's infrared radiation.It can detect the moving human within the effective range covered by the sensor and judge the body appearance and gait characteristics of the human according to the collected imaging so as to make classification.This method is low cost and has high reliability.Although these intrusion detection methods can achieve a certain degree of detection accuracy, they all have limitations.Video surveillance relies on high-definition cameras and data processing equipment.Although the cameras are low cost, they are exposed to the environment and easily get damaged, which will negatively affect the effect of real-time monitoring.The technologies based on acoustic wave and infrared ray require special equipment, which is not cost-effective.Meanwhile, the infrared technology can not cover the target area completely and the detection accuracy is low.In addition, some methods can only detect the target that carries device in the monitoring.
With the continuous development of science and research, the technical means and methods of intrusion detection have been greatly improved, and a relatively complete technical system is gradually formed.The concept of passive detection in a wireless environment [14] was first proposed by Youssef et al. in 2007.Then, the DFL (Device-Free Localization) intrusion detection system [15] was implemented, i.e., the target can be detected without any wireless transceiver equipped.This method can be widely applied.Kaltiokallio et al. [16] proposed a distributed approach with the received signal strength collected by wireless network nodes to achieve intrusion detection.Mrazovac et al. [17] used the irregular phenomenon of wireless signal transmission and achieved intrusion detection by means of analyzing the main components of signal strength.Because when the target appears on the signal link, the signal strength received from sensor nodes will have some changes.Zhang et al. [18] conducted extensive research on passive intrusion detection techniques and proposed a method by using midpoint and cross-point algorithms.The main principle is that, if the target appears at different locations in a wireless link, the RSSI of each link will produce various degrees of change, and the intrusion detection can be achieved when multiple links are combined.Fernandes et al. [19] achieved intrusion detection through analyzing wavelet coefficient together with the change of RSSI data caused by the interference of intruders, and they combined with wavelet coefficient analysis to achieve intrusion detection.Alfandi et al. [20] used the ZigBee network to detect a person by analyzing the fluctuations of the signal strength in the network.Han et al. [21] used the received signal strength measured between the sender and the Anchor module to determine that an object has entered a predefined area on the condition that the RSSI must exceed a specified threshold.Younus et al. [22] made the detection based on the fact that the appearance of the intruder will change the received signal strength between the transmitter and receiver, and they established a controlled environment to approximate the intruder's weight and its mode of motion.Although these algorithms are successful, RSSI signals are easily affected by environmental changes, multipath fading and frequency-selective fading, leading to low robustness and reliability of the system if the RSSI is used as an input signal.
CSI represents the more fine-grained physical layer information compared with RSSI.CSI describes the changes of amplitude and phase in subcarriers.The number of subcarriers in this paper is 30.Based on these characteristics of CSI, a large number of related applications have been proposed.Brauers et al. [23] proposed a process of using channel state information to detect the presence of mobile objects reliably.When people pass through the room, they used CSI instead of RSSI and took into account the frequency-selective fading characteristics of indoor wireless channels while eliminating consumption impact of power level fluctuations in wireless hardware.Lv et al. [24] proposed a detection method that will not be affected by the moving speed of the target.They captured the variance of the amplitude differences of the CSI subcarriers and the HMM (Hidden Markov model) was used to solve the problem of entity detection.Qian et al. [25] extracted the amplitude and phase information of CSI to form the sensitive index of target detection to detect the moving target.FIMD (Fine-grained Device-free Motion Detection) [26] and the intrusion detection part of Pilot system [27] were proposed by Xiao et al., both of which used CSI information to extract feature fingerprints in the time domain.However, the wireless signals in the time domain are affected by the environment, so the methods had limitations and the accuracy was low.Although these passive intrusion detection technologies require no special equipment and are low cost and easy to implement, there are still some problems that need to be improved.For example, some methods can only be achieved with the moving target in the detection area.Some algorithms are too complex to be practical.
In summary, passive personnel detection technologies need to be further investigated.In this paper, we propose a passive indoor personnel detection method based on Wi-Fi, which we call FDF-PIHD (Frequency Domain Fingerprint-based Passive Indoor Human Detection).Through this method, fine-grained physical layer channel state information can be extracted to generate feature fingerprints so as to help determine the state in the scene by matching online fingerprints with offline fingerprints.In order to improve accuracy, we combine the detection results of three receiving antennas to obtain the final test result.

Preliminary
Two main metrics of Wi-Fi signals (RSSI and CSI) are introduced in this section, and the feasibility of FDF-PIHD is also analyzed.

Received Signal Strength Indicator and Channel State Information
RSSI is easy to obtain in wireless communication technology and cellular network technology, so it is used in traditional wireless sensors.However, RSSI only represents the energy feature of the media access control (MAC) layer, making it very unstable and easily affected by multipaths, which can only be applied to the simple environment and a scene with low precision.Specifically, in the whole process of transmission indoors, the wireless signal needs reflection, diffraction and scattering, and finally arrives at the receiver through multiple paths.Wireless signals from different paths have different delays, attenuations, and phase changes.A receiver receives a signal composed of these complex wireless signals in a time point.RSSI is a very unstable superimposed value from multiple paths.Fluctuations occur at different time points, even in a static link with no human interference.This is due to the fact that, although the fluctuations from one path are very small, the superimposition of all the links may cause the final value to change drastically.CSI is a physical layer characteristic.In the field of wireless communication, CSI refers to a channel attribute of a communication link, and it describes the attenuation factors of the signal transmission between the transmitter and the receiver, including the information of scattering, environmental attenuation, distance attenuation, and so on.Figure 1 shows three of the multiple CSI indoor transmission paths.The corresponding signal waveform is drawn in Figure 2. CSI is more granular and stable than RSSI.In a stable channel, channel information can be modeled in the frequency domain as Equation ( 1): where y and x are vectors of the received and transmitted signals, respectively, H is a channel information matrix, and n is a Gaussian noise vector.Through Equation (2), we can get the CSI calculation of all subcarriers: where H est is the estimated value.According to the different drivers of the receiving end, the CSI will be divided into different subcarrier groups, so the matrix H of CSI can be expressed as Equation ( 3): where N is the number of subcarriers divided according to the driver, and usually N = 30, H i is the CSI on the i-th subcarrier, which is expressed as Equation ( 4): where |H i | and ∠H i are the amplitude and phase of the i-th subcarrier.

Feasibility of Distinguishing Indoor Conditions through Frequency Domain Fingerprinting
In human-free indoor environments, wireless signals arrive at the receiver through multiple paths with different time-delays, attenuations and phase changes in the propagation process.When the target appears, it will influence 30 sub-carriers at the same time.The stationary target and the moving target have varying degrees of influence on the wireless signals transmitting in the space, so that the state of the target indoor can be judged.We show this effect through the correlation between CSI subcarriers, and then the characteristic fingerprint C generated by the data received by each receiving antenna is: where hi is the i-th subcarrier vector in the CSI matrix, and C i,w is the correlation coefficient between the i-th subcarrier and the i + 1-th subcarrier in the w-th window.According to Equations ( 5) and ( 6), characteristic fingerprints are calculated with the CSI received by the three antennas under three states and the nuclear density image is drawn.As can be seen from Figure 3, the fingerprints of three states under each antenna are clearly distinguishable.From the correlation point of view, there is the least correlation in human-free state, followed by the stationary human presence, and the correlation becomes the highest in the state with moving human presence.This verifies three assumptions that it has no impact on the wireless signal when no one is in the room, the presence of stationary target in the room causes less influence on the wireless signal, and the moving target has the most obvious impact on the wireless signal.At the same time, there are also differences in CSI fingerprint density in three states.Therefore, the construction of frequency domain fingerprinting can be used to distinguish different states within the scene.

System and Methodology
This section mainly describes the detailed design of the indoor passive intrusion detection scheme, including the offline training phase and the online matching phase.
The FDF-PIHD is a device-free method.It only needs an ordinary commercial router capable of sending wireless signals and a computer equipped with an Intel 5300 network card.FDF-PIHD is low-cost and easy to implement without the need for additional wireless devices and the target to carry the related sensor devices.
This scheme extracts the effective fingerprint in the frequency domain based on fine-grained physical layer information-CSI.The process is shown in Figure 4.In the offline part, we train the fingerprint corresponding to the three indoor states and store as the offline fingerprint library.In the online phase, the characteristics of the sampling signal is calculated and the online fingerprint and offline training fingerprint are compared so as to determine the current indoor state according to the degree of similarity and the state of the target indoors.After obtaining the results of each receiving antenna, we use the voting scheme to determine the final results.

Offline Phase
We collected data at multiple measurement points in three states: human-free state, a state with a static target and a state with a moving target.We used the correlation between sub-carriers to show the effect of the target on the wireless signal.At the same time, we selected one second as a sliding window to calculate M correlation coefficient values.In order to satisfy the generality, several sets of offline fingerprints of different periods were calculated and averaged.The collected CSI matrix shows the channel gain on different subcarriers from the transmitting antenna to the receiving antenna, and the CSI matrix H received by each antenna at one measurement point is shown in Equation ( 7): Each line is shown as a subcarrier, and each subcarrier vector h i is expressed as (packet rate is 50 packets per second, t for time): In wireless communication, the propagation of CSI is affected by multipath effects and the environmental changes, and the original data will be mixed with a certain amount of noise inevitably.We use median filtering to reduce noise and eliminate outliers.All the CSI matrices used in experiments were performed on the noise-reduced data.In the previous section, we have verified that frequency-domain fingerprint can distinguish different states under a scene.In the following, we construct an offline fingerprint library based on this conclusion.5) is the fingerprints trained by a set of offline training sets.In order to get more accurate results, the final offline fingerprint C o f f is the result of the average of the g groups' fingerprints:

C in Equation (
C sta_o f f is the offline fingerprint in no one scene.We calculate it according to Equations ( 5) and (9).CSI data of multiple test points are collected when the target exists in the scene.Therefore, when the fingerprints are calculated under the other two situations, the fingerprints of each set of offline training sets are the result of the average fingerprints of the l test points, which is denoted as C: According to Equation ( 10), we computed the fingerprints Cstan (a stationary target in the scene) and the fingerprints Cdyn (a dynamic target in the scene) by each set of offline training sets, and then put it into Equation ( 9), the final offline fingerprints Cstan and Cdyn in both states together with C sta o f are formed as an offline fingerprint library.

Online Detection and Status Judgment
Collecting a set of online data, we calculate the correlation coefficient matrix C on with the data of each receiving antenna according to Equation (5).
We use Euclidean distance to compare the similarity between online fingerprint C on and offline fingerprint C o f f .Similarity Measurement is normally achieved through calculating the "distance" between samples.The distance D is as follows: D sta , D stan and D dyn are the distances between the online fingerprint C on and the offline fingerprints C sta_o f f , C stan_o f f and C dyn_o f f .They are calculated according to Equation (11), and the shortest distance D min is selected as Equation ( 12): When D min =D sta , the output result shows no one is over the scene.When D min =D stan , the output result shows a stationary object in the scene.When D min =D dyn , the output result is that there is a dynamic target in the scene.In order to verify whether the state of the scene can be judged according to the similarity between online fingerprints and offline fingerprints, we took 10 sets of online fingerprints in three states to calculate the Euclidean distance corresponding to antenna 1.Three line graphs in Figure 5 correspond to three states: no one in scene, a stationary object in scene and a dynamic target in scene.At the same time, D sta , D stan and D dyn are the minimum distances corresponding to each state, and the similarity calculation method is feasible.

Multiple Antenna Voting
The online phase is the output of a single receiving antenna.In a practical experiment, we use three antennas to receive the CSI matrix transmitted from the transmit antenna.It is mentioned above that we determine the specific state of the scene by comparing the similarity of online and offline fingerprints based on a single receiving antenna.On this basis, if the output results of the two or more antennas are the same, the result is the final output result; if the judgment states of the three antennas are different from each other, the judgment fails.

Experiment Results
In this section, the layout of the experimental scenario is introduced, and the results of this scheme and the anomaly detection part in the pilot system are compared in this scenario.In the experiment, we choose different numbers of CSI data packets as a set of offline training sets to investigate whether the accuracy of the detection rate is affected.We collect enough data in three different states (human-free, a stationary and a moving human presence, we call them state 1, state 2 and state 3 in this section) under different time periods, and use these data as offline training sets and online test sets.

The Layout of the Experimental Scene
We use a Wireless Access Point (AP), a wireless router, and a computer with a 3-antenna Intel 5300 NIC (Network Interface Card) as a monitoring point (MP) in a 8.5 m × 5.7 m indoor scene and get CSI data by modifying the firmware.The experimental platform is a Wi-Fi based wireless sensing system platform built by the integrated installation tool (TNS-CSI Tool) based on a "Linux 802.11nCSI Tool".
Before collecting offline data, we first need to establish a reasonable distribution of indoor measurement points.We divide the ground equally into 32 1 m × 1 m areas outside the occupied area by table and chairs.The center of each area is set as a measurement point; AP and MP are placed on two sides of the scene as shown in Figure 6.

Impact of Multiple Antennas' Voting on Test Results
Considering the fact that the impacts of different target states on wireless signals are different, in this scheme, we generate feature fingerprint and determine the state of the scene by comparing the similarity between online and offline fingerprints.In the experiment, five groups of D sta calculated by 10 groups of online data received by antenna 3 are not the shortest distances under the static environment.If the result of detection by one antenna is regarded as the final output result, half of the output results are wrong in these 10 groups of sampled data.However, we apply the method of multiple antennas voting.Then, in these five groups, D sta corresponding to antenna 1 and antenna 2 are the smallest.In that way, the detection results of more than two antennas have static environments with the same sampling point, so 10 randomly selected sets of sample data have a detection rate of 100%.Similarly, when the stationary target and dynamic target are in the scene, the corresponding distances D stan and D dyn are not the smallest ones under one of the three antennas, while they are likely to be the smallest distance under the two other antennas, except for individual examples.In Figure 7, the abscissas 1, 2, and 3 respectively represent three states.We find that when there is just one target in the scene, the detection rate of a single antenna is 69.5%; when there is a stationary target in the scene, the detection rate of a single antenna is 74.2%.The detection rate obtained after multiple antennas' voting is obviously higher than that obtained from the single Antenna, without the situation when there is a moving target in a scene.

Detection Rate Comparison between FDF-PIHD and the Pilot
The Pilot method [27] used the time stability of CSI to complete the anomaly detection.The author formulated a threshold as a criterion to determine whether there is a target intrusion according to the stability of the signal in the time domain without interference combined with the fingerprints trained offline.After calculating the fingerprints according to the pilot method, we find that the correlation coefficient values of all three states are all between 0.9 and 1, and the correlation coefficients calculated under states 2 and 3 are very close without significant difference in these two situations.Figure 8 shows the bar graphs for detection rates and false alarm rates of the indoor state obtained in these two methods when 750 packets are taken as the training set for a group.We can know that the Pilot method cannot discriminate between two states well when there is a stationary target and a dynamic target in the scene, and the static detection rate is only 77% at the maximum.However, the detection results of three states in the scenario in our method can reach more than 90%.At the same time, the false alarm rate of this scheme is far lower than that of the Pilot method.

The Impact of the Number of Packets Used for Fingerprinting on Test Results
The greater the number of fingerprints in each state, the more accurate the corresponding detection rate will be.In order to ensure the generation of as many fingerprints as possible, we set the sliding window as 50.Based on the unchanged sliding window, we change the number of packets needed for online fingerprints by changing the number of packets that are used for each set of offline training sets, and analyze its impact on test accuracy.We use 750 and 500 data packets, respectively, as a set of offline training sets.We draw a histogram as shown in Figure 9 after finishing all the data collected in the experiment.It precisely indicates the changes of detection rate.The detection rates of three states are rising with the increase in the number of packets.When 500 packets are used, the static detection rate is 96.67%, a static target detection rate 90.89%, and the dynamic detection rate 100%.When 750 packets are used, the static detection rate is 97.5%, the static target detection rate is 92.58%, and the dynamic detection rate is 100%.Based on the assumption that the detection rates of all three states should be above 90%, the minimum number of packets required for the training set and the online test set is 500.

Conclusions
In FDF-PIHD proposed in this paper, we extract valid CSI features and calculate the correlation between subcarriers in the frequency domain to generate fingerprints, which can effectively avoid the problem that wireless signals in the time domain may be affected by the environment.Meanwhile, we use a voting method to reduce the mistakes in reporting, which guarantees high detection accuracy.In addition, the method can not only detect whether there is a target in the scene, but also determine the specific state of the target.On this basis, we intend to conduct further studies in the area of passive indoor positioning.

Figure 1 .
Figure 1.Three signals of the propagation paths.

Figure 2 .
Figure 2. Signal waveform of three propagation paths.

Figure 4 .
Figure 4. Flow chart of the proposed FDF-PIHD (Frequency Domain Fingerprint-based Passive Indoor Human Detection) method.

Figure 5 .
Figure 5.The Euclidean distance of three states under 750 data packets on antenna 1.(a) online human-free fingerprint; (b) online stationary target fingerprint; (c) online moving target fingerprint.

Figure 6 .
Figure 6.The layout of the experimental scene.

Figure 7 .
Figure 7.The influence of the number of antennas on the detection rate.

Figure 8 .
Figure 8.Comparison diagram of detection rate and false alarm rate.(a) online human-free fingerprint; (b) online stationary target fingerprint.

Figure 9 .
Figure 9. Detection rate of different data packets.