title: Ð Ð°Ð·ÑÐ°Ð±Ð¾ÑÐºÐ° Ð¾Ñ ÑÐ°Ð½Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ Ñ ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸ÐµÐ¼ Ð»Ð¸Ñ Ð½Ð° Ð¾ÑÐ½Ð¾Ð²Ðµ Ð¾Ð´Ð½Ð¾Ð¿Ð»Ð°ÑÐ½Ð¾Ð³Ð¾ ÐºÐ¾Ð¼Ð¿ÑÑÑÐµÑÐ° Raspberry pi 4 Ñ ÑÐ¿ÑÐ°Ð²Ð»ÐµÐ½Ð¸ÐµÐ¼ ÑÐµÑÐµÐ· TelegramâÐÐ¾ÑÐ°
title: Ð²ÑÐ¿ÑÑÐºÐ½Ð°Ñ ÐºÐ²Ð°Ð»Ð¸ÑÐ¸ÐºÐ°ÑÐ¸Ð¾Ð½Ð½Ð°Ñ ÑÐ°Ð±Ð¾ÑÐ° Ð±Ð°ÐºÐ°Ð»Ð°Ð²ÑÐ°
titleType: Subtitle
title: Development of a security system with face recognition based on a single-board Raspberry pi 4 computer controlled via Telegram-Bot
Creators: name: ÐÑÑÐµÐ¹Ð½Ð¾Ð², Ð¢Ð¸Ð¼ÑÑ
Publisher: name: Ð¡Ð°Ð½ÐºÑ-ÐÐµÑÐµÑÐ±ÑÑÐ³ÑÐºÐ¸Ð¹ Ð¿Ð¾Ð»Ð¸ÑÐµÑÐ½Ð¸ÑÐµÑÐºÐ¸Ð¹ ÑÐ½Ð¸Ð²ÐµÑÑÐ¸ÑÐµÑ ÐÐµÑÑÐ° ÐÐµÐ»Ð¸ÐºÐ¾Ð³Ð¾
Year: 2020
Subjects: raspberry pi
opencv
telegram
bot
picamera
ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ðµ Ð»Ð¸Ñ
Ð´Ð°ÑÑÐ¸Ðº Ð´Ð²Ð¸Ð¶ÐµÐ½Ð¸Ñ - hc-sr501
python
face recognition
motion sensor - hc-sr501

description: Ð¢ÐµÐ¼Ð° Ð²ÑÐ¿ÑÑÐºÐ½Ð¾Ð¹ ÐºÐ²Ð°Ð»Ð¸ÑÐ¸ÐºÐ°ÑÐ¸Ð¾Ð½Ð½Ð¾Ð¹ ÑÐ°Ð±Ð¾ÑÑ: Â«Ð Ð°Ð·ÑÐ°Ð±Ð¾ÑÐºÐ° Ð¾ÑÑÐ°Ð½Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ Ñ ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸ÐµÐ¼ Ð»Ð¸Ñ Ð½Ð° Ð¾ÑÐ½Ð¾Ð²Ðµ Ð¾Ð´Ð½Ð¾Ð¿Ð»Ð°ÑÐ½Ð¾Ð³Ð¾ ÐºÐ¾Ð¼Ð¿ÑÑÑÐµÑÐ° Raspberry pi 4 Ñ ÑÐ¿ÑÐ°Ð²Ð»ÐµÐ½Ð¸ÐµÐ¼ ÑÐµÑÐµÐ· Telegram-BotÂ». 

ÐÐ°Ð½Ð½Ð°Ñ ÑÐ°Ð±Ð¾ÑÐ° Ð¿Ð¾ÑÐ²ÑÑÐµÐ½Ð° ÑÐ°Ð·ÑÐ°Ð±Ð¾ÑÐºÐµ Ð¿ÑÐ¾Ð³ÑÐ°Ð¼Ð¼Ð½Ð¾Ð³Ð¾ Ð¾Ð±ÐµÑÐ¿ÐµÑÐµÐ½Ð¸Ñ Ð¸ ÑÐ±Ð¾ÑÐºÐµ Ð¾ÑÑÐ°Ð½Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ. Ð ÑÐ¾Ð´Ðµ ÑÐ°Ð±Ð¾ÑÑ Ð±ÑÐ»Ð¸ ÑÐµÑÐµÐ½Ñ ÑÐ»ÐµÐ´ÑÑÑÐ¸Ðµ Ð·Ð°Ð´Ð°ÑÐ¸:
1. Ð¡Ð±Ð¾ÑÐºÐ° Ð°Ð¿Ð¿Ð°ÑÐ°ÑÐ½Ð¾Ð¹ ÑÐ°ÑÑÐ¸ Ð¾ÑÑÐ°Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ; 
2. Ð£ÑÑÐ°Ð½Ð¾Ð²ÐºÐ° Ð¸ ÑÐ±Ð¾ÑÐºÐ° Ð²ÑÐµÑ Ð½ÐµÐ¾Ð±ÑÐ¾Ð´Ð¸Ð¼ÑÑ Ð±Ð¸Ð±Ð»Ð¸Ð¾ÑÐµÐº Ð¸ Ð·Ð°Ð²Ð¸ÑÐ¸Ð¼Ð¾ÑÑÐµÐ¹; 
3. ÐÐ°Ð¿Ð¸ÑÐ°Ð½Ð¸Ðµ Ð¿ÑÐ¾Ð³ÑÐ°Ð¼Ð¼Ð½Ð¾Ð³Ð¾ Ð¾Ð±ÐµÑÐ¿ÐµÑÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ð¾ÑÑÐ°Ð½Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ; 
4. Ð¦Ð¸ÐºÐ»Ð¸ÑÐµÑÐºÐ°Ñ Ð·Ð°Ð¿Ð¸ÑÑ Ð²Ð¸Ð´ÐµÐ¾ Ð² Ð±ÑÑÐµÑ Ð¿Ð°Ð¼ÑÑÐ¸; 
5. Ð Ð°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ðµ Ð»Ð¸ÑÐ° ÑÐµÐ»Ð¾Ð²ÐµÐºÐ° Ð¸ Ð¸Ð´ÐµÐ½ÑÐ¸ÑÐ¸ÐºÐ°ÑÐ¸Ñ Ð»Ð¸ÑÐ½Ð¾ÑÑÐ¸; 
6. Ð¡Ð¾Ð·Ð´Ð°Ð½Ð¸Ðµ Ð¸ Ð½Ð°ÑÑÑÐ¾Ð¹ÐºÐ° Telegram-Bot. 
Ð Ð°Ð±Ð¾ÑÐ° Ð¿ÑÐ¾Ð²ÐµÐ´ÐµÐ½Ð° Ð² ÑÐ¸ÑÑÐµÐ¼Ðµ Linux Raspbian Ð²ÐµÑÑÐ¸Ð¸ 9.6, Ð½Ð° ÑÐ·ÑÐºÐµ Ð¿ÑÐ¾Ð³ÑÐ°Ð¼Ð¼Ð¸ÑÐ¾Ð²Ð°Ð½Ð¸Ñ python 3. Ð Ð´Ð°Ð½Ð½Ð¾Ð¹ ÑÐ°Ð±Ð¾ÑÐµ Ð² Ð¾ÑÐ½Ð¾Ð²Ð½Ð¾Ð¼ Ð±ÑÐ»Ð¸ Ð¸ÑÐ¿Ð¾Ð»ÑÐ·Ð¾Ð²Ð°Ð½Ñ Ð±Ð¸Ð±Ð»Ð¸Ð¾ÑÐµÐºÐ¸ OpenCV Ð¸ TelegramBotAPI. Ð Ð°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ðµ Ð»Ð¸Ñ Ð¿ÑÐ¾Ð¸ÑÑÐ¾Ð´Ð¸Ñ Ð¿Ð¾ Ð¼ÐµÑÐ¾Ð´Ñ Viola Jones Ñ Ð¸ÑÐ¿Ð¾Ð»ÑÐ·Ð¾Ð²Ð°Ð½Ð¸ÐµÐ¼ Ð¿ÑÐ¸Ð·Ð½Ð°ÐºÐ° Ð¥Ð°Ð°ÑÐ°.
ÐÑÐ¾Ð³Ð¾Ð¼ Ð´Ð¸Ð¿Ð»Ð¾Ð¼Ð½Ð¾Ð¹ ÑÐ°Ð±Ð¾ÑÑ ÑÐ²Ð»ÑÐµÑÑÑ Ð¿ÑÐ¾ÐµÐºÑ Ð¾ÑÑÐ°Ð½Ð½Ð¾Ð¹ ÑÐ¸ÑÑÐµÐ¼Ñ Ñ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ÑÑÑÑ ÐµÐ³Ð¾ Ð¼Ð¾Ð´ÐµÑÐ½Ð¸Ð·Ð°ÑÐ¸Ð¸ Ð´Ð¾ ÑÐ¸ÑÑÐµÐ¼Ñ Â«ÑÐ¼Ð½ÑÐ¹ Ð´Ð¾Ð¼Â». Ð ÐµÐ·ÑÐ»ÑÑÐ°ÑÐ¾Ð¼ ÑÐ°Ð±Ð¾ÑÑ Ð¿ÑÐ¾-Ð³ÑÐ°Ð¼Ð¼Ñ ÑÐ²Ð»ÑÐµÑÑÑ Ð¾Ð¿Ð¾Ð²ÐµÑÐµÐ½Ð¸Ðµ Ð¿Ð¾Ð»ÑÐ·Ð¾Ð²Ð°ÑÐµÐ»Ñ Ð¾ ÑÑÐ°Ð±Ð°ÑÑÐ²Ð°Ð½Ð¸Ð¸ Ð´Ð°ÑÑÐ¸ÐºÐ° Ð´Ð²Ð¸Ð¶ÐµÐ½Ð¸Ñ Ñ Ð¿Ð¾Ð¼Ð¾ÑÑÑ ÑÐ¾Ð¾Ð±ÑÐµÐ½Ð¸Ñ, Ð·Ð²ÑÐºÐ¾Ð²Ð°Ñ ÑÐ¸Ð³Ð½Ð°Ð»Ð¸Ð·Ð°ÑÐ¸Ñ, Ð²Ð¸Ð´ÐµÐ¾Ð·Ð°Ð¿Ð¸ÑÑ ÑÐ¾Ð±ÑÑÐ¸Ñ, Ð¿ÑÐ¸ ÐºÐ¾ÑÐ¾ÑÐ¾Ð¼ ÑÑÐ°Ð±Ð¾ÑÐ°Ð» Ð´Ð°ÑÑÐ¸Ðº Ð´Ð²Ð¸Ð¶ÐµÐ½Ð¸Ñ, ÑÐ¾ÑÐ¾Ð³ÑÐ°ÑÐ¸Ñ Ð»Ð¸ÑÐ° ÑÐµÐ»Ð¾Ð²ÐµÐºÐ°, Ð¾Ð±Ð½Ð°ÑÑÐ¶ÐµÐ½Ð½Ð¾Ð³Ð¾ Ð½Ð° Ð²Ð¸Ð´ÐµÐ¾Ð·Ð°Ð¿Ð¸ÑÐ¸. Ð¡ Ð¿Ð¾Ð¼Ð¾ÑÑÑ ÑÑÐ¸Ñ Ð´Ð°Ð½Ð½ÑÑ Ð²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð° Ð¸Ð´ÐµÐ½ÑÐ¸ÑÐ¸ÐºÐ°ÑÐ¸Ñ Ð»Ð¸ÑÐ½Ð¾ÑÑÐ¸ Ð¾Ð±ÑÐµÐºÑÐ° Ð²Ð¸Ð´ÐµÐ¾Ð·Ð°Ð¿Ð¸ÑÐ¸.
ÐÐ°Ð½Ð½Ð°Ñ ÑÐ°Ð±Ð¾ÑÐ° Ð¸Ð¼ÐµÐµÑ ÑÐ¾ÑÐ¾ÑÐ¸Ðµ Ð¿Ð¾ÐºÐ°Ð·Ð°ÑÐµÐ»Ð¸. ÐÐ°ÑÑÐ¸Ðº Ð´Ð²Ð¸Ð¶ÐµÐ½Ð¸Ñ ÑÑÐ°Ð±Ð°ÑÑÐ²Ð°ÐµÑ Ð² 99 Ð¿ÑÐ¾ÑÐµÐ½ÑÐ°Ñ ÑÐ»ÑÑÐ°ÐµÐ². ÐÐµÑÐ¾Ð´ ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ñ Ð»Ð¸Ñ Viola Jones Ð¸Ð¼ÐµÐµÑ 87 Ð¿ÑÐ¾ÑÐµÐ½ÑÐ¾Ð² ÑÐ¾ÑÐ½Ð¾ÑÑÐ¸ ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ñ Ð¸ Ð¼ÐµÑÐ¾Ð´ Ð¸Ð´ÐµÐ½ÑÐ¸ÑÐ¸ÐºÐ°ÑÐ¸Ð¸ Ð¸Ð¼ÐµÐµÑ Ð¾ÐºÐ¾Ð»Ð¾ 70 Ð¿ÑÐ¾ÑÐµÐ½ÑÐ¾Ð² ÑÐ¾ÑÐ½Ð¾ÑÑÐ¸ ÑÐ°ÑÐ¿Ð¾Ð·Ð½Ð°Ð²Ð°Ð½Ð¸Ñ. Ð¢Ð°ÐºÐ¶Ðµ Ð¿ÑÐ¾ÐµÐºÑ Ð¸Ð¼ÐµÐµÑ ÑÐ¾ÑÐ¾ÑÐ¸Ðµ Ð¿ÐµÑÑÐ¿ÐµÐºÑÐ¸Ð²Ñ ÑÐ°Ð·Ð²Ð¸ÑÐ¸Ñ Ð² ÑÐ¸-ÑÑÐµÐ¼Ñ "ÑÐ¼Ð½ÑÐ¹ Ð´Ð¾Ð¼". ÐÑÐ¸ ÑÑÐ¾Ð¼ Ð²ÑÐµÐ¼, Ð¿ÑÐ¾ÐµÐºÑ Ð¸Ð¼ÐµÐµÑ Ð² Ð´Ð²Ð° ÑÐ°Ð·Ð° Ð½Ð¸Ð¶Ðµ ÑÑÐ¾Ð¸Ð¼Ð¾ÑÑÑ Ð¿Ð¾ Ð² ÑÑÐ°Ð²Ð½ÐµÐ½Ð¸Ñ Ñ ÐºÐ¾Ð½ÐºÑÑÐµÐ½ÑÐ°Ð¼Ð¸, ÐºÐ¾ÑÐ¾ÑÑÐµ Ð½Ðµ Ð¸ÑÐ¿Ð¾Ð»ÑÐ·ÑÑÑ ÐºÐ°Ð¼ÐµÑÑ Ð² ÑÐ²Ð¾Ð¸Ñ ÑÐ¸ÑÑÐµÐ¼Ð°Ñ.
description: The topic of the final qualification work is âDevelopment of a security system with face recognition based on a single-board Raspberry pi 4 computer controlled via Tele-gram-Botâ. 
 This project is devoted to software development and security system setting-up. Objectives that were achieved throughout this work:
1. Assembly of the security system's hardware; 
2. Installation and assembly of all necessary libraries and dependencies; 
3. Development security system software; 
4. Loop recording to the buffer memory; 
5. Recognition of a person's face and personal identification;
6. Creation and configuration of a Telegram-Bot.
 
 The work was carried out in Linux Raspbian version 9.6 system and was pro-grammed in python 3 language. Mainly the OpenCV and TelegramBotAPI libraries were used in this work. Face recognition occurs according to the Viola Jones method using Haar-like features.

 As a result of the thesis a security system project with the possibility of its modernization to the "smart home" system was created. The outcome of the program is user's notification of the signal detection with the motion sensor with a message, an audible alarm, a video of the event in which the motion sensor worked, a photograph of the face of a person detected in the video. Using this data, it is possible to identify the video object's personality. 

 This work has good performance indicators. The motion sensor is triggered at 99 percent response. The Viola Jones facial recognition method has 87 percent recognition accuracy and the identification method has about 70 percent recognition accuracy. The project also has good development prospects into the "smart home" system. In addition, this project has half the cost compared to competitors' systems which do not use cameras in their performance.