Keywords

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

1 Introduction

The location of a mobile device or a user is one of the most essential pieces of information for emerging location-based services (LBS) and applications. For outdoor localization, Global Positioning System (GPS) has been widely used. For indoor localization, Wi-Fi fingerprinting is a promising technique. Wi-Fi fingerprinting first senses the Wi-Fi measurements at desired locations and generates Wi-Fi fingerprints for each of these locations. The correlated relationship between Wi-Fi fingerprints and locations is later used to locate mobile devices or users by comparing the current Wi-Fi measurement and learned Wi-Fi fingerprints. The phase of generating the Wi-Fi fingerprints is called the learning phase. The phase of determining the current location is called the positioning phase.

In the learning phase, the conversion approaches of the Wi-Fi fingerprinting technique usually rely on an extensive site survey with data annotation for the Wi-Fi fingerprint generation. Recently, many research groups focus on generating the Wi-Fi fingerprint without the need of data annotation, i.e., in an unsupervised manner, which is known as unsupervised localization. A typical unsupervised localization system is DCCLA (Density-based Clustering Combined Localization Algorithm) [1]. It can automatically learn and recognize the significant locations from Wi-Fi measurements continuously collected in a user’s daily life, without the requirement of data annotation or an explicit burden on users. Significant locations are locations where a user stays stationary for a while (e.g., at least 10 min).

Given Wi-Fi measurements continuously collected in a user’s daily life, we observe that when a user remains stationary in a location, the Wi-Fi measurements collected are similar to each other. Consequentially, the similar Wi-Fi measurements collected at a significant location show a high density. On the other hand, when a user keeps moving, the Wi-Fi measurements are dissimilar to each other, showing a low density. The density differentiation allows DCCLA to discover the significant locations in an unsupervised manner. Once a significant location is discovered, the Wi-Fi measurements collected is used to generate the Wi-Fi fingerprint of the location. As the generation of the Wi-Fi fingerprinting does not require data annotation, the system DCCLA is an unsupervised localization system.

However, since a user often visits the same locations (e.g., home or office) and stays there for a long while, DCCLA suffers from significant power consumption for mobile devices because of the continuous Wi-Fi collection. The problem can be addressed through activating Wi-Fi collection when it is necessary and deactivating Wi-Fi collection when “enough” data is collected. Specifically, the system enables activating Wi-Fi collection when a user stays at a significant location and deactivating Wi-Fi collection when optimal Wi-Fi collection duration is achieved and when the device is motion.

In this paper, we proposed to activate or deactivate the Wi-Fi collection based on the motion information of smartphones. The motion information is detected by using the acceleration readings from the embedded accelerometer sensor. The improved system benefits from saving power by only activating Wi-Fi collection when a user stays at a significant location and the system needs a learning dataset. In addition, we experimentally investigate the optimal Wi-Fi collection duration at a location to trade off the power consumption. The improved unsupervised localization system DCCLA with motion detection is tested by different users in real-world scenarios. The results show an improved performance of unsupervised localization, in terms of localization precision and power consumption.

This paper is organized as follows. In the next section, the works related to unsupervised localization and motion detection are presented. We then introduce the core idea of DCCLA and the motion detection algorithm for DCCLA. The performance of the system without and with motion detection is evaluated in the following section. In the end, the paper gives a conclusion.

2 Related Work

While outdoor localization is well supported by GPS, indoor localization, although attracting much attention, is still a research challenge. Wi-Fi networks provide a potential solution for indoor localization without additional costs of hardware installation. Some commercial software based on Wi-Fi fingerprinting localization has come to the market, including the Mobile Google Map [2], and Skyhook [3]. They usually generate a global database containing Wi-Fi fingerprints, known as a fingerprint database, by driving streets in cities and collect the Wi-Fi data at certain locations. However, these systems and applications require time-consuming and labor-intensive site surveys with explicit data annotation.

To eliminate the pre-deployment effort of site surveys, many research groups focus on learning significant locations from data collected in a user’s daily life (e.g., GPS, GSM, Wi-Fi, or Bluetooth signals) implicitly. Such approaches do not require manual data annotation.

comMotion [4] is one of the earliest systems for discovering significant locations based on continuously GPS readings. The GPS signal is lost when a user enters a building. If the signal has been lost within a given radius (e.g., 100 meters) on three different occasions, the system infers that the location (building) is significant. The approach from Ashbrook and Starner [5] discovers significant locations, where the GPS readings have a continuous gap of at least 10 min. Such approaches based on GPS reading gaps provide building-level accuracy since the GPS signal is lost within buildings.

BeaconPrint [6] works based on collected Wi-Fi measurements and GSM readings, under the assumption that the user stays in a significant location if the measurements remain fairly stable during a pre-defined time window (known as a stable state). Once the criterion of a stable state is satisfied, the location is discovered as a significant location. SensLoc [7] is a similar system, but reduces false location detection by exploiting received signal strength (RSS) changes. However, the approaches of discovering significant locations by detecting a stable state are sensitive to the Wi-Fi signal variations and noise during a short time.

In recent years, Density-based clustering [8] has been proposed to address the problems caused by signal variations and noise. It works under the observation that the Wi-Fi measurements at a location, although suffering from signal variations, are quite similar to each other. When a user stays at a location for a while, the location can be discovered based on the high-density of similar measurements. Examples of such systems include ARIEL [9] Place Learning [10], and DCCLA [1]. These systems can automatically learn, and later recognize the significant locations where a user stays for a while. However, such systems suffer from consuming quite some power for continuous Wi-Fi collection.

The embedded accelerometer sensor is utilized to assist localization in some systems by detecting user movements. In most cases, the acceleration data can be used for step counting, displacement estimation or reachability between different areas [1113], which is further utilized to improve the performance of localization in term of improving the location accuracy.

The accelerometer sensor is also used to save power by determining the moment a procedure of positioning should occur. Shafer, et al. [14] have proposed a strategy that the positioning only occurs when the system detect a user has moved to a new location. However, while such systems save power for positioning when using fingerprint database provided by others (e.g., Google, Skyhook), the power consumption for fingerprint learning is not considered, which is a huge amount when building their own fingerprint database. Different from many previous works, we utilize the accelerometer sensor to save power for both learning and positioning.

3 DCCLA with Motion Detection

DCCLA is an unsupervised indoor localization system using the Wi-Fi fingerprinting technique. “Unsupervised” indicates that the Wi-Fi measurements are implicitly and continuously collected in a user’s daily life without requiring users’ attention or data annotation. By processing the Wi-Fi measurements, the system can automatically discover and learn the significant locations where a user stays for a while (e.g., at least 10 min), and then recognize the locations when the user re-visits them.

A significant location is a location where a user stays stationary for a while (e.g., at least 10 min). The original DCCLA discovers significant locations by analyzing the Wi-Fi continuously collected. When the Wi-Fi measurements show a high-density distribution, a significant location is discovered.

When using an accelerometer sensor, the significant locations can be detected when a mobile device keeping in a stationary state at a location for at least 10 min. Based on motion detection, the unsupervised localization system activates Wi-Fi collection when a mobile device stays in a stationary state, and deactivates Wi-Fi collection when a mobile device stays a moving state.

When “enough” data is collected for place learning in a stationary state, more Wi-Fi collection consumes more power. The system enables deactivating the Wi-Fi collection when the optimal collection duration is achieved.

3.1 DCCLA

The localization procedure of the original DCCLA includes three phases: a collection phase, a learning phase, and a recognition phase. More details are available in the previously published paper [1, 1517].

Collection phase: The smartphone periodically collects Wi-Fi measurements from surrounding APs (Access Points). Wi-Fi measurements consist of a current timestamp, MAC (Medium Access Control) addresses and RSS (Received Signal Strength) values from all detectable APs.

Learning phase: DCCLA performs a density-based clustering algorithm. We define an RSS value from an AP in a Wi-Fi measurement as a point p. A set of points in the learning dataset, whose Euclidean distance (e.g., the absolute value of the difference of two RSS values) to the point p is smaller than a specific distance threshold Eps, is the neighborhood of p. The density-based clustering algorithm works as follows:

  • For a point p, if the number of the neighbourhood of p is equal to or larger than a density threshold MinPts, the point p and his neighborhood generate a cluster.

  • For a point p, if the number of the neighbourhood of p is smaller than MinPts, the point p is regarded as noise.

  • If any two clusters contain the same point(s), the two clusters are merged into one cluster.

A set of learned clusters, which belong to different APs related to the same timestamp of a Wi-Fi measurement, are combined to form a Wi-Fi fingerprint of a location.

Recognition phase: As the user visits a location, the current Wi-Fi measurement with n points is compared to the Wi-Fi fingerprints. If at least n-1 points in the current Wi-Fi measurement belong to a Wi-Fi fingerprint, the Wi-Fi fingerprint related to a learned significant location is recognized. Thus, DCCLA can recognize learned locations when the user re-visits them.

3.2 Motion Detection

The accelerometer sensor, embedded in smartphones, can be used to detect a mobile device’s/a user’s current motion state (i.e., in a stationary state or a moving state). Knowing the motion state, the system enables detecting a significant location and optimizing the Wi-Fi collection duration.

We implement a motion detection algorithm for DCCLA based on the continuous acceleration samples. It works based on the observation that the variation of the acceleration samples is large during a moving state, whereas the variation is small during a stationary state. In other words, a set of successive samples within a time window can be used to determine the motion state.

We select 4 s as the time window size. There are two reasons for the selection. First, the Wi-Fi collection frequency in DCCLA is 0.2 Hz. Thus, motion detection occurs at least once between two Wi-Fi collections. Secondly, according to our investigations, the time window of 4 s can tolerate some quick activities within a short period (e.g., to stand up and sit down quickly). The pseudo code of the motion detection algorithm is presented as follows.

The acceleration samples used in two successive time windows have a 50 % overlapping that can achieve improved precision than detecting without an overlapping.

In order to determine the optimal sampling frequency, we evaluate the precision of correctly detecting the motion states by using accelerometer readings with different sampling frequencies 5 Hz, 10 Hz, 20 Hz and 32 Hz (32 Hz is a high sampling frequency for activity detection).

Table 1. The precisions of motion detection using different sampling frequencies.

The result in Table 1 shows that the increase of the sampling frequency does not significantly improve the precision of correct detection. With the consideration of power consumption in the next chapter, a low sampling frequency of 5 Hz is optimal for the motion detection.

Based on the motion detection output, the system enables automatically activating and deactivating Wi-Fi collection. The Wi-Fi collection is activated only when the current state is stationary, and the last state is either moving or no state (i.e., the system just starts). It indicates the mobile stays at a fixed location from the moment on. The Wi-Fi collection is deactivated in the following two situations: (1) the current state is moving, and the last state is either moving or no state. It indicates the mobile leaves a fixed location from the moment on. and (2) the Wi-Fi collection duration at a location is longer than the optimal Wi-Fi collection duration. It indicates “enough” data is collected for learning.

4 Experimental Evaluation

The reasons for using an accelerometer sensor in the unsupervised localization system are to save power. As such, we need to evaluate the optimal collection duration and the power consumption without and with motion detection. We have designed three experiments to:

  • Determine the optimal collection duration D opt , which provides an optimal performance, when trading off with the power consumption;

  • Investigate how much power can be saved with the motion detection algorithm;

  • Evaluate the performance of DCCLA with motion detection by different users in real-word scenarios.

We select an office area with adjacent rooms for the investigations. The Wi-Fi measurements from available APs in the surrounding are collected with a sampling frequency of 0.2 Hz. The office area is located on the second floor of a three-storey building. The area consists of five office rooms next to each other. The layout of the office area is shown in Fig. 1.

Fig. 1.
figure 1

The office area and the Wi-Fi collection locations, i.e. the positions of smartphones used for the evaluation.

The location accuracy of DCCLA is room-level. The room-level accuracy means the system is likely to be able to locate a mobile device in a room where the mobile device or an occupant is. The room-level accuracy, in the most cases, indicates 3–5 m error distance. DCCLA can learn and recognize a room correctly without having it mistaken for another room, even though the rooms are adjacent.

To evaluate the performance of achieving room-level accuracy, we define a set of evaluations metrics. Correct means a smartphone is in a room, and the system recognizes it is in this room. False means a smartphone is in a room, but the system recognizes it is in a different room. Missed means a smartphone is in a room, but the system does not recognize where it is.

Recognition Precision ( RP ) is defined as the number of “Correct” recognitions divided by the number of recognized attempts. It indicates how well the DCCLA can recognize a room correctly.

$$ CP = \frac{\mathop \sum \nolimits Correct}{\mathop \sum \nolimits Correct + \mathop \sum \nolimits False} \times 100\% $$

Response Rate ( RR ) is defined as the number of “Correct”s divided by the number of the total attempts. It indicates how often the Wi-Fi measurements from a given room are correctly recognized.

$$ RR = \frac{\mathop \sum \nolimits Correct}{\mathop \sum \nolimits Correct + \mathop \sum \nolimits False + \mathop \sum \nolimits Missed } \times 100\% $$

4.1 Optimal Wi-Fi Collection Duration

In order to determine the optimal Wi-Fi collection duration D opt , we learn the locations (i.e., rooms) using datasets of the following Wi-Fi collation durations D: 5, 10, 15, 20, 30, 45, 60, and 120 min in each room. The recognition phase is performed using the subsequent 60 min of Wi-Fi measurements from each room. The results are summarized in Fig. 2. From previous evaluations of DCCLA without motion detection [1], we deduced that the ideal MinPts is approximately one-third of the total number of Wi-Fi measurements. This parameter can be dynamically set when the Wi-Fi collection duration is controlled by the motion detection algorithm.

The results in Fig. 2 show that the optimal Wi-Fi collection duration is between 10 min and 30 min, when observing both RP and RR performance. Based on the experimental observations, we keep the Wi-Fi collection duration in our experiments between 10 min and 30 min. When a user stays at a location for less than 10 min, the Wi-Fi measurements are discarded. When a user stays at a location for more than 30 min, the Wi-Fi measurement is deactivated to save power, and 30 min of Wi-Fi measurements are used for location learning.

Fig. 2.
figure 2

The performance of recognition precision and response rate with different collection durations (Minutes) (Color figure online).

4.2 Power Consumption

The power consumption of DCCLA with motion detection consists of two parts: the Wi-Fi measurement and the accelerometer sampling. To test the power consumption, we installed the experimental setup as shown in Fig. 3. To measure the power consumption, the experimental setup consists of a combination of hardware and software. The hardware includes a Samsung Galaxy S2 smartphone with a battery of 3.7 V and 1650 mAh capacity, two Peaktech digital-multimeters. The software running on a laptop is to record the voltage and current measurements, respectively. The recording frequency is 2 Hz.

Experiments are carried out in three different settings. In each setting, we take 10 min as measurement duration. We measure each setting three times, respectively.

Fig. 3.
figure 3

The experimental setup to measure the power consumption of Wi-Fi measurement and accelerometer sampling.

Fig. 4.
figure 4

The power consumption of Wi-Fi measurements (upper right) and accelerometer sampling (upper left), as well as the power consumption of DCCLA without and with motion detection (lower).

Setting 1: A smartphone periodically collected the Wi-Fi measurements with different frequencies of 0.2, 0.1, 0.05, and 0.03 Hz.

Setting 2: A smartphone periodically read the accelerometer samples with different frequencies of 1, 5, 10, 20, 32 Hz.

Setting 3: A smartphone collected Wi-Fi measurements without and with the assistant of accelerometer readings. The Wi-Fi measurement frequency for both systems with and without motion detection is 0.2 Hz. The accelerometer sampling frequency for the system with motion detection is 5 Hz.

The power consumptions for Settings 1, 2 and 3 are shown in Fig. 4. We can observe that the acceleration acquisition consumes 73 mW with a sampling frequency of 5 Hz, whereas it consumes 134 mW with a sampling frequency of 32 Hz. For the Wi-Fi measurement with different measurement durations, the power consumption is at least 280 mW. However, the acceleration acquisition consumes less power than Wi-Fi measurement even with a high accelerometer sampling frequency of 32 Hz. Based on the observations we compare the power consumption of the system without and with the assistant of accelerometer readings. We assume with the assistant of accelerometer readings, the Wi-Fi measurement duration can be reduced to half compared to DCCLA without the assistant of accelerometer readings. In such case, compared with the power consumption of the system without motion detection, the average power consumption for the system with motion detection saves power of almost 30 %.

4.3 Tests in the Real-World Scenario

The real-world tests were carried out in the student activity area as Fig. 5 shows. The area includes a computer pool 2417, a kitchen 2414 and a meeting room 2413, where students spend a part of their day. Smartphones were carried by three different users, whose motion patterns were different.

Fig. 5.
figure 5

The student activity area, where the system was tested by three different users.

For each user, the learning dataset in each location was collected in the first 30 min during the stationary state detected based on accelerometer readings. The recognition dataset was the subsequent 15 min from each location after each location is automatically learned.

Figure 6 shows the test results. We can observe that DCCLA without motion detection performs unsupervised localization with an average RP of 78.60 % and an average RR of 68.20 %. DCCLA with motion detection achieves a better performance with an average RP of 99.93 % and an average RR of 64.08 %. The results indicate that DCCLA with motion detection can learn and recognize a room with improved recognition precision, while maintaining the response rate.

Fig. 6.
figure 6

The comparison of DCCLA performance without (right) and with motion detection tested (left) by three different users.

5 Conclusion

While the unsupervised localization system DCCLA can automatically learn and recognize the significant locations from the continuously collected Wi-Fi measurements, the system usually suffers from consuming large amounts of power of mobile devices caused by continuous Wi-Fi collection. With motion information (i.e. in a stationary state or in a moving state) determined by acceleration readings, DCCLA with motion detection enables automatically activating Wi-Fi collection when the mobile device stays at a significant location and deactivating Wi-Fi collection when the mobile device keeps moving or “enough” data is collected at a significant location. As such, the system can reduce the power consumption.

Our experiments have shown that DCCLA with motion detection saves almost 30 % power when the Wi-Fi measurement duration is reduced to half compared to DCCLA without motion detection. The system has been tested in a real-world scenario by three different users. With the assistance of accelerometer readings, DCCLA achieves room-level accuracy with a recognition precision of 99.93 %. Thus, the unsupervised localization system DCCLA with motion detection can reduce the power consumption, while maintaining the localization performance of the unsupervised localization system.