OVIDIUS University of Constant a [616586]
Ministry of National Education
"OVIDIUS" University of Constant a
Faculty of Mathematics and Computer Science
Degree Program: Computer Science
Home Assistant for Elderly People
Scientic Adviser:
Conf. dr. Pelican Elena
Student: [anonimizat] a
2018
Resume
Aletheria
.paltforma: android
.domeniul principal:
.domenii adiacente: inteligent a articial a, recunoa stere facial a
.tipul lucr arii: sintez a
Aletheria
.paltform: android
.main domain:
.secondary domains: articial inteligence, facial recognition
.type: synthesis
Outline
Outline 1
1 Introduction 2
2 Content 3
2.1 Reminder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.2 Chatbot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
2.3 Face Recognition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
3 Application 8
4 Conclusions 9
4.1 Future works . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
References 10
1
Chapter 1
Introduction
This idea came to life from the desire of easing the lives of elderly people. How
will it ease their lives? Simple! This application is designed to the needs of the
elderly,having features that will help them throughout the day.
Seeing how my grandmothers have a hard time remembering some things that
are important or trying to use smartphone, I thoight that maybe I could desing an
app that would be easy for them to use and that would help them remembering the
forgotten things. As the idea started to form in my mind, I thought that I sould also
add a feature for the people that suers from alzheimer, so I added face recognition.
Up until now the application contain three functional features:
.Reminder
.Chatbot
.Face recognition
Reminder
I thought of the application to have a reminder activity that will help the user remember
activities or events. For example this part of the application could be used for taking
pills, or checking every night before bedtime if the doors and windows are closed.
Chatbot
The application has integrated a chatbot functionality mainly to help entertaining the
elders, helping them in dierent activities and socialize with them.
Face recognition
The last functionality is it for a rather extreme case. I thought about integrating a
facial recgnition in the application so it can be used mostly by people who suers from
alzheimer and they cannot recognize even their family.
2
Chapter 2
Content
2.1 Reminder
2.2 Chatbot
2.3 Face Recognition
For this feature I used the [1] for the integration of the Eigenfaces algorithm. I
used the algorithm from [2]. PCA (Principal Component Analysis) is a method of
identifying patterns in data. We use PCA to obtain a set of eigenfaces. For a dataset
with N images, each image must have the same resolution
M=n1xn2
and is transformed into a vector
i
of dimmensions M x 1.
Then it is calculated the mean vector
'i= i ;i=1;N
which is substraced from all the vectors that forms the dataset. That means that the
data is "centered".
The rst singular image is dened by the principal singurlars vectors, looks like the
mean vector. From here we conclude that there is no benet from substracting the
mean vector from all the others vectors.
The PCA algorithm is applied to the vectors set of big dimmensions
'1;'2;:::;' N
3
Content Face Recognition
. A set of orthonomal vector
u1;u2;:::;u N
which will best describe the patterns from the dataset is sought for.
Let A:m x n be a centered data matrix, where each column has random values of
mean 0.
Let SVD decomposition for A,
A=UVT
.
The right singular vectors
vi
are named principal components directions.
The vector
z1=Av1=1u1
has the biggest variation from all the liniar normalized combinations belonging to the
column A:
var(z1) =var(Av1) =!2
1
m
We remind that for a vector/sample x of length n, we have
var(x) =1
nnX
i=1(xi x)2
, where
x
is the mean of the vector x.
Finding the maximum varience vectors is equivalent, in liniar algebra terms, with
maximization of Rayleight coecients
2
1= max
v6=0vTATAv
vTv=kAvk2
kvk2
,
v1=argmax
v6=0kAvk2
kvk2
The normalized variable
ui=1
1Av1
is called the rst principal component of A.
Then, we want to determine the vector with the second biggest varience wich is
perpendicular to the rst vector. This is obtain by calculating the biggest varience of
the "de
ated" matrix,
A A 1u1vT
1
4
Content Face Recognition
and so on…
We will explain the pick of
ukand k
. From the SVD decomposition of the matrix A we have
A=UVT
, where A is of dimensions N x N, and
=diag(1;2;::::; r;0;:::::0)
with
1:::r>0
, r = rang(A),
Let
u1;u2;:::u N
a subspace of U of dimmension N. Then each vector
'i
can be written as:
'i=fi1u1+fi2u2+:::+fiNuN;i=1;N
. We obtain the relation:
fij='T
iuj=<u j;'i>
We know that for a symmetric and positive-dened matrix B, we have
(B) =1;::::; n[0;1);minkxk2<Bx;x>maxkxk2and max= max
kxk6=0<Bx;x>
kxk2= max
kxk26=0xTBx
kxk2
.
But
max(AAT) =2
1;where 1
is the biggest singular value of the matrix A.We have
wTAATw= (ATw)T(ATw) =kATwk2=NX
i=1j'T
1wj2
So we obtain:
max
w6=0wT(AAT)w
wTw= max
kwk=1wT(AAT)w= max
kwk=1NX
i=1j'T
iwj2
. So we are looking for
max
kwk=1NX
i=1j'T
iwj2
5
Content Face Recognition
.
We have:
AAT=UVTVTUT=UTUT;usingthisweobtain :wT(AAT)w
wTw=xTTx
xtx=1
1×1
1+2
2×2
2+:::+r
rxr
r
x2
1+x2
2+:::+x2
N
.
We suppose that
12:::r
and we obtain:
max
x6=1
1×1
1+2
2×2
2+:::+r
rxr
rx2
1+x2
2+:::+x2
N=2
1=1
The Eigenfaces algorithm
Step1: All images are transformed into vectors:
1; 2;:::; N
Step2: Then it is calculated the mean vector
=1
NNX
i=1 i
Step3: The mean vector is subtracted from all the vectors from dataset:
'i= i ;i=1;N
Step4: We obtain the covariance matrix:
C=1
NNX
i=1'i'T
i=1
NAAT
Step5:We obtain the eigen vectors
ui=1;N
of the matrix C and we keep the rst k vectors, which correspond to the biggest k eigen
values.
Step6: We then obtain the vector:
T
i= [!i
1;!i
2;:::;!i
k]
6
Content Face Recognition
, with
'i'^'i=kX
j=1!i
jui
j
Step7: Being given an image
, it is normalized:
'=
Step8:
is projected on the space of eigen vectors:
^'i=kX
j=1!juj
Step9:
^'
is represented as
T
i= [!1;!2;:::;! k]
Step10: We are searching for a
i021;:::;N
that satisfy
k i0k= min
1iNk ik
7
Chapter 3
Application
I gave this application the name of "Aletheia", which is a greek word that can be
translasted as truth or disclosure. But there is also a literal meaning to the word, the
state of not being hidden or being evident.
The reason why I chose this word was because, being the oposite of the word
lethe that can be translated to forgetfulness, oblivion or concealment, I believe that it
captures the essence of what this application is built for.
Reminder
.a date picker, so the user can choose the data of a certain event or activity
.a time picker, so the user can choose the time of the said activity or event
.a repeat function, so the user can choose if the activity he is creating is a repeating
one or not
.a repetition interval, so the user can choose the interval of the repeating activity
.the type of repetition, e.g hourly, daily, weekly etc.
Chatbot
The application has integrated a chatbot functionality mainly to help entertaining the
elders, helping them in dierent activities and socialize with them.
Face recognition
The last functionality is it for a rather extreme case. I thought about integrating a
facial recgnition in the application so it can be used mostly by people who suers from
alzheimer and they cannot recognize even their family.
8
Chapter 4
Conclusions
4.1 Future works
In the future I plan to integrae
.speech recognition so the user can communicate easily with the chatbot without
needing to write. I plan to integrate both speech-to-text and text-to-speech so it
will make a more enjoyable communication between the man and machine.
.google maps so that the users can know the path back home, or to the doctor
or to the store, or anywhere else. This feature will have a table that contains
some crucial information such as: the home address, the doctor address, the
store address, the park address. With this data I wil draw the minimum distance
between two points such as: the user wants to go to the store from home, he will
select the destination location and the app will shortly show the most favorable
route to the destination from the current location.
.a medical log so that if the user knows what pills they have alergies to, etc.
9
References
[1] Opencv library.
[2] Elena Pelican si L acr amioara Lit a. Algoritmi pentru recunoa sterea fet elor . MA-
TRIX ROM BUCURES TI, 2015.
10
Copyright Notice
© Licențiada.org respectă drepturile de proprietate intelectuală și așteaptă ca toți utilizatorii să facă același lucru. Dacă consideri că un conținut de pe site încalcă drepturile tale de autor, te rugăm să trimiți o notificare DMCA.
Acest articol: OVIDIUS University of Constant a [616586] (ID: 616586)
Dacă considerați că acest conținut vă încalcă drepturile de autor, vă rugăm să depuneți o cerere pe pagina noastră Copyright Takedown.
