Adaptive Mini-Batch Gradient-Ascent-Based Localization For Indoor IoT Networks Under Rayleigh Fading Conditions

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 13

IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO.

13, JULY 1, 2021 10665

Adaptive Mini-Batch Gradient-Ascent-Based


Localization for Indoor IoT Networks Under
Rayleigh Fading Conditions
Ankur Pandey , Graduate Student Member, IEEE, Piyush Tiwary ,
Sudhir Kumar , Senior Member, IEEE, and Sajal K. Das , Fellow, IEEE

Abstract—Location estimation in an indoor Internet-of-Things


(IoT) environment is a challenging task due to multipath sig-
nals and obstacles that cause shadowing and fading effects, and
change the received signal power considerably. Most of the exist-
ing path-loss-based localization methods assume only a lognormal
shadowing model and ignore small scale fading effects. This
article considers a generic combined lognormal shadowing and
Rayleigh fading model for efficient localization of smart devices
in an indoor IoT environment. In particular, the maximum likeli-
hood estimate of the location and path-loss exponent (PLE), and
Cramer–Rao lower bound (CRLB) are derived. The localization
parameters are estimated using a novel adaptive mini-batch gra-
dient ascent method that maximizes the log-likelihood function
with an appropriate batch size based on the convergence fac-
Fig. 1. Effect of fading on localization in an indoor IoT environment. (LOS
tor. Hence, the proposed method addresses the challenge of an = Line of Sight; NLOS = Non-LOS).
arbitrary selection of a fixed batch size for a gradient ascent
method by utilizing this convergence factor. Performance evalua-
tion by a simulation study and real experiments from an indoor
IoT testbed provide a more accurate joint estimation of model location estimation methods are widely used owing to the
parameters and smart device localization. ubiquitous nature of opportunistic signals, such as wireless
fidelity (Wi-Fi), Bluetooth, light, acoustic and geomagnetic
Index Terms—Internet of Things (IoT), mini-batch gradient
ascent, Rayleigh fading, smart device localization. signals [1]. The RSS-based methods are low cost as they do not
require any additional hardware, and utilize the received power
at the smart devices for positioning with the help of a path-
loss model. However, a major challenge with this method is the
I. I NTRODUCTION appropriate choice of path-loss model given the dynamic envi-
OCALIZATION of smart devices in an Internet-of- ronment and shadowing effects [2]. This is because the RSS
L Things (IoT) environment is crucial for many applica-
tions, such as indoor activity recognition, health care, and
values fluctuate considerably due to fading effects, thereby
reducing the smart device localization accuracy [3].
smart agriculture. While global positioning system (GPS) is
a viable solution for outdoor localization, it either does not A. Motivation and Contributions
work in an indoor environment, or nonline-of-sight (NLOS) Wireless signals are affected by obstacles and undergo
multipath signals due to reflections from walls and furniture reflection and diffraction phenomena. Therefore, the signals
severely degrade the localization accuracy. Therefore, in an arrive at smart devices through multipath, which affects the
indoor IoT setting, the received signal strength (RSS)-based RSS values. Fig. 1 illustrates an indoor IoT environment
where the wireless signals arrive at the smart devices through
Manuscript received November 10, 2020; accepted December 23, 2020.
Date of publication December 29, 2020; date of current version June 23, 2021. multipath because of reflections from obstacles. Therefore, the
The work of Sudhir Kumar was supported in part by the project RSS-based localization methods lead to erroneous location
NRDMS/UG/S.Kumar/IIT Patna/e-04/2019 of the Department of Science and estimates if neither multipath fading effect nor the variation of
Technology, India. The work of Sajal K. Das was supported in part by
the NSF grants CNS-2008878 and SaTC-2030624. (Corresponding author: RSS values due to multipath signals is considered. When both
Ankur Pandey.) shadowing and small scale fading are considered, the maxi-
Ankur Pandey, Piyush Tiwary, and Sudhir Kumar are with the mum likelihood estimate of the location of the smart device is
Department of Electrical Engineering, Indian Institute of Technology Patna,
Patna 801106, India (e-mail: 1821ee12@iitp.ac.in; piyush.ee17@iitp.ac.in; nonlinear in nature making it difficult to obtain a closed-form
sudhir@iitp.ac.in). expression. Therefore, to maximize the log likelihood function,
Sajal K. Das is with the Department of Computer Science, Missouri different localization techniques are proposed as discussed in
University of Science and Technology, Rolla, MO 65409 USA (e-mail:
sdas@mst.edu). Table I. In the proposed work, we use an adaptive gradient
Digital Object Identifier 10.1109/JIOT.2020.3047982 ascent method for maximizing the log likelihood function. The
2327-4662 
c 2020 IEEE. Personal use is permitted, but republication/redistribution requires IEEE permission.
See https://www.ieee.org/publications/rights/index.html for more information.

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10666 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

TABLE I
C OMPARISON OF E XISTING RSS-BASED PLE AND S MART D EVICE 3) We derive the Cramer–Rao lower bound (CRLB) for a
L OCATION E STIMATION M ETHODS Rayleigh faded IoT environment.
4) We evaluate the performance of our proposed solution
via a simulation study and real-world experiments in an
indoor IoT testbed.
The remainder of this article is organized as follows.
Section II reviews the existing localization methods and their
limitations. Section III presents the derivation of the maxi-
mum likelihood estimate under Rayleigh fading. Section IV
describes the proposed adaptive mini-batch gradient ascent
method. Sections V and VI evaluate the performance of
the proposed method via a simulation study and real-world
experiments in an indoor IoT testbed, respectively. Finally,
gradient ascent method or its variants, such as single sample, conclusions are drawn in Section VII.
mini-batch, and full batch require manual calibration of both
the learning rate and batch size. Smaller batch sizes (single
sample methods) converge in fewer epochs while larger batch II. R ELATED W ORK
sizes (full batch methods) require a large number of epochs In this section, we review the existing range-based local-
to converge, which increases the computational complexity ization methods utilizing the path-loss model for PLE and
of the method. Moreover, the single sample method provides location estimation and contrast with our proposed method.
marginally lesser accuracy than the full batch due to the
noisy gradient. Such tradeoff between the accuracy and con-
vergence for gradient ascent methods, based on the batch size, A. Localization Methods Based on Signal Measurements
necessitates an estimation method that chooses the appropriate Signal measurements, such as Time of Arrival (ToA) [4],
batch size between the single sample and full batch meth- time difference of arrival (TDOA) [13], Angle of Arrival
ods. Given that selecting a particular batch size manually or (AoA) [14], channel state information (CSI)-based [15], and
through the line search is computationally expensive, an adap- RSS features [16] are extensively used for localization. The
tive method is required during the training process [11], [12]. RSS-based smart device localization methods are widely uti-
This motivates our work. lized as the wireless signals are ubiquitous with proliferation of
We consider the fading effects and propose an adaptive smart devices and APs, which makes the methods low-cost [1].
mini-batch gradient ascent method for smart device location Since our proposed localization method is also RSS-based,
estimation. The proposed method utilizes the advantage of Table I compares only the RSS-based methods (except the
both single sample and full batch methods by taking into Relative Location method, which also uses ToA measurement)
account the convergence factor, μ, and its impact on the for PLE and location estimation.
localization accuracy. The range-based techniques utilize the RSS values to esti-
The algorithm starts with an initial batch size of unity, mate the distance between a smart device and APs. This
and as the estimate is far from maximum, it approaches estimated distance is used to compute the location of the
the maximum faster with a single batch. Once the log- smart device using a multilateration method. The maxi-
likelihood function is near the maximum, the method achieves mum likelihood method is used in [4] to estimate the smart
a sharper maximum by increasing the batch size. However, if device location for a lognormal shadowing environment. Semi
the value of the log-likelihood function overshoots the maxi- definite programming (SDP)-based methods are proposed
mum because of the large step size (that is, μ < 1), then the in [7], [17], [18] that address the nonconvex nature of the
batch size is decreased accordingly, in order to allow the log- Maximum likelihood function, considering lognormal shad-
likelihood function attain the sharper maximum back. In this owing. Methods, such as [5], [6], [8], and [19] estimate the
way, the proposed method achieves both faster convergence PLE and smart device locations using weighted least square,
and higher localization accuracy, with the appropriate batch centroid, Bayesian, and joint estimation methods. In [20],
size. experiments are conducted at different sites, and it is observed
The major contributions of this article are summarized as that for fixed transmitter locations, lognormal distribution
follows. shadowing alone is not sufficient to model the RSS values,
1) We provide a joint estimation of the path-loss exponent and the authors used a compound Gamma-lognormal distri-
(PLE) and smart device location in an indoor IoT envi- bution for modeling the fading characteristics for an indoor
ronment considering a combined lognormal model for environment. Shen et al. [10] utilized Rayleigh fading with
shadowing, and Rayleigh fading. the log distance path-loss model to estimate the location of
2) We propose a novel adaptive mini-batch gradient ascent- APs using particle filtering and pedestrian dead reckoning
based localization that addresses the nonlinearity of (PDR) methods. The localization performance improves with
the derived maximum likelihood function and arbi- the fusion of PDR. However, particle filtering approach is in
trary selection of fixed mini-batch size considering the general nondeterministic in nature, and with an increase in the
tradeoff between convergence and localization accuracy. dimensionality of the state space, a large number of particles

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10667

Fig. 2. Overview of the proposed localization method in an indoor fading IoT environment.

are required. The method suffers from sample impoverishment devices. Let N denote the number of APs with known coor-
and high complexity as the particle area increases [21]. dinates ψi = [pi , qi ]T where ψi ∈ R2 , and i = 1, 2, . . . , N.
The coordinates of unknown smart devices are denoted as
B. Shortcomings of the Existing Methods
θ = [x, y]T where θ ∈ R2 . The received power Pri due to
The range-based localization methods [4], [7], [18] do the ith AP for a shadowing PLE is given as [25]
not consider the fading effect in the location estimation.
Localization methods, such as [2], [22], and [23] do consider θ − ψi 
Pri = P0 − 10η log10 +χ (1)
the effect of fading for location estimation, assuming that the d0
PLE is known apriori in a new environment. Hence, these
where P0 is the reference received power at distance d0 = 1
methods do not estimate the PLE on the fly. Reference [22]
m (θ − ψi  ≥ d0 ); η denotes the PLE that depends on
utilizes a computationally expensive trilateration method for
the environment; and χ denotes lognormal shadowing effect
which three APs are required. Dogandzic and Amran [2]
distributed as zero-mean Gaussian variable with variance σg2 .
incorporated the expectation–maximization (EM) algorithm
for localization. However, for the M step, the method utilizes
the Newton–Raphson iteration method, which is computa- A. Location Estimation Under Rayleigh Fading
tionally expensive. Moreover, this method does not present As discussed, two significant phenomena that degrade the
results for a real-time fading environment. Similarly, [23] eval- strength of wireless signals are fading and shadowing or, at
uates the CRLB for ToA measurements in different fading times, their coexistence. In an indoor IoT environment, signals
environments but provides only numerical simulations to ver- are received at smart devices through reflection, scattering, and
ify the expressions. The least-square-based methods [6], [24] diffraction due to building walls, furniture, or any other obsta-
attempt to address the nonlinear nature of maximum likeli- cles. Therefore, signals arrive at the devices through multiple
hood function, but is prone to shadowing effects. Adhikary paths. As the amplitude and phase of the signal through this
and Daigle [9] presented localization results in a Rayleigh multipath are random, this makes the superimposed RSS also
fading environment and compared the performance of three random in nature. Such randomness or fluctuations exist for
standard localization methods. However, the performance was a short duration of time over small distances, referred to as
not evaluated in a real IoT system, and the complexity is also small scale fading [26]. The multipath effects over relatively
high. The SDP-based methods [7], [17]–[19] are computation- larger distances from a large number of scatterers give rise to
ally expensive and require tight relaxations to guarantee the the shadowing phenomenon. This is also known as long-term
convergence of maximum likelihood function. It is assumed fading effect, the distribution of which is lognormal [26], [27].
in [7] that the multipath fading effects can be mitigated by In this work, we consider a lognormal-Rayleigh shadowed
averaging the RSS values in the time and frequency domains. fading wireless channel for smart device localization. Fig. 2
Hence, the method involves a preprocessing step that further depicts an overview of the proposed method. The RSS values
increases the complexity. are collected from the smart devices and input to the adaptive
Therefore, in this article, we propose a location estima- mini-batch gradient ascent method. We consider three scenar-
tion method that considers Rayleigh fading in the indoor IoT ios for parameter estimation: 1) Scenario 1 assumes that the
environment, adaptively selects the batch size for the gra- PLE is known and estimates the location; 2) Scenario 2 esti-
dient ascent method, and guarantees the convergence as the mates the PLE using a few known smart device locations, and
maximum likelihood estimate is strongly concave. then estimate the locations of all other smart devices; and 3)
Scenario 3 jointly estimates the PLE and smart device location.
III. M AXIMUM L IKELIHOOD E STIMATION The RSS samples are fed to the adaptive mini-batch gradi-
U NDER R AYLEIGH FADING ent ascent method, continuing the iteration until convergence.
In this section, we consider a lognormal shadowing model Finally, the parameters are estimated. The proposed method is
and Rayleigh fading for location estimation of unknown smart detailed in the rest of this section and the next section.

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10668 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

  N η 
N
B. Maximum Likelihood Parameters Estimation of Location i=1 θ − ψi 
 Pr
The location estimate in the presence of both lognormal = exp i

(4.34P0 )N i=1
4.34
shadowing and Rayleigh fading can be described as follows.  N

Proposition 1: The unknown location estimate z ∈ {x, y}  (θ − ψi )η
× exp −β . (9)
for a single sample due to N number of APs is given as P0
i=1
N   
 1 β  η −1  The log-likelihood function is given as
ẑs+1 = zˆs + ρ η(zˆs − ψi ) − α2 (2)
α P0 ln L(Pr ) = η ln Ni=1 θ − ψi  + κi
i=1
N

where zˆs and ẑs+1 are the current and next location estimates; (θ − ψi )η
− β − N
α = (x − pi )2 + (y − qi )2 and β = exp(Pri /4.34); ρ is the P0
i=1
learning rate; η is the PLE; ψi = [pi , qi ]T is the known location N 

of APs; and Pri is the received power due to the ith AP.  (θ − ψi )η
= η lnθ − ψi  − − β + κi
Proof: The received signal amplitude r(t) at time t with P0
i=1
carrier frequency f0 in a multipath fading environment, assum- (10)
ing all the phases λi are uniformly distributed in the range N
[0, 2π ] with amplitude ai , is given as [26] where κi = i=1 (Pri /4.34) and  = ln(4.34P0 ). Therefore,
the maximum-likelihood estimator for θ is given as
r(t) = X cos(2π f0 t) − Y sin(2π f0 t) (3) N 

N N  (θ − ψi )η
where X = i=1 ai cos(λi ), Y = i=1 ai sin(λi ), and X and θ̂ = arg max η lnθ − ψi − β . (11)
θ P0
Y follow Gaussian distribution for large N, due to central limit i=1
theorem.
√ Therefore, the envelope of the received signal E = We express the maximum likelihood function in terms of
X 2 + Y 2 will be Rayleigh distributed [28] having probability unknown location coordinates (x, y) as follows:

η  
density function (pdf)  N

θ̂ = arg max ln (x − pi )2 + (y − qi )2
b b2 θ 2
f (b) = 2 exp − 2 , b ≥ 0 (4)  i=1
σr 2σr η 
((x − pi )2 + (y − qi )2 ) 2
where σr represents the shape parameter of the distribution. − β . (12)
P0
The power distribution for Rayleigh fading f (φ) is obtained
using the variable transformation method as φ = b2 Let us now use the gradient ascent method [29] to estimate
√ the unknown location z ∈ {x, y}. The gradient ascent estimate
φ 1 1 −φ/2σr2 using (12) with an initial estimate zˆs ∈ {xˆs , yˆs } and next esti-
f (φ) = 2 e−φ/2σr × √ =
2
e (5)
σr 2 φ 2σr2 mate ẑs+1 for a single sample due to N APs for sth iteration
The expression in (5) represents an exponential distribution. is given in (2).
Given that the mean of the standard exponential distribution In an indoor IoT scenario, a smart device receives signals
f (x; λ) = λe−λx is (1/λ), (5) yields λ = (1/2σr2 ). Hence, the from multiple APs. Therefore, we need to consider multiple
expected value E(φ) is derived as RSS samples from all the APs for location estimation. A sin-

gle RSS sample from all the APs for parameter estimation
θ − ψi  −η leads to frequent parameter updates and a noisy gradient [30].
E(φ) = 2σr = P0
2
. (6)
d0 However, considering a full batch of samples from the N APs
Equation (6) is obtained using the mean value of the received increases the convergence time because one update requires
power from (1). Now, using (5) and (6), the pdf of the received the full batch of data. Therefore, we propose to use an adaptive
power f (ζ ) in linear scale can be written as mini-batch gradient ascent method that utilizes multiple sam-

ples from the N APs and converges faster than the full batch
di η di η
f (ζ ) = exp −ζ (7) gradient ascent method. However, if no small scale fading is
P0 P0 considered, we use the expression given in [4] and [31] to
where ([θ − ψi /d0 ]) = di . To obtain the pdf in dB scale we compute the location of the unknown smart devices.
perform another transformation Pr = 10 log10 ζ = 4.34 ln(ζ ).
Therefore, using the transformation for a logarithm variable, IV. A DAPTIVE M INI -BATCH G RADIENT A SCENT
the pdf of the received power Pri in dB is given as L OCALIZATION


di η di η The gradient ascent method following (2) is for a single
f (Pri ) = β exp −β . (8) RSS sample. Consider N APs that provide m samples at each
4.34P0 P0
smart device. The RSS matrix is represented as
Now, for d0 = 1, the likelihood function of the received ⎡ ⎤
P11 P12 . . . P1N
power from N number of APs is given by ⎢ P21
⎢ P22 . . . P2N ⎥ ⎥

P=⎢ . .. .. .. ⎥ . (13)
θ − ψi η
N
(θ − ψi )η ⎣ .. . . . ⎦
L(Pr ) = β exp −β
4.34P0
i=1
P0 Pm1 Pm2 . . . PmN m×N

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10669

The mth input sample to the batch algorithm is given by initialize the batch size B = 1 for faster initial convergence.
Sm = [Pm1 , Pm2 , . . . , PmN ]. Consider a mini-batch of size B As the gradient ascent proceeds, the batch size increases (as
samples where 1 ≤ B ≤ m. Therefore, the RSS matrix is μ > 1), thereby leading to a slower convergence rate but
PB = [S1 , S2 , . . . , SB ]T , and the total number of mini-batches higher accuracy. The advantage is that at the same time, the
is m
B . The location estimate of the smart device for sth iteration log-likelihood function is already near to its maximum because
using mini-batch gradient ascent for B samples is given as of its initialization with the batch size equal to 1, and fur-
ther requires fewer batch sizes to reach a sharper maximum.
ẑs+1 = zˆs + ρδz (14) Hence, the proposed method converges faster with comparable
where the average gradient δz for batch size of B samples is accuracy as compared to the fixed or full batch method.
Similarly, for the case where the maximum is missed due
1
B
to the higher learning rate, the convergence factor becomes
δz = δSm×B (15)
B less than 1 (that is, μ < 1). Therefore, the batch size is
m=1
decreased so that the log-likelihood function again attains the
and for the mth minibatch, the gradient δSm×B is given as missed maximum at a faster convergence rate. As the log-

N likelihood function reaches near its maximum, the proposed
 
δSm×B = η zˆs − ψi (D − C) (16) method achieves a sharper maximum compromising the con-
i=1 vergence rate by increasing the batch size. However, when the
where log-likelihood function is far from its maximum, the proposed
method gives priority to faster convergence rather than the
β η
D = (α)−1 , C= (α) 2 −1 (17) sharper maximum and accordingly utilizes fewer mini-batches.
P0 Therefore, the significant advantage of our method is fast
as discussed in (2). processing of large RSS samples from N APs with faster
Equation (14) helps devise the fixed mini-batch algorithm convergence and a smooth gradient. The proposed method
and requires to choose a mini-batch size B manually to com- converges for a particular batch size when μ = 1. For conver-
pute the gradient update. As there is a tradeoff between the gence, we set the threshold value of μ − 1 ≤  between the
mini-batch size and accuracy [32], [33], the choice of B is output of the current and next iterations (here,  = 10−5 ).
important. To address this issue, in the proposed method, we Initialization of the Location Estimates: It is important to
define a convergence factor (μ) as the ratio of the value of choose an initial estimate of the location that is closer to the
log-likelihood function for the initial and final values of a actual estimate so that the likelihood function can be maxi-
particular epoch. Thus mized and converges at a faster rate. In particular, for a large
max(|ln L(Pr )final |, |ln L(Pr )initial |) IoT network with large number of smart devices, this achieves
μ= . (18) faster convergence as compared to the random initialization. It
min(|ln L(Pr )final |, |ln L(Pr )initial |)
is also possible that a poor choice of initial estimate does not
We initialize with B = 1 and update the batch size as lead to convergence, and hence incorrect location estimates.
Bi+1 = Bi × μ (19) Therefore, in this work, we initialize the gradient ascent with
a weighted centroid localization (WCL) method [34], where
until μ = 1. The estimated location of each batch acts as the initial estimate zs is given as
an initial location estimate for the next batch, which helps

N
Pr
in faster convergence as well as better accuracy. The sin- zs =
 z i × N i . (20)
gle sample method provides the fastest convergence but with i=1 i=1 Pri
marginally higher localization error, as only a single sample
leads to a noisy gradient and can easily deviate from the batch Hence, this initial estimate is used in (14) for better location
gradient direction [30]. On the other hand, in the fixed batch estimate and faster convergence.
method, all the sample points are input at once, and the param-
eters are updated after processing the complete fixed batch of A. Joint Parameter Estimation for Smart Device Localization
B samples. Therefore, the convergence of the batch method In an unknown IoT environment, it is required to estimate
is slow, but the accuracy is better than the single sample the PLE and location of the smart device. In the Scenario 1,
method. It is also observed that large mini-batches are compu- we assume that the environmental parameters are known.
tationally expensive, while the small batch sizes utilize fewer Therefore, we use the known shape parameter σr , and PLE
memory [12]. Therefore, there is a tradeoff between conver- (η) to find the location of smart devices. In Scenario 2, we
gence time and accuracy for the single sample and full batch first estimate the PLE using the knowledge of a few smart
methods. device locations beforehand. After η is estimated, (14) and (19)
In our proposed method, we utilize the advantages of both are used to estimate the unknown smart device location using
the above methods by introducing the convergence factor μ, the adaptive mini-batch gradient ascent method. Finally, in
which controls the batch size depending on the current state Scenario 3, we jointly estimate all the unknown parameters,
of convergence. As the gradient ascent method maximizes the namely, η, σr , and θ for an unknown IoT environment. The
log-likelihood function, after each epoch, the value of the log- joint estimation is advantageous as the parameters are learned
likelihood function should increase, thus implying μ > 1. We on the fly for an unknown IoT environment, thereby making

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10670 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

the method adaptive to the new IoT environment. The local- Algorithm 1 Algorithm for Smart Device Location Estimation
ization error and estimation performance are evaluated for all in a Rayleigh Faded IoT Environment
the three scenarios. Input: RSS values at the unknown smart devices location θ
1) Location Estimation With Known PLE: In this case, from APs with known locations ψi
the unknown smart device locations are estimated using (14) Output: Shape parameter (σr ), PLE (η), and smart device
and (19) where the PLE is known. We evaluate the location θ
performance of the proposed method for different IoT envi- begin
ronments with varying PLE. Estimate the initial location of the smart device using (20)
2) Location Estimation With Unknown PLE: In this case, if Single Sample Gradient Ascent then
using known locations of a few smart devices, the PLE is first use (2) to estimate θ for Scenario 1
estimated according to: else if Scenario 2 and Scenario 3 then
for iteration = 1 to max.iterations do
∂L(Pr ) Compute θ , η, and σr and using (2), (22), and (23),
ηs+1 = ηs + ρ (21) respectively,
∂η
Convergence: if ||ẑi+1 − zˆi || ≤ Threshold then
where the gradient of the likelihood with respect to PLE is Break
given as
end


∂L(Pr )  ln α
N
β η −1
= 1− α2 (22) if Adaptive Mini-Batch Gradient Ascent then
∂η 2 P0
i=1 Intialize B = 1
for batchsize = 1 to m do
After the estimation of PLE, the unknown location of the Update B → B × μ, Until μ = 1
smart device is determined using the adaptive gradient ascent end
method from (14) and (19). The estimation of PLE and for iteration = 1 to max.iterations do
unknown locations using this method requires the knowledge Compute θ, η, and σr using Equation (14), Equation
of the locations of a few smart devices. To this end, we propose (22), and Equation (23) respectively for Scenario 1,
the adaptive joint estimation method below. Scenario 2 and Scenario 3 such that
3) Joint Estimation of the Shape Parameter, PLE, and Convergence: if ||ẑi+1 − zˆi || ≤ Threshold then
Location: For an IoT environment with all unknown smart Break
device locations and PLE, the last scenario is not useful.
Therefore, we utilize (14), (19), (21), and (23) for joint estima- end
tion of all the parameters using multivariable gradient ascent return Online learned parameters σr , η, and θ
method. For better estimate, we initialize η in the range of end
2 to 6 as discussed in [25]. As the dimensions of the indoor
area is available, the location estimates are initialized in the
range of the nearest to farthest locations. The gradient ascent
equations for the parameter σr is given as C. Computational Complexity of Proposed Localization
We present the computational complexity of the single
∂L(Pr )
σrs+1 = σrs + ρ (23) sample, mini-batch, and batch gradient ascent methods in
∂σr terms of floating-point operations (flops). We assume that the
where mathematical operations, such as addition, subtraction, multi-
plication and exponent take one flop count each. Therefore, we


∂L(Pr )  1 β
N
first count the number of flops for the gradient term of (2). The
= − 2 . (24) C term [see (17)] requires a total of 10 flops, and the D term
∂σr σr σr2
i=1
[see (17)] takes a total of 6 flops. Therefore, the total gradient
This method is advantageous because for an unknown envi- term for N APs requires 20N flops. Now the complete term
ronment, we can estimate all the parameters required for on the right-hand side of (2) requires a total of 20N + 2 flops
localization. Also, for a new IoT environment, the parame- for a single iteration. Furthermore, for mini-batch, the total
ters can be relearned and locations can be estimated thereby number of flops required is (20N + 2)B for a single iteration.
making the method adaptive in nature. Finally, for batch gradient ascent we need (20N + 2)m flops
in one iteration, where m is the size of a full batch. If we
compare the full batch and mini-batch methods with an exam-
B. Localization Under Rayleigh Fading ple of k = 103 samples, mini-batch size of 20 and N = 20
Algorithm 1 explains the steps involved in localizing smart APs, it is observed that a mini-batch requires 8040 flops and
devices for all three scenarios using the adaptive mini-batch a full batch requires 4.02 × 105 flops for one iteration. Hence,
gradient ascent method. First, a suitable scenario is identified there is a reduction of 98% flops with mini-batch gradient
depending upon prior information. The parameters are esti- ascent method. If the mini-batch size is searched manually, the
mated using respective equations for the identified scenario. timing complexity further increases. Therefore, the proposed

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10671

TABLE II
method adaptively chooses the suitable batch size based on S IMULATION PARAMETERS FOR S MART D EVICE L OCALIZATION
the convergence factor, μ.

D. CRLB for Unknown Smart Device Location


The CRLB computes the lower bound on the variance
of any unbiased estimator, and can be used to evaluate the
performance of the proposed method. Recalling that ψi =
[pi , qi ]T , where ψi ∈ R2 and i = 1, 2, . . . , N are known loca-
tions of N APs, the CRLB for unknown smart device location
parameter θ = [x, y]T is derived as follows. and the second derivative is given as
Proposition 2: The CRLB for location estimate in a

∂ 2 ln L(Pr ) 
N
Rayleigh fading environment is given as 1 2(y − qi )2 β
= η − −
    ∂y2 α α2 P0
i=1
CRLB(θ )  I−1 (θ ) 1,1 + I−1 (θ ) 2,2 (25)
[α η/2−1 + (η − 2)(y − qi )2 α η/2−2 ]. (32)
where I−1 (θ) is the inverse of I(θ ), the Fisher information
Finally
matrix (FIM), whose elements are given as


∂ 2 ln L(Pri ) 
N
N

2(y − qi )
2(x − pi )2 (η − 2)(x − pi )2 = η(x − pi )
E(Fxx ) = i 1 − − γ 1 + ∂x∂y α2
θ − ψi 2 (θ − ψi )2 i=1
i=1
β  η

N

− β 2 −2 (η − 2)(y − qi ) (33)
2(y − qi )2 (η − 2)(y − qi )2 P0
E(Fyy ) = i 1 − − γ 1 +
θ − ψi 2 (θ − ψi )2
i=1 which is simplified to
N
 
2 (η − 2)γ ∂ 2 ln L(Pri ) 
N
β
E(Fxy ) = η(x − pi )(y − qi ) − =
2
η(x − pi )(y − qi ) 2 −
η
(η − 2)α 2 −2 .
θ − ψi )4 (θ − ψi )4 ∂x∂y α P0
i=1
i=1
(26) (34)
where i = (η/θ − ψi 2 ), γ = exp{(4.342 σg2 /2)} and E(.) Now, from (1), χ = Pri −P0 −10η log10 θ − ψi  which fol-
denotes the expectation operator. lows Gaussian distribution. Therefore, the moment generating
Proof: From the definition of CRLB [35]
function of Gaussian pdf is given as E(etx ) = eμt+(σg t /2) .
2 2
  !
vr θ̂j ≥ I−1 (θ) (27) Hence, the expression for our model is E[eχ /4.34 ] =
jj exp{(4.342 σg2 /2)} = γ (say). Using the identity, we compute
where vr (.) denotes the variance operator and I(θ ) is the FIM the Expectation of the above derivatives and the FIM elements
given as are obtained as in (26). Finally, the CRLB is derived with the
⎡ ! !⎤ help of (25).
∂ 2 ln p(.)
E ∂ ∂x∂y
2 ln p(.)
E We compare the performance of the proposed method
⎢ ∂x2
 ⎥
I(θ) = −⎣ ∂ 2 ln p(.) ! ∂ 2 ln p(.) ⎦ by comparing the obtained root mean square error
E ∂x∂y E ∂σ 2
y (RMSE) with the CRLB obtained in (25). The localiza-
   tion results obtained using the adaptive mini-batch method
E(F )
 xx  E F
 xy  (say).
= (28) for all the three scenarios are discussed in the next
E Fxy E Fyy
section.
The first-order and second-order derivatives of the log-
likelihood function with respect to the location coordinates V. P ERFORMANCE E VALUATION BY S IMULATION S TUDY
are, respectively, given as
In this section, we simulate a real-time indoor IoT envi-
∂ ln L(Pr )  (x − pi ) ηβ  
N
η ronment with Rayleigh fading and lognormal shadowing to
= η − (x − pi )α 2 −1 . (29) evaluate the performance of the proposed method for the
∂x α P0
i=1
three scenarios, as discussed in Section IV-A. The localization
Therefore, the second derivative is given as results for the combined lognormal and Rayleigh fading mod-

els are compared with the three robust state-of-the-art methods
∂ 2 ln L(Pr ) 
N
1 2(x − pi )2 β
= η − − that also estimate PLE and location using path-loss models. We
∂x2 α α2 P0 also present the advantages of the adaptive mini-batch method
i=1
[α η/2−1 + (η − 2)(x − pi )2 α η/2−2 ] (30) over fixed mini-batch and full batch methods for the simulation
environment.
Similarly The parameters used for simulating the Rayleigh fading and
lognormal shadowing are shown in Table II.
∂ ln L(Pr )  (y − qi ) ηβ  
N
η
= η − (y − qi )α 2 −1 (31) We simulate the Rayleigh faded environment with the help
∂y α P0 of standard path loss (1) and standard fading parameters, η and
i=1

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10672 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

TABLE III
E STIMATION OF PLE AND S MART D EVICE L OCATION W HEN L OCATIONS
OF A F EW S MART D EVICE A RE K NOWN

Fig. 3. (a) Variation of received power with distance for Rayleigh fading
and lognormal shadowing for given simulation parameters. (b) Variation of
localization error for different values of η and σg .

σr mentioned in [25] and [27]. We consider an indoor room of


area 20 × 20 m2 with 20 smart device locations at a particular
time. We consider a small area with different values of η, as
the fading affects are prominent in small indoor spaces, in-line
with the works that estimate PLE and location [6], [8], [19]. Fig. 4. (a) Comparison of cumulative distributed function (CDF) of localiza-
tion error for lognormal and Rayleigh fading. (b) Comparison of localization
error assuming lognormal shadowing [4], [31], and combined shadowing +
fading. (c) Comparison of tracking with the proposed combined model and
A. Localization Results for Simulation Environment only lognormal shadowing in a 20×20 simulated environment. x and y coordi-
In this section, we present the smart device localization nates represent the smart device locations in the given simulation environment.
S = Only shadowing, and S + F = Combined shadowing and fading.
results using the proposed method for the simulation envi-
ronment. The performance metric for the localization method
TABLE IV
is the average localization error, defined as E STIMATION OF PLE AND S MART D EVICE L OCATION
FOR AN U NKNOWN E NVIRONMENT
1 " "
S
" "
LE = "θ̂ t − θ t " (35)
S
t=1

where θ̂ t and θ t are the estimated and actual location of the


tth smart device, respectively. We consider a total of S smart
devices in the IoT network.
The smart device location is estimated using the proposed
method for an environment with both Rayleigh fading and log-
normal shadowing. We use 1000 Monte Carlo runs and report scenario, is for the simulation environment with η = 5. As
the estimated parameters with 95 % confidence interval (CI). the PLE is increased for a new environment, the estimation
Fig. 3(a) shows the received power for the cases consider- error also marginally increases. This is due to the fact that the
ing Rayleigh, lognormal, and no shadowing, respectively. The higher value of PLE indicates more obstructions, and hence
value of σr is 0.85 and for Rayleigh fading and lognormal a higher number of NLOS paths, thereby degrading the loca-
shadowing, the value of σg2 is considered as 6 dB. tion estimate. However, the variation in localization error is
Scenario 1: We vary the shadowing effect (σg2 ) and PLE to marginal, which shows the robustness of the proposed method
analyze the effect of the localization error. Fig. 3(b) shows the to higher PLE environments.
variation of the localization error for different values of PLE Scenario 3: We jointly estimate the PLE and smart device
and lognormal shadowing parameter σg2 . It is observed that location without prior knowledge of any environment parame-
for lower shadowing effects, the localization error is smaller ters. This is the most generic and robust scenario, as we do not
as compared to a higher σg2 . As the noise degrades the esti- put any constraint on the parameters such as PLE. In this sce-
mated parameters, it is observed that the localization error nario also, to estimate η, we run 1000 Monte Carlo simulations
marginally increases with the increase in noise. The proposed and report the 95 % CI. We initialize the PLE randomly in the
method provides lower localization error for the indoor envi- range of 2 to 5. Also, as the area of the simulated Indoor IoT
ronment (η = 3 to 6); hence the method is suitable for indoor network is known, the initial location estimate is randomly
environments as the PLE lies in the indoor environment range. chosen in the range of 0–20 m. Table IV shows the joint
Scenario 2: Assuming the locations of a few smart devices estimate of PLE and localization error for the simulated RSS
are known, to find the location of the smart devices using values. The average localization error for the simulation envi-
the proposed method, we first initialize the location estimates ronment with all considered value of η is 1.58 m. Therefore,
using (20). Table III shows the simulation results for the PLE the proposed method provides comparable average localiza-
and smart device localization error estimate. The average of tion error for all three cases. It is to be noted here that the
1000 Monte Carlo runs is reported in Table III along with the computed localization errors for all these cases are obtained
95 % CI. We observe that the estimate of PLE is closer to the for random placement of APs multiple times. It is possible
actual estimate for lower values of η. The maximum average that few smart device locations receive high RSS, and there-
localization error is 2.28 m using the proposed method in this fore, provide lower localization error. However, at few smart

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10673

Fig. 5. (a) Impact of epochs on localization error for different methods


on simulation data set. (b) Variation of mini-batch size with epochs for
convergence. Fig. 7. (a) Experimental indoor IoT environment for Wi-Fi RSS (dBm) data
collection. (b) Variation of Wi-Fi RSS at different locations.

track is much closer to the actual track. Hence, the proposed


method considering Rayleigh fading is better for an indoor
IoT environment as compared to only the shadowing model.
2) Comparison of Convergence Results: In this section, we
present the effectiveness of the different adaptive mini-batch
Fig. 6. (a) Impact of epochs on PLE for different methods on simulation
method. Fig. 5 shows the convergence of variants of gradi-
data. (b) Number of epochs required for different gradient ascent methods for ent ascent method and the selection of mini-batch size for
convergence of PLE. the proposed method. Fig. 5(a) demonstrates that the adaptive
mini-batch method converges earlier to the fixed mini-batch
method. The full batch method does not converge even after
device locations, the RSS values decrease, and the values are 15000 epochs. Fig. 5(b) shows the variation of batch size with
low leading to lower localization error. The reason for this the convergence factor (μ) and the number of epochs. We
is based on the term β in (2). If the value of β vanishes or observe that when the batch size is 1, the convergence factor
becomes very small because of low RSS values, the location μ < 1; therefore, the batch size is adaptively increased so that
estimate is inaccurate, leading to high localization error. We μ attains unity. As μ is close to unity, to attain sharper maxi-
report the average localization error for all the three cases. mum, the batch size is further increased utilizing more epochs.
Observe that the localization error remains comparable for It is observed that μ is closer to unity within 270 epochs.
all the three scenarios; hence, the proposed method is suitable However, μ attains unity and is stable around 845 epochs with
for an indoor fading environment where the parameters can a batch size of 30. Therefore, it utilizes the advantage of sin-
be known or unknown apriori. However, this small variation gle sample method (reaches closer to unity quickly in 270
in the location estimate is observed for the three scenarios epochs), that is, faster convergence, and also the advantage of
because, in the first two scenarios, we put a constraint on the the full batch method, that is, higher accuracy (achieved by
parameters that limit the search region for the maximum value further requiring 845 epochs to converge).
of the log-likelihood function. Fig. 6(a) shows the convergence of PLE for different vari-
1) Comparison of Smart Device Localization on Lognormal ants of gradient ascent methods. It is observed that the
Shadowing and Rayleigh Fading: As discussed in Section II proposed adaptive mini-batch method converges earlier than
that most of the existing methods assume only a lognormal the fixed mini-batch method. Also, the accuracy of the adaptive
shadowing for localization. Fig. 4 compares the localization and fixed mini-batch methods is more than the single sample
results when only shadowing, and combined shadowing and method, as it is closer to the actual estimate of η = 2. Fig. 6(b)
fading are considered. In particular, Fig. 4(a) compares the highlights the number of epochs required for each gradient
CDF of the localization error for both the models. It is ascent method to converge. It is observed that even after 10 000
observed that with the proposed method, the smart devices epochs, the full batch method is not converged. Thus, we con-
are localized within 1.34 m localization error, whereas the clude that the proposed adaptive mini-batch method is best
maximum localization error is 2.4 m when only lognormal suited for an indoor IoT environment as compared to other
shadowing is considered. The increase in localization error is gradient ascent methods.
observed because only lognormal shadowing is not sufficient
to model the RSS values in an indoor NLOS IoT environ-
ment. Now considering the fading effect, the localization error VI. P ERFORMANCE E VALUATION IN R EAL I OT T ESTBED
decreases as the RSS values are appropriately modeled, includ- The localization performance of the proposed method is
ing both the shadowing and fading effects. Fig. 4(b) compares tested on an indoor IoT environment consisting of multiple
the average localization error for both lognormal shadowing obstacles, such as walls and furniture contributing to shad-
as well as combined shadowing and Rayleigh fading. It is owing and fading. As the simulation environment may not
observed that there is a 50% reduction in the average local- exactly mimic the real-time indoor scenarios; hence, we test
ization error when the Rayleigh fading is considered combined the proposed method on a real-IoT testbed. We consider an
with shadowing. Finally, Fig. 4(c) shows the comparison using area of 600 m2 consisting of 26 locations where the smart
a tracking plot with the actual locations of smart devices devices are placed. The Wi-Fi RSS values are observed from
and estimated locations. It is observed that the combined 26 smart devices, as shown in Fig. 7(a). For this testbed, we

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10674 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

Fig. 8. (a) Variation of localization error for different gradient ascent methods Fig. 10. (a) Variation of mini-batch size with epochs for convergence.
on experimental data set. (b) Convergence of localization error with epochs (b) Convergence of different initialization methods.
for experimental data set.

parameters are known or fixed. In the following, we analyze


the convergence of different gradient ascent methods for the
experimental testbed.
1) Convergence Analysis: Fig. 8(b) shows the convergence
of full batch, fixed mini-batch, adaptive mini-batch, and single
sample gradient ascent methods. The results are in agreement
with the theory discussed in Section II as all the methods
Fig. 9. (a) Convergence of PLE for different gradient ascent methods. converge to the localization error value of approximately 4.78
(b) Number of epochs required for convergence. m. The single sample method converges fastest while the full
batch method takes maximum epochs to converge, and the
performance of the fixed mini-batch gradient ascent lies in
estimate the parameters and locations of the smart devices, as between the other two methods. Finally, the proposed adap-
discussed in Section II. The data set contains 180 RSS sam- tive mini-batch method is observed to converge with fewer
ples at each location. Fig. 7(b) shows the variation of Wi-Fi epochs than the fixed mini-batch method, for which we need
RSS at different locations. It is observed that because of the to choose an arbitrary batch size. A similar convergence trend
fading, the RSS values fluctuate and vary at the same location is observed for the PLE estimate, as shown in Fig. 9(a).
as well as at different locations. The proposed adaptive mini-batch method converges faster
than fixed mini-batch method. Fig. 9(b) shows the number
A. Localization Results for Real IoT Testbed of epochs required for each method to converge for the exper-
This section presents localization results on the experimen- imental IoT testbed. It is evident that the proposed adaptive
tal testbed. As the environment parameters are not known, mini-batch method requires fewer epochs than the fixed-batch
only Scenarios 2 and 3 are valid for this experimental testbed. method to converge for both simulation environment and
For Scenario 2, the estimated average PLE is 5.12, with a experimental testbed.
95 % CI of [5.08, 5.16]. This estimate is in agreement with Quick location updates are required for any connected IoT
the theoretical estimates of PLE presented in [25] as η = 5 environment; hence, early convergence of the adaptive method
indicates an indoor environment and the RSS data is actually leading to faster parameter updates is useful. As shown in
collected in a dense indoor environment. The estimated σr is Fig. 10(a), the convergence factor μ becomes unity after the
0.26 with 95 % CI of [0.23, 0.29], and the localization error is batch size of 55 and does not fluctuate. It can be observed that
4.75 m with a CI of [4.72, 4.78] using the adaptive mini-batch with the initial batch size of 1, the value of μ < 1. Therefore,
gradient ascent method. Similarly, for Scenario 3, the joint the batch size is increased, and within 800 epochs, μ reaches
average estimate of PLE and localization error is estimated as closer to unity. Now to achieve a sharper maximum, more
4.36 and 4.75 m, respectively. Thus, the localization error and epochs are utilized, and it is observed that around 2200 epochs,
PLE estimates are comparable to Scenario 2, where the loca- μ attains unity. Therefore, the proposed adaptive method uti-
tion information of a few smart devices was known. Fig. 8(a) lizes the advantage of both the single sample and full batch
represents the localization error for different type of gradi- methods.
ent ascent methods on the experimental data set. We observe For early convergence, the proper initialization of the gra-
that in the real-IoT scenario, the localization error is more dient ascent method is important. The effect of appropriate
as compared to the simulation environment as the simulation initialization is analyzed in Fig. 10(b). To analyze the effect
environment can not mimic all the changes occurring in a real of initialization, we find the number of iterations required for
environment. This shows the necessity of testing the proposed maximizing the log-likelihood function with a close estimate
method on real-time IoT testbeds. However, many existing (closer to the actual location coordinates) and a far estimate
path-loss-based localization methods [5], [8], [17] only report (farther from the actual location coordinates), respectively. It
localization error in a simulation environment. is observed that the WCL method converges at a compara-
The proposed adaptive mini-batch gradient ascent method ble number of iterations with the close estimate initialization.
for the joint estimation of all the unknown parameters yields However, other initialization methods take more iterations to
a good location estimate as observed from the CI in Tables III converge as compared to the WCL method. It is observed that
and IV on simulation environment as well as real-time IoT all the initialization methods converge and maximize the log-
testbed. The results are also at par with the cases where few likelihood function. Therefore, in the proposed method, we

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10675

provides the minimum localization error on the experimental


data set and a localization error of 2.15 m on the simulation
testbed. This method filters out the deep faded signals and then
utilizes the centroid localization with the grid scan, which is
highly computation intensive. As VariLoc work provides the
best localization performance on the experimental data set,
Fig. 11. Variation of CRLB and RMSE with smart devices.
we also compute the number of flops required to achieve this
TABLE V localization error.
C OMPARISON OF L OCALIZATION E RROR AND F LOP C OUNT OF The number of flops required for VariLoc is KN +
S TATE - OF - THE -A RT M ETHODS FOR B OTH S IMULATED 6MN + 7NA + 80(1 + 7NA) + 7NA + 2(|| + 1) =
AND R EAL I OT E NVIRONMENT
N(K + 6M + 574A) + 82 + 2|| where K denotes the trans-
mission power levels, M denotes number of samples per
transmission level, N is the number of APs, A is the num-
ber of grid points in the localization area, and || denotes
the number of grid points in the final set. Consider N = 20,
K = 10, A = 2400, || = 25. The total number of flop counts
obtained is 3 × 107 . However, for the same set of param-
eters the flop counts obtained for our proposed method is
8 × 105 . Therefore, it is observed that at convergence, VariLoc
method requires 100 times more flop counts than our proposed
method. The real experimental data set is not entirely Rayleigh
choose the WCL method for initializing the location estimate faded unlike the simulation environment, where we consid-
for Scenario 1 and Scenario 2, respectively. ered a perfect Rayleigh fading. Hence, the performance of
2) CRLB Analysis: The CRLB of the proposed method is our method is second best in the real environment, but best in
obtained from (25). Fig. 11 shows that the CRLB and the the case of a simulation environment where VariLoc provides
RMSE decrease with the number of smart devices. As the a high localization error. Given that the performance of our
number of smart devices increase, the RMSE is closer to proposed method is comparable to the Variloc method with
CRLB, thereby demonstrating the efficacy of our proposed lesser computational complexity in terms of the number of
estimation method. flop counts, we conclude that the proposed method provides
comparable localization error with the state-of-the-art local-
ization methods utilizing path-loss models and addressing the
B. Comparison With State-of-the-Art Methods fading effects. Additionally, the proposed method converges
Table V compares the proposed method with four robust faster in a Rayleigh fading environment.
state-of-the-art RSS-based localization methods that also uti-
lize path-loss models and address the fading. These methods
are frequently used for localization using Wi-Fi RSS val- VII. C ONCLUSION
ues due to their ease of implementation [1]. Specifically, we This article presented the localization of smart devices in an
choose WCL [36], particle filter (PF) [10], linear least square indoor IoT environment. The proposed Rayleigh fading-based
(LLS) [24], and VariLoc [5] methods to compare with our localization method includes the fading effects, which are
proposed method. mostly ignored in other existing path-loss-based localization
The WCL method [36] provides an unbiased location methods. We derive the maximum likelihood estimate for a
estimate and is extensively used for fast localization. This combined shadowing and Rayleigh faded environment, which
method is deployed for a Rayleigh fading environment, and is nonlinear, and estimate the model parameters using an adap-
exhibits increased localization accuracy with the increase in tive mini-batch gradient ascent method. The proposed method
the transmission power of the APs. However, the WCL method adaptively selects the batch size, and addresses the challenge
provides a high localization error of 7.5 m for our experimen- of arbitrary selection of fixed mini-batch size, thereby taking
tal data set as compared to the proposed method that provides the advantages of both full batch and single sample gradient
a localization error of 4.6 m. Shen et al. [10] also utilizes the ascent algorithms. Therefore, the proposed method is fast and
Rayleigh fading model and particle filtering approach. A high accurate, and hence suitable for the IoT network. Furthermore,
localization error of 6.9 m on real IoT testbed and 4.61 m a joint estimation of the model parameters is proposed that
on simulation testbed is reported with medium complexity in estimates the parameters adaptively with high accuracy in a
terms of flop counts. The LLS-based localization is another real-time indoor IoT scenario. The CRLB of the proposed
classic method that does not require apriori information of estimator is also derived. Our results for both simulation and
noise distribution [37]. This low-complexity method can be real environment, show a considerable improvement over the
utilized for most of the signal measurement techniques. It is methods that assume only the shadowing model with lesser
observed that for our experimental data set, the LLS method computational complexity. The future work includes consider-
provides a localization error of 5.5 m, and 6.36 m, respec- ing the mobility of smart devices for outdoor localization in
tively, for the simulation testbed. We report that Variloc [5] the presence of generalized fading models.

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
10676 IEEE INTERNET OF THINGS JOURNAL, VOL. 8, NO. 13, JULY 1, 2021

[4] N. Patwari, A. O. Hero, M. Perkins, N. S. Correal, and R. J. O’dea,


“Relative location estimation in wireless sensor networks,” IEEE Trans.
Signal Process., vol. 51, no. 8, pp. 2137–2148, Aug. 2003.
[5] M. Golestanian and C. Poellabauer, “VariLoc: Path loss exponent esti-
mation and localization using multi-range beaconing,” IEEE Commun.
Lett., vol. 23, no. 4, pp. 724–727, Apr. 2019.
[6] N. Salman, A. H. Kemp, and M. Ghogho, “Low complexity joint esti-
mation of location and path-loss exponent,” IEEE Wireless Commun.
Fig. 12. (a) Values of first-order principal minor for all locations. (b) Values Lett., vol. 1, no. 4, pp. 364–367, Aug. 2012.
of second order principal minor. (c) Log-likelihood values for the smart device [7] Z. Wang, H. Zhang, T. Lu, and T. A. Gulliver, “Cooperative RSS-based
at (0, 0). localization in wireless sensor networks using relative error estimation
and semidefinite programming,” IEEE Trans. Veh. Technol., vol. 68,
no. 1, pp. 483–497, Jan. 2019.
[8] R. Sari and H. Zayyani, “RSS localization using unknown statisti-
A PPENDIX cal path loss exponent model,” IEEE Commun. Lett., vol. 22, no. 9,
pp. 1830–1833, Sep. 2018.
A. Concavity of the Log-Likelihood Function [9] R. Adhikary and J. N. Daigle, “RSS based localization in Rayleigh
fading environment,” in Proc. IEEE Wireless Commun. Netw. Conf.,
The global maximum should be attained using the gradient 2016, pp. 1–6.
ascent method, and the function should not be stuck at a local [10] J. Shen, B. Huang, Y. Tian, and L. Zhao, “On the reliable localization
maximum. The function attains a unique global maximum if of WiFi access points,” IEEE Access, vol. 7, pp. 90931–90940, 2019.
[11] A. Devarakonda, M. Naumov, and M. Garland, “AdaBatch: Adaptive
it is concave, differentiable, and Lipschitz continuous [38]. batch sizes for training deep neural networks,” 2017. [Online]. Available:
Here, we prove the concavity of the log-likelihood function arXiv:1712.02029.
obtained in (11). For strong concavity, the function should [12] D. Masters and C. Luschi, “Revisiting small batch training for deep
neural networks,” 2018. [Online]. Available: arXiv:1804.07612.
be twice differentiable, and its Hessian should be negative [13] L. Yang and K. C. Ho, “An approximately efficient TDOA localization
definite. The Hessian matrix is given as algorithm in closed-form for locating multiple disjoint sources with erro-
⎡ 2 ⎤ neous sensor positions,” IEEE Trans. Signal Process., vol. 57, no. 12,
∂ ln L(Pr ) ∂ ln L(Pri )
2
pp. 4598–4615, Dec. 2009.
∂x∂y
H=⎣ ∂x2
∂ 2 ln L(Pri ) ∂ 2 ln L(Pr )
⎦. [14] S. Xu and K. Doğançay, “Optimal sensor placement for 3-D angle-of-
arrival target localization,” IEEE Trans. Aerosp. Electron. Syst., vol. 53,
∂y∂x ∂y2 no. 3, pp. 1196–1211, Jun. 2017.
[15] Q. Song, S. Guo, X. Liu, and Y. Yang, “CSI amplitude fingerprinting-
The matrix H is negative definite if the first-order principal based NB-IoT indoor localization,” IEEE Internet Things J., vol. 5, no. 3,
minor satisfies ([∂ 2 ln L(Pr )]/∂x2 ) < 0, and the second order pp. 1494–1504, Jun. 2018.
principal minor satisfies [16] Y. Hu and G. Leus, “Robust differential received signal strength-
based localization,” IEEE Trans. Signal Process., vol. 65, no. 12,
# #
# ∂ 2 ln L(Pr ) ∂ 2 ln L(Pri ) # pp. 3261–3276, Jun. 2017.
# ∂x2 # [17] R. W. Ouyang, A. K.-S. Wong, and C.-T. Lea, “Received sig-
D2 = ## ∂ 2 ln L(P ) 2 ∂x∂y ## > 0. nal strength-based wireless localization via semidefinite programming:
∂ ln L(Pr )
# ∂y∂x ri
∂y2
# Noncooperative and cooperative schemes,” IEEE Trans. Veh. Technol.,
vol. 59, no. 3, pp. 1307–1318, Mar. 2010.
We compute the first-order principal minor (D1 ) for the [18] G. Wang and K. Yang, “A new approach to sensor node localization
using RSS measurements in wireless sensor networks,” IEEE Trans.
given indoor scenario. Fig. 12(a) shows D1 < 0 ∀ θ . Similarly, Wireless Commun., vol. 10, no. 5, pp. 1389–1395, May 2011.
D2 is computed as shown in Fig. 12(b) that exhibits D2 > 0 ∀ [19] G. Wang, H. Chen, Y. Li, and M. Jin, “On received-signal-strength based
θ . Hence, H is negative definite. It is observed that the second localization with unknown transmit power and path loss exponent,” IEEE
Wireless Commun. Lett., vol. 1, no. 5, pp. 536–539, Oct. 2012.
order derivative is finite ∀ θ, implying the function is differ- [20] T. Olofsson, A. Ahlén, and M. Gidlund, “Modeling of the fading statis-
entiable. As discussed in [39], a concave function is locally tics of wireless sensor network channels in industrial environments,”
Lipschitz continuous. Therefore, all the conditions for the log- IEEE Trans. Signal Process., vol. 64, no. 12, pp. 3021–3034, Jun. 2016.
[21] M. T. N. Truong and S. Kim, “Optimization for particle filter-based
likelihood function’s concavity are satisfied, and the function object tracking in embedded systems using parallel programming,” in
attains the global maximum. It is also verified from Fig.12(c) Advances in Computer Science and Ubiquitous Computing. Singapore:
that for a particular location (0, 0) of the smart device, the log- Springer, 2016, pp. 246–252.
[22] P. Bergamo and G. Mazzini, “Localization in sensor networks with
likelihood attains maximum around the same location. Hence, fading and mobility,” in Proc. PIMRC, 2002, pp. 750–754.
the maximum is achieved at the estimated smart device loca- [23] X. Zhang, C. Tepedelenlioğlu, M. K. Banavar, A. Spanias, and
tion and function is not stuck at local maximum as it is concave G. Muniraju, “Location estimation and detection in wireless sensor
networks in the presence of fading,” Phys. Commun., vol. 32, pp. 62–74,
and evident from Fig. 12(c). A similar nature of the log- Feb. 2019.
likelihood function is also obtained for other locations of the [24] H. C. So and L. Lin, “Linear least squares approach for accurate received
smart device. signal strength based source localization,” IEEE Trans. Signal Process.,
vol. 59, no. 8, pp. 4035–4040, Aug. 2011.
[25] T. S. Rappaport, Wireless Communications: Principles and Practice,
R EFERENCES vol. 2. Upper Saddle River, NJ, USA: Prentice Hall PTR, 1996.
[26] P. M. Shankar, Fading and Shadowing in Wireless Systems. Cham,
[1] F. Zafari, A. Gkelias, and K. K. Leung, “A survey of indoor localization Switzerland: Springer, 2017.
systems and technologies,” IEEE Commun. Surveys Tuts., vol. 21, no. 3, [27] A. Goldsmith, Wireless Communications. Cambridge, U.K.: Cambridge
pp. 2568–2599, 3rd Quart., 2019. Univ. Press, 2005.
[2] A. Dogandzic and P. P. Amran, “Signal-strength based localization in [28] A. Papoulis and S. U. Pillai, Probability, Random Variables, and
wireless fading channels,” in Proc. Conf. Rec. 38th Asilomar Conf. Stochastic Processes. Boston, MA, USA: Tata McGraw-Hill Educ.,
Signals Syst. Comput., vol. 2, 2004, pp. 2160–2164. 2002.
[3] A. Pandey, R. Vamsi, and S. Kumar, “Handling device heterogeneity [29] M. G. Rabbat and R. D. Nowak, “Decentralized source localization and
and orientation using multistage regression for GMM based localization tracking [wireless sensor networks],” in Proc. IEEE Int. Conf. Acoust.
in IoT networks,” IEEE Access, vol. 7, pp. 144354–144365, 2019. Speech Signal Process., vol. 3, 2004, pp. 921–924.

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.
PANDEY et al.: ADAPTIVE MINI-BATCH GRADIENT-ASCENT-BASED LOCALIZATION FOR INDOOR IoT 10677

[30] R. Ge, F. Huang, C. Jin, and Y. Yuan, “Escaping from saddle points- Sudhir Kumar (Senior Member, IEEE) received the
online stochastic gradient for tensor decomposition,” in Proc. Conf. Ph.D. degree from the Electrical Engineering (EE)
Learn. Theory, 2015, pp. 797–842. Department, Indian Institute of Technology Kanpur,
[31] G. Mao, B. Fidan, and B. D. Anderson, “Wireless sensor network local- Kanpur, India, in 2015.
ization techniques,” Comput. Netw., vol. 51, no. 10, pp. 2529–2553, He is currently an Assistant Professor with the EE
2007. Department, Indian Institute of Technology Patna,
[32] N. S. Keskar, D. Mudigere, J. Nocedal, M. Smelyanskiy, and Patna, India. He has worked as an Erasmus Mundus
P. T. P. Tang, “On large-batch training for deep learning: Generalization Fellow with the Department of Computer Science,
gap and sharp minima,” 2016. [Online]. Available: arXiv:1609.04836. University of Oxford, Oxford, U.K. He has pub-
[33] L. Bottou, F. E. Curtis, and J. Nocedal, “Optimization methods for large- lished more than 45 research articles in prestigious
scale machine learning,” SIAM Rev., vol. 60, no. 2, pp. 223–311, 2018. journals and conference proceedings. His broad
[34] J. Blumenthal, R. Grossmann, F. Golatowski, and D. Timmermann, research interests include wireless sensor networks and Internet of Things.
“Weighted centroid localization in zigbee-based sensor networks,” in Dr. Kumar is a recipient of several awards and fellowships, such as the
Proc. IEEE Int. Symp. Intell. Signal Process., 2007, pp. 1–6. Best Teacher Award in UG Teaching from the EE Department, the CSIR and
[35] S. M. Kay, Fundamentals of Statistical Signal Processing. Englewood SERB International Travel Grants, the National Award from L&T—ISTE for
Cliffs, NJ, USA: Prentice Hall PTR, 1993. having guided the Best M.Tech. Thesis (Second Prize), the SERB Indo-U.S.
[36] K. Magowe, A. Giorgetti, S. Kandeepan, and X. Yu, “Accurate analysis Postdoctoral Fellowship, the India-EU Namaste Fellowship, the TCS Research
of weighted centroid localization,” IEEE Trans. Cogn. Commun. Netw., Scholarship, and the MHRD Scholarship.
vol. 5, no. 1, pp. 153–164, Mar. 2019.
[37] S. Cao, X. Chen, X. Zhang, and X. Chen, “Combined weighted method
for TDOA-based localization,” IEEE Trans. Instrum. Meas., vol. 69,
no. 5, pp. 1962–1971, May 2020.
[38] S. Boyd, S. P. Boyd, and L. Vandenberghe, Convex Optimization.
Cambridge, U.K.: Cambridge Univ. Press, 2004.
[39] A. Cambini and L. Martein, Generalized Convexity and Optimization:
Theory and Applications, vol. 616. Heidelberg, Germany: Springer,
2009.

Ankur Pandey (Graduate Student Member, IEEE)


received the M.Tech. degree in communication
systems engineering from the Indian Institute of
Technology Patna, Patna, India, in 2018, where he
is currently pursuing the Ph.D. degree with the
Department of Electrical Engineering.
His research interest includes signal processing
for IoT networks addressing the smart device local-
ization challenges.
Mr. Pandey is a recipient of the National Award Sajal K. Das (Fellow, IEEE) received the Ph.D.
from L&T—ISTE for the Best M.Tech. Thesis (2nd degree in computer science from the University of
Prize), the Best M.Tech. Thesis Award from the institute, and the Institute Central Florida in 1988. He is currently a pro-
Silver Medal for scoring highest CPI in the course. fessor of Computer Science and the Daniel St.
Clair Endowed Chair at the Missouri University of
Science and Technology, Rolla, USA. His current
research interests include wireless sensor networks,
mobile and pervasive computing, cyber-physical
Piyush Tiwary was born in Bihar, India, in January systems and IoT, smart environments (smart city,
2000. He is currently pursuing the B.Tech. degree smart grid, and smart health), edge and cloud com-
in electrical engineering from the Indian Institute of puting, and cyber security. He has published exten-
Technology Patna, Patna, India. sively in these areas and coauthored four books, including the Principles
His research interests lie in the area of deep of Cyber-Physical Systems: An Interdisciplinary Approach (Cambridge
learning and statistical machine learning. His cur- University Press, 2020).
rent interest is focused on the generalization of deep Prof. Das is the Editor-in-Chief of Pervasive and Mobile Computing, and
learning methods across domains. an Associate Editor of several journals including IEEE T RANSACTIONS ON
D EPENDABLE AND S ECURE C OMPUTING and IEEE T RANSACTIONS ON
M OBILE C OMPUTING.

Authorized licensed use limited to: Indian Institute of Technology Patna. Downloaded on July 29,2021 at 14:46:37 UTC from IEEE Xplore. Restrictions apply.

You might also like