Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
net/publication/330713199
CITATIONS READS
0 95
6 authors, including:
7 PUBLICATIONS 11 CITATIONS
University of Novi Sad
378 PUBLICATIONS 2,364 CITATIONS
SEE PROFILE
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Sasa Pesic on 29 January 2019.
Saša Pešić
University of Novi Sad, Faculty of Sciences, Department of Mathematics and Informatics, Trg
Dositeja Obradovića 4
Novi Sad, 21000, Serbia
sasa.pesic@dmi.uns.ac.rs
Milenko Tošić
VizLore Labs, Braće Ribnikar 56
Novi Sad, 21000, Serbia
milenko.tosic@vizlore.com
Ognjen Iković
VizLore Labs, Braće Ribnikar 56
Novi Sad, 21000, Serbia
ognjen.ikovic@vizlore.com
Miloš Radovanović
University of Novi Sad, Faculty of Sciences, Department of Mathematics and Informatics, Trg
Dositeja Obradovića 4
Novi Sad, 21000, Serbia
radacha@dmi.uns.ac.rs
Mirjana Ivanović
University of Novi Sad, Faculty of Sciences, Department of Mathematics and Informatics, Trg
Dositeja Obradovića 4
Novi Sad, 21000, Serbia
mira@dmi.uns.ac.rs
Dragan Bošković
VizLore Labs, Braće Ribnikar 56
Novi Sad, 21000, Serbia
dragan.boskovic@vizlore.com
Indoor positioning systems are gaining the attention of the research community and
industry that try to solve challenges in the domain of smart spaces. In this paper, we
propose BLEMAT, a space-agnostic, context-aware fog computing system that performs
real-time indoor positioning, fingerprinting and floor plan layout detection. BLEMAT ac-
quires high accuracy and precision in position estimation while maintaining low resource
utilization. Through offering an approach to fingerprinting without system downtime,
1
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
2 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
BLEMAT takes a significant step in diminishing human efforts required to build signal
propagation maps. Furthermore, BLEMAT is a space-agnostic positioning system, aim-
ing to detect the floor plan layout of the operational context of the system. Based on
the results described in this paper, we are confident that the BLEMAT provides a solid
basis for deployment of high-performance location-aware IoT services and applications.
1. Introduction
The Internet of Things (IoT) services and applications rely heavily on context in-
formed decision making when performing automation of every day and mission-
critical operations. One of the main aspects of contextual awareness is knowing
precise location and spatial distribution of managed resources and IoT system users
in order to make proper decisions. This is why concepts like indoor positioning
and location tracking are gaining the attention of the research community and
industry that tries to solve challenges in the domain of smart spaces1 . These chal-
lenges include the efficient utilization of resources and energy efficiency2 , emergency
evacuation3 , security fencing, and asset tracking. In order to be solved, they require
knowledge of mobility patterns, space organization and layout and real-time location
of specific assets. Indoor positioning does not have a robust solution like outdoor po-
sitioning based on the global navigation satellite systems (GNSS). It relies on less
precise techniques based on video surveillance or wireless radio technologies like
Bluetooth, WiFi, Near Field Communication (NFC), etc. Solutions based on ra-
dio technologies are less intrusive than video surveillance, but, traditionally, require
detailed contextual insights including software representation of floorplans, organi-
zations‘ schedules and signal propagation maps. Preparing and maintaining these
contextual inputs for indoor positioning systems (IPS) is a cumbersome manual
task. This is why machine learning (ML) techniques are introduced as a potential
solution for indoor positioning based on radio signal propagation. Systems based
on ML collect signal and position related measurements and learn about their sur-
roundings and different patterns that impact the accuracy of the position estimation
tasks.
Services that leverage IPS are often referred to as position-based or location-
based services. On the other hand, there are proximity-based services, which provide
only information about the proximity of the object or a person, without disclosing
the exact position. IPS refer to a framework of network devices that communicate
wirelessly in order to provide position estimations of objects or people. There are
two distinguishable categories of IPS4 :
In the IPS that belong to the first group, position estimation is frequently de-
rived from point-to-point touch-based events (e.g. an employee scanned his ID card),
thus deliberating the system of heavy data collection, signal noise processing, signal
filtering, and finally position estimation calculation through triangulation or tri-
lateration. IPS that belong to the second group offer position estimation through
the observance and collection of different sources of signal. Often, receiver signal
strength (RSS), also known as RSS indicator (RSSI) is used to determine the dis-
tance between a source of the signal and its destination, employing a specific dis-
tance model, such as log-distance path loss model (PLM)5 , mean PLM6 , free space
PLM7 , etc. Once distance/angle has been established from destination to a number
of source points, triangulation or trilateration is used to pinpoint the exact loca-
tion. Both triangulation and trilateration are means to determine a position inside a
specified coordinate system using the help of anchor nodes whose position is known
(see Fig. 1).
Since GPS is undependable within interior spaces due to lack of visual contact
with the satellite, IPS are obliged to resort to other positioning techniques. These
can include technologies like Bluetooth or Bluetooth Low Energy (BLE), WiFi,
radio frequency identification (RFID), etc. Indoor spaces require finer precision and
granularity of positioning accuracy. Whilst an error in position estimation of 5–10m
might be tolerable in outdoor environments when positioning is performed indoors
the error in estimation is significant and unacceptable. GPS cannot be used indoors
is due to the operational characteristics of the system - signals from the satellite
are not designed to penetrate most construction materials, and as a rule, require
line-of-sight transmission between receivers and satellites. Although none of these
technologies (WiFi, BLE) presents itself as robust as GPS, services that leverage IPS
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
4 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
are hastily gaining traction in closed spaces like airports, shopping malls, hospitals,
and other venues where indoor navigation, route guidance or position-based services
can prove to be indispensable. Accurate real-time indoor location determination is
essential to enabling various context-aware services and protocols8,9,10 .
When considering IPS deployment option, IoT is a suitable approach. IoT is a
hot topic of technological, economic, social and industrial importance. Driven by
artificial intelligence, cognitive computing and new solutions for device-to-device
connectivity as well as rising technologies concerning big data and data analytics,
the adoption of the Internet of Things concept is accelerating rapidly. Ciscoa predicts
a 2.4-fold growth in machine-to-machine IoT communications, from 6.1 billion in
2017 to 14.6 billion devices by 2022. The prediction paints a picture of accelerating
technological and economic growth, as well as increasing influence on different scales
as an added value to industry and global economy.
As an extension of IoT, there is the concept of fog computing. Fog computing
is a decentralized architecture that brings computational resources and application
services closer to data sources. It creates an environment for a new type of applica-
tions and services that rest on responsiveness, privacy protection, location aware-
ness, with improved quality of service for direct streaming of data. A micro-location
asset tracking system for large indoor spaces requires the properties brought by fog
computing systems and IoT. Through massive technology improvements of wireless
indoor localization hardware and software, tracking of resources in confined spaces
has become a challenge that holds a promise of being answered to, and also with a
high- quality, low-cost solution.
The rest of the paper is structured as follows: in Section 2 challenges in location
determination are presented; section S concerns itself with contributions of this
paper, in Ssection 4 related work is presented; Section 5 presents a novel approach for
context building implemented in BLEMAT; in Section 6 BLEMAT’s approach to ML
is presented; Section 7 concerns itself with results of the implemented experiments;
and finally, in Section 8 the paper is concluded and future work is presented.
6 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
3. Related Work
In the positioning literature, machine learning algorithms have widespread usage in
estimating positions18 . To be able to guarantee high location estimation accuracy
and precision, most machine learning algorithms require a large number of carefully
labeled samples19,20 .
Through academic research, it has become evident that IPS cannot be precise
without contextual knowledge and aggressive filtering. Honggui Li14 presents a low-
cost 3D indoor positioning with Bluetooth smart device and least square methods
for linear and nonlinear parameters estimation. By fusing Bluetooth beacons and a
pedestrian dead reckoning (PDR) technique to provide meter-level positioning with
the help of Extended Kalman Filter (EKF) system, Xin Li, et.al.16 acquire 2-meter
precision. Qi Wang et.al.15 propose a Bluetooth positioning based on weighted K-
nearest neighbors and adaptive bandwidth man shift, which achieves high precision.
Cheng et.al.13 , utilize Kalman filtering, while Jianyong et.tl.21 propose Gaussian
filtering of RSSI and positioning optimization based on Taylor series expansion.
There are solutions proposing BLE and WiFi Combination22,23 with respect to
clear advantages of the approach. While following the trend of inducing machine
learning and consecutive filtering to different trilateration approaches, the above-
mentioned solutions are not space-agnostic – all reference nodes and the reference
space must be known at the time of deployment. Moreover, they mostly need a large
contextual dataset at the beginning, that is the WiFi or BLE spectral map of the
entire physical space.
A standard approach to building IPS is ML-based fingerprinting. Fingerprint-
ing requires a big pre-deployment effort to record a spectral map of the observed
space. This represents a major issue in the adoption and practical applications of
fingerprinting as a standard for location determination. When it comes to discussing
fingerprinting calibration and initial signal spectral map creation, there are a few
studies that aspired to diminish the human effort required for it. By analyzing and
studying crowdsourcing gathered unlabeled data to improve location estimation
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
4. Contributions Outline
BLEMAT is an upgrade to the results of two previous research papers 36,37 . It pro-
poses a novel approach to space-agnostic context building through a specific matrix,
grid and graph-based space modeling, online machine-learning based fingerprinting,
graph-based beacon paths persistence and exploration, and floor plan estimation.
On top of that, BLEMAT is a highly autonomous distributed fog computing system
offering auto-discovery and onboarding of new devices. Combining these features is
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
8 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
the key to developing a space-agnostic IPS and the research goal that this work
aspires to achieve. Furthermore, the contributions in this paper showcase:
(1) That the human work required to build the initial signal propagation map i.e.
fingerprinting map is vastly reduced with the proposed framework;
(2) That machine-learning algorithms for fingerprinting have a positive effect on
the final position estimation;
(3) That graph-based beacon path modeling, persistence, and analysis have a pos-
itive effect on the results of context building and space modeling, as well as
filtering of final position estimations.
Through this set of contributions, BLEMAT indirectly offers to speed up the
onboarding of new smart spaces systems, since it mitigates the need for digital
representation of a floor plan.
BLEMAT accounts for signal perturbation and distortion by employing a set
of filtering methods. It adapts to the changes in the system context by resting
on an infrastructure of gateways that communicate seamlessly and share contextual
information non-stop. BLEMAT utilizes ML for fingerprinting, where, in BLEMAT,
fingerprinting is an online-phase that requires minimal pre-deployment and data
acquisition efforts. It offers novel approaches to physical space modeling through
estimation of the floor plan layout. In conclusion, BLEMAT represents a significant
step in building context-aware, space-agnostic, distributed and autonomous IPS.
of the space (see Fig. 2). Matrix fields marked with Si represent the deployed
BLEMAT scanners in the matrix. In order to get insight into the physical context
the system operates in, BLEMAT first needs scanners to be deployed. It is important
to distinguish between every scanner, as each has its own characteristics - every Si
is characterized by its position in the observed space matrix, hardware, etc. So, at
first, the only two things that are known about the observed space are the maximum
width and length, and the position of deployed scanners. This is necessary to be
prepared as the first step in context-building.
S1 0 0 0 000 0 000 0 0
0 00 0 000 0 000 0 0
0 00 0 0 0 0 S3 0 0 0 0 0
M =
0 00 0 000 0 000 0 0
0 00 S2 0 0 0 0 0 0 0 0 0
0 00 0 0 0 0 0 0 0 0 S4 0
Fig. 3 shows how each element of the matrix maps to an element in the grid
representation of the physical space. Every element of the matrix represents a 1m2
area of the observed physical space – this means that element (0, 0) corresponds
to the area of the space that represents a square meter around that element. From
Fig. 2 it is clear that the position of scanner S1 is inside element M [0, 0], meaning
that, on the floor plan its position is inside a square defined with four edges: (0, 0),
(0, 1), (1, 0) and (1, 1) (also visualized in Fig. 3 ). The figure shows the fusion of the
10 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
purposes and showcasing the results of the floor plan layout detection algorithm
(Section 7).
In Def. 1 elements x and y represent the position of a given node regarding the
observed space (x and y position in a 2-D grid representation). V represents a vector
of objects where each object is described by two attributes: timestamp and duration
of stay. Timestamp represents the exact time when beacon visited the node, and
the duration represents the duration of stay at that visited node in seconds. For
Ein /Eout , n is the number of transitions that have been made towards/outwards
the respective graph node.
Once a beacon has been detected in the system the graph maintenance frame-
work commences and adds the first node to the digraph GB . This node contains
the captured x and y positions, as well as one element in the vector of all visits,
V . If the position of a beacon in the system is captured every two seconds, then
a node and an edge are both added or updated in the graph representation. As
explained in Section 5.1 every captured position can be tied to a specific element
of the space matrix, as well a m2 of the observed physical space. Adding a new
node and a new edge means that the beacon has moved to another field in the ma-
trix/grid representation. If the beacon has not moved to another field, the node’s
information is updated accordingly (duration of stay for the current visits vector
element is increased).
To keep the graph representation simple, diagonal transitions are not allowed,
but are rather modeled as regular, straight-line, transitions with a intermediary
node. The intermediary node will not be updated, only the final destination node.
This is to distinguish the actual visited nodes from the ones that have only been
used to model the transitions. An example for graph GB is given in Fig. 4. GB
nodes are marked with N .
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
The visual representation of the graph corresponds to the matrix and graph
representations, meaning that there are three overlapping representations for the
observed space and context, each of them providing unique insights into the oper-
ational context of the system, its elements, and the observed space. Once created
these graphs enable us to persist and explore beacon paths and extract patterns
from them, giving the possibility to detect anomalous behavior easily. Beacon paths
are persisted to a database for further processing and information retrieval.
(1) Defining a mapping between graph representations of beacons and matrix rep-
resentation of the observed space;
(2) Defining an algorithm to estimate floor plan layout from the collected data;
(3) Storing floor plan layout information and updating the matrix-grid space rep-
resentation.
A mapping has already been defined between matrix-grid and grid-graph rep-
resentations in Sections 5.1 and 5.2. Defining a mapping between graph represen-
tations of beacons and matrix representation of the observed space is the first step
in performing floor plan layout detection, and is necessary to complete the circle
between all representations. The mapping can be defined naturally since the matrix-
grid-graph representations of the observed space and its context overlap. The data
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
12 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
from the graphs complement the matrix representation, and the matrix representa-
tion is further used to perform calculations and information extraction that is part
of step (2). A visual representation of the mapping circle is displayed in Fig 5.
The context modeling starts with a matrix that holds only values of where
scanner devices are stored, (upper step (1) in Fig. 5), other fields have value 0. In
the second step (step (2) in Fig. 5) the matrix is mapped to the grid representation
of the observed space. The third step (step (3) in Fig. 5) consecutively collects
beacon data, which leads to constant updates of the previous matrix representation
for the given graph (bottom-left corner in Fig. 5). The mapping of node attributes
to matrix values is defined in Equation 1.
n
X n
X
M[i,j] = Vi · Vdi + (Ein + Eout ) (1)
i=1 i=1
in the related work section focus on offline fingerprinting. The approach presented
in our paper vastly diminishes human effort required to collect fingerprinting data
while automating data collection and ML model training at the same time. In this
section, an overview of the BLEMAT ML framework is given.
6.1. Background
There are four principles39 used in building positioning systems: trilateration, tri-
angulation, scene analysis, and proximity. Although systems relying only on the
combination of these principles and attributes are computationally efficient and
have proven to have a 2–4 meter accuracy40,41 , the authors themselves criticize
the approaches from the point of view of the system’s ability to handle contextual
information input like regard for obstacles, signal deviation, etc. Based on cur-
rent research done in indoor positioning based on Bluetooth, relying only on signal
parameters gives unsatisfactory results42,43 . Thus, a proactive approach must be
considered – an approach that would not only use signal parameters but also act
upon detecting patterns, deviations and correcting them.
There are three types of indoor positioning approaches based on used machine
learning techniques: supervised, semi-supervised and unsupervised. Supervised po-
sitioning relies on fingerprinting – two-phase process of matching elements from a
database to a particular signal strength fingerprint in real-time. The major flaw
with this approach is that it requires a comprehensive training phase – to create a
radio map with reference points within the area of interest which requires on-site
measurements and cumbersome manual actions12,13,44 . Semi-supervised positioning
has a short or no training phase, and needs to be space-agnostic. It relies on real-
time filtering of RSSI, distance and position estimation. Ideally, it has a minimal
set of pre-deployment requirements: dimensions of the indoor space and location of
a subset of scanners. Unsupervised approaches, like cluster analysis, can be used in
combination with the two above-mentioned approaches to improve the positioning
results. The aim of this section is to present an online, semi-supervised ML-based
fingerprinting framework.
14 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
measured and recorded with a timestamp. While raw data is being collected, it is
automatically being averaged over a period of one minute, and a spectral image for
every scanner is built. Raw data is displayed on the top side of the figure, while the
averaged, preprocessed data ready for machine learning input is displayed in the
bottom part in Fig. 6.
The upper side table in Fig 6 can be interpreted as: at 08:00:01 from Scanner
S1 to scanner S2 RSSI is −72 dBm, from scanner S1 to scanner S3 RSSI is −68
dBm, etc. The bottom side table then shows averaged value from one scanner to
all others, per minute. For example, the first row can be interpreted as: from 8:00
to 8:01, RSSI measurement from scanner S1 to scanner S2 was −82 dBm, from
scanner S1 to scanner S2 was −66 dBm, etc. Other rows show averaged values for
all scanners and all timestamps (4 scanners, 24 hours). The lower table in Fig.
6 represents the input training data format for the ML model, as rows represent
spectral images for a specific controller, at a specific time. Details about the training
of the model will be discussed later, in Section 7.
In order to understand how this is useful for the observed beacons in the IPS, it
is necessary to establish a clear correlation between a beacon’s RSSI and a scanner’s
RSSI. A scanner is a part of the system, but a beacon is an external device with its
own signal characteristics (signal stability, range, etc.). This correlation is presented
as a mapping function in the system. This mapping function is able to transform
any beacon to a scanner, thus giving the system the possibility to interpret external
beacons as integral part of the system (scanners). It is a novel approach designed
to automate fingerprinting, increase its efficiency, and reduce data acquisition time.
In fact, beacon’s RSSI has to be transformed into a scanners RSSI in order for the
system to observe it as a scanner. In order to be able to do that, beacon RSSI
data needs to be collected as well, prior to the creation of the mapping function.
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
External beacon’s RSSI data collection implies that the beacon is placed in the
indoor space, at the exact position of one of the scanners. After this condition is
met, the data acquisition process is initiated on all of the scanners, again, and the
data is collected in the same manner for scanners (see Fig. 6). For example, let there
be a measurement of RSSI between scanner S1 and scanner S2 of −76 dBm, and
scanner S4 and scanner S2 of −57 dBm. Let us replace scanner S2 with an external
beacon B. Now the RSSI is measured again, and the results are: between scanner
S1 and beacon B, −56 dBm, and between scanner S4 and beacon B, −67 dBm.
Intuitively, a mapping has been obtained. It can transform an external beacon B
into Si, by simply adding/subtracting a certain number. In the first case difference
is −20 dBm, and in the second −10 dBm. Now, we can effectively observe beacons as
internal system scanners, and that will help in the automation of the fingerprinting
process, and later, ML training.
There are three ways how this mapping could be implemented:
(1) Find a unique parameter λ that will transform beacon measurements into scan-
ner measurements as followed:
(2) For the observed data generate a set of mapping functions for every minute of
every hour throughout one day: f (0, 0) = y − λ, . . . , f (23, 59) = y − λ; where y
is a current beacon measurement and λ is derived from Algorithm 1;
(3) Same as (2) but with a thirty-second margin instead of one minute, for increased
accuracy and smaller granularity.
16 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
Finding a unique λ, as in (1), was not possible due to the nature of Bluetooth
signal (signal perturbation, losses, noise, etc.). Algorithm 1 showcases a solution to
(2) – the algorithm creates a set of mapping functions for each minute of the day,
per scanner. The algorithm is initiated for every type of beacon (hardware type)
introduced to the system. It will go through every minute of one day (24 hours)
and extract a mapping function for every scanner, to one beacon type. Thus, when
a beacon’s measurement is captured in the system from scanner Si , and there is a
mapping function for Si and the beacon, this beacon is transformed to a scanner
Sk . Approaches (2) and (3) are both equivalently valid, and the algorithm 1 could
be revised for (3).
From the values that are the output of this set of mapping functions, a machine
learning model to classify beacons to the closest scanner is built. Machine learning
for proximity detection is not only faster, but more accurate as well since the model’s
decision is resting on a continuous stream of data and is retrained periodically to
better adapt to the changing context. The model is updatable upon system request.
Classical fingerprint-based localization methods (Section 3) could be classified as
probabilistic and deterministic. Furthermore, they require additional building time,
and they cannot incorporate system context updates. Thus, the only way to generate
a new fingerprint spectral map is to go through the process of physically measuring
the whole indoor space again.
In our approach, based on a vector of RSSI values that represent a beacon
in the system, a decision is made on which scanner in the system can best be
represented by the same vector, thus classifying the beacon to the near proximity
of that specific scanner. Creating a new fingerprint map requires no downtime,
and can be completed while the system operates normally. This model impacts
the filtering of the position estimations by removing noisy and improbable values.
Selection of utilized machine learning algorithms, construction of machine learning
datasets, feasibility study of training data collection, and analyzing their impact on
the system’s performance, is going to be presented in Section 7.
layout building.
7.2.1. Algorithms
Regarding the selection of machine-learning algorithms, the following were con-
sidered: Naive Bayes classifier, K-nearest neighbors and Logistic Regression (LR).
Naive Bayes is a good candidate because it is easy to build and particularly useful
for very large data sets. Along with simplicity, Naive Bayes is known to outper-
form even highly sophisticated classification methods. KNN can be used for both
classification and regression problems, however, it is more commonly used in classi-
fication problems. KNN is easy to build and interpret, and its training time is small,
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
18 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
however, one does need to analyze the value of K carefully in order to obtain good
results. Logistic regression is a special case of linear regression when the outcome
variable is categorical, and the log of odds is used as dependent variable. Simpler,
it predicts the probability of occurrence of an event by fitting data to a logit func-
tion. Although it is considered to be used more for binary classification problems,
logistic regression can help answer different questions like: can the categories be
correctly predicted given a set of predictors and what is the relative importance of
each predictor. Also, for multi-class classification one-vs-all method is used in LR.
When the rest of the scanners were plotted, the same results regarding sig-
nal characteristics were noticed. Furthermore, when comparing signal behavior for
two consecutive days, the plotting results were nearly identical with insignificant
signal deviations. Once it has been established that there are grounds for trying
machine-learning classification a set of experiments with the three above-mentioned
algorithms was conducted.
7.2.3. Evaluation
Evaluation of three ML algorithms was carried out on training datasets with three
different sizes: one-hour dataset, five-hour dataset, and 24-hour dataset. From each
of these datasets, two distinct datasets were extracted: one where measurements are
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
averaged over one minute, and another where they are averaged over 30 seconds.
Test datasets were collected in the same manner: one-hour, five-hour, and 24-hour
BLE measurements were averaged over both 1-minute and 30-seconds resulting in
two distinct datasets for each of three datasets, from another workday. A dataset
larger than one day was not considered - the context of system operation in IoT
is ever-changing and a large dataset approximates the context worse than smaller
datasets.
The metrics that are of interest in the experiments are the number of mislabeled
points, accuracy and training time. Alongside, ML prediction capabilities when
taking certain combinations of predictors (scanners) into account rather than all
predictors is evaluated. Furthermore, efficiency between training ML models and
choosing the dataset size was investigated.
Model training times were first evaluated on a 16GB DDR4 2133MHz SDRAM
virtual machine with a SSD and an Intel Core i7 6700HQ processor. The program-
ming language used for data analysis was Python, and the library for ML used was
scikit-learnb . The results of the evaluation are presented in Table 1.
As can be seen, Logistic Regression gives the best classification accuracy, but the
highest training times for all datasets. It was trained with 100 iterations utilizing
the Newton-CG solver from scikit-learn. When increasing the number of iterations,
the same level of accuracy is achieved, but training times are larger. When bellow
70 iterations are performed, the model fails to converge. Naive Bayes classification
gives second-best classification accuracy in all of the cases, and it is the fastest model
to train. For KNN, best results are achieved when k = 1. For k = 2 and k = 3,
accuracy linearly decreases, however it does not go below 90% of classification
accuracy. For different k values, training times differ insignificantly, 5ms.
The trained ML models were further tested with the real-time position estima-
tion service (PES) running in BLEMAT. One beacon was observed, with known
real-positions, where the position of the beacon was changed three times in a one-
hour period. A position has been captured every 30 seconds, resulting in 120 position
estimations. Two experiments were run. In the first experiments the final position
estimation was the result of PES solely – relying on: (1) the averaging of signals,
(2) dBm to meter conversion, and (3) trilateration. In the second experiment the
20 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
position estimations were first filtered by the class output of the ML model, and
then steps (1), (2) and (3) were performed. In the first experiment, without relying
on the trained ML model, all 120 position estimations are taken into account as
potential positions. A total of 18% of these positions (22 position estimations) were
from 3-5 meters further from the actual noted position of the beacon at the given
time. However, when the trained ML model is used to first classify the spectral
representation of the beacon to a certain scanner’s area, 18% was reduced to 2%.
The ML model eliminated a significant majority of captured positions that were not
within 1m2 of the scanner that the spectral representation was assigned to. This is
a rather good result showcasing that the ML models trained for fingerprinting have
a serious impact on the quality of the PES.
7.2.4. Discussion
Given that observed training time intervals are short, and that a 24-hour dataset
includes many measurements points that are not needed for IPS (data at night),
it is more efficient to train and build ML classification models on smaller BLE
measurement datasets. While this hypothesis has been proven on one-hour and
five-hour datasets, a typical training dataset should include data during working
hours. If the system needs to operate non-stop, the experimental results indicate
that training a whole day‘s dataset requires insignificant time and outputs stable
predicting capabilities.
Experimental results showed that when ML models are trained with less than
three predictors/scanners (combinations of two), the average classification accuracy
decreases, as a rule. Training with all scanners gives more accurate and reliable
prediction results.
Since ML models are being trained on a remote VM there is an induced network
latency possibility. However, due to insignificant training times, the roundtrip from
sending data to the VM to receiving a trained model is just under three seconds.
Another possibility is to move the training of the models to the fog layer, to the
fog scanners. This will dismiss reduce the network latency, but then training times
on scanner machines is going to be slower. The issue becomes a trade-off between
latency and training time.
The human effort in building a spectral map in this framework is vastly dimin-
ished. When the system starts to operate, an instance of the proposed ML model can
be built within the first hour of operation and used to extrapolate for the upcoming
hours. This model might not be the most accurate but will have predictor capabil-
ities around 90%. However, it is evident that, as the data accumulates, the model
becomes more accurate in predicting classes. On the contrary, if the spectral map
had to be created by physically measuring signals at every m2 of the observed space
(80m2 ), at least 80 minutes would be required for the data acquisition phase, while
data transformation and ML training would be further delayed. Furthermore, once
trained in this manner, the model cannot incorporate context changes in the system,
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
thus increasing the probability that the physical fingerprinting will be repeated in
the future.
0 11 12 18 5 0 9 14 3 0 3 0 1
6 9 14 16 12 0 15 11 654 1312 1301 1244 1560
6 23 17 16 18 4 5 5 224 1223 1020 1311 1566
M =
3 2 16 21 18 22 16 21 268 1100 3121 1678 1098
17 35 15 11 41 43 39 34 45 990 1234 1345 1312
20 29 27 22 34 22 43 28 50 345 1117 1337 1087
On this matrix, the algorithm for floor plan layout detection is run. The algo-
rithm receives a matrix M as a parameter. M represents a matrix representation
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
22 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
of the observed space, as shown in Fig. 9. The algorithm then calculates the mean
of the data from M and outputs a heat map of the observed space, according to
M . Fig. 10 shows the heat map of the office layout where the median of empirical
results was used as the only threshold, thus all elements which are larger than the
median (median of M is 22) were saturated on the heat map. This incurs an in-
teresting approach where using only the median for categorization in algorithm for
floor plan layout detection could be employed. The presented heat map is a valid
representation of the actual physical office space configuration where all 1m2 areas
shown in white and light gray color are indeed detected as walls and occupied space
in the office. In addition to obtained empirical results, we have run 50 simulations
for the same area where the value for each element was randomized between 0 to
1000. Values of elements representing physical obstacles (walls) were randomized
between 0 and 10 representing low-frequency visits of beacons. For both empirical
and simulation results it was shown that the best strategy for identifying the rele-
vant threshold for floor plan layout detection was using the median of the observed
results.
Fig. 10. Physical office space heat map based on matrix M (corresponds to Fig. 8)
.
References
1. J. J. Gomez-Sanz, R. Pax, M. Arroyo and M. Cárdenas-Bonett, Requirement engi-
neering activities in smart environments for large facilities., Comput. Sci. Inf. Syst.
14(1) (2017) 239–255.
2. L. Wang, W. Wu, J. Qi and Z. Jia, Wireless sensor network coverage optimization
based on whale group algorithm., Computer Science & Information Systems 15(3)
(2018).
3. M. Lujak, H. Billhardt, J. Dunkel, A. Fernández, R. Hermoso and S. Ossowski, A
distributed architecture for real-time evacuation guidance in large smart buildings.,
Comput. Sci. Inf. Syst. 14(1) (2017) 257–282.
4. N. Swangmuang and P. Krishnamurthy, Location fingerprint analyses toward effi-
cient indoor positioning, in Pervasive Computing and Communications, 2008. PerCom
2008. Sixth Annual IEEE International Conference on (IEEE, 2008), pp. 100–109.
5. V. Erceg, L. J. Greenstein, S. Y. Tjandra, S. R. Parkoff, A. Gupta, B. Kulic, A. A.
Julius and R. Bianchi, An empirically based path loss model for wireless channels
in suburban environments, IEEE Journal on selected areas in communications 17(7)
(1999) 1205–1211.
6. V. Abhayawardhana, I. Wassell, D. Crosby, M. Sellars and M. Brown, Comparison of
empirical propagation path loss models for fixed wireless access systems, in Vehicular
Technology Conference, 2005. VTC 2005-Spring. 2005 IEEE 61st 1, (IEEE, 2005),
pp. 73–77.
7. A. Bose and C. H. Foh, A practical path loss model for indoor wifi positioning enhance-
ment, in Information, Communications & Signal Processing, 2007 6th International
Conference on (IEEE, 2007), pp. 1–5.
8. J. Hightower and G. Borriello, Location systems for ubiquitous computing, Computer
34(8) (2001) 57–66.
9. K. Muthukrishnan, M. Lijding and P. Havinga, Towards smart surroundings: Enabling
techniques and technologies for localization, in International Symposium on Location-
and Context-Awareness (Springer, 2005), pp. 350–362.
10. K. Pahlavan, X. Li and J.-P. Makela, Indoor geolocation science and technology, IEEE
Communications Magazine 40(2) (2002) 112–118.
11. R. Faragher and R. Harle, Location fingerprinting with bluetooth low energy beacons,
IEEE journal on Selected Areas in Communications 33(11) (2015) 2418–2428.
December 25, 2018 14:45 WSPC/INSTRUCTION FILE ws-ijait
24 Saša Pešić, Milenko Tošić, Ognjen Iković, Miloš Radovanović, Mirjana Ivanović, Dragan Bošković
fusion of pedometer and wifi measurements for mobile indoor positioning, in Pro-
ceedings of the 2014 ACM international joint conference on pervasive and ubiquitous
computing (ACM, 2014), pp. 147–158.
31. Y. Jiang, Y. Xiang, X. Pan, K. Li, Q. Lv, R. P. Dick, L. Shang and M. Hannigan,
Hallway based automatic indoor floorplan construction using room fingerprints, in
Proceedings of the 2013 ACM international joint conference on Pervasive and ubiqui-
tous computing (ACM, 2013), pp. 315–324.
32. C. Wu, Z. Yang, Y. Liu and W. Xi, Will: Wireless indoor localization without site
survey, IEEE Transactions on Parallel and Distributed Systems 24(4) (2013) 839–848.
33. H. Shin, Y. Chon and H. Cha, Unsupervised construction of an indoor floor plan
using a smartphone., IEEE Trans. Systems, Man, and Cybernetics, Part C 42(6)
(2012) 889–898.
34. H. Luo, F. Zhao, M. Jiang, H. Ma and Y. Zhang, Constructing an indoor floor plan
using crowdsourcing based on magnetic fingerprinting, Sensors 17(11) (2017) p. 2678.
35. R. Gao, M. Zhao, T. Ye, F. Ye, Y. Wang, K. Bian, T. Wang and X. Li, Jigsaw:
Indoor floor plan reconstruction via mobile crowdsensing, in Proceedings of the 20th
annual international conference on Mobile computing and networking (ACM, 2014),
pp. 249–260.
36. S. Pešić, M. Tošić, O. Iković, M. Ivanović, M. Radovanović and D. Bošković, Context
aware resource and service provisioning management in fog computing systems, in
International Symposium on Intelligent and Distributed Computing (Springer, 2017),
pp. 213–223.
37. S. Pešić, M. Tošić, O. Iković, M. Radovanović, M. Ivanović and D. Bošković, Bluetooth
low energy microlocation asset tracking (blemat) in a context-aware fog computing
system, in Proceedings of the 8th International Conference on Web Intelligence, Min-
ing and Semantics (ACM, 2018), p. 23.
38. N. Lanchier, Stochastic modeling (Springer, 2017).
39. K. Al Nuaimi and H. Kamel, A survey of indoor positioning systems and algorithms, in
Innovations in information technology (IIT), 2011 international conference on (IEEE,
2011), pp. 185–190.
40. S. Mazuelas, A. Bahillo, R. M. Lorenzo, P. Fernandez, F. A. Lago, E. Garcia, J. Blas
and E. J. Abril, Robust indoor positioning provided by real-time rssi values in unmod-
ified wlan networks, IEEE Journal of selected topics in signal processing 3(5) (2009)
821–831.
41. M. E. Rusli, M. Ali, N. Jamil and M. M. Din, An improved indoor positioning algo-
rithm based on rssi-trilateration technique for internet of things (iot), in Computer
and Communication Engineering (ICCCE), 2016 International Conference on (IEEE,
2016), pp. 72–77.
42. W.-H. Kuo, Y.-S. Chen, G.-T. Jen and T.-W. Lu, An intelligent positioning approach:
Rssi-based indoor and outdoor localization scheme in zigbee networks, in Machine
Learning and Cybernetics (ICMLC), 2010 International Conference on 6, (IEEE,
2010), pp. 2754–2759.
43. G. Zanca, F. Zorzi, A. Zanella and M. Zorzi, Experimental comparison of rssi-based
localization algorithms for indoor wireless sensor networks, in Proceedings of the work-
shop on Real-world wireless sensor networks (ACM, 2008), pp. 1–5.
44. H. Liu, H. Darabi, P. Banerjee and J. Liu, Survey of wireless indoor positioning tech-
niques and systems, IEEE Transactions on Systems, Man, and Cybernetics, Part C
(Applications and Reviews) 37(6) (2007) 1067–1080.