Thesis
Thesis
Thesis
SYSTEMS
by
Copyright © graduation,2024
Dedication
I dedicate this thesis to my family for their unwavering support and encourage-
ment throughout my academic journey. To my parents, who have always believed
in me and pushed me to reach my full potential. To my siblings, who have been
my biggest cheerleaders and inspiration. And to my friends, who have stood by me
through late-night study sessions and moments of doubt. Without their love and en-
couragement, I would not have been able to achieve this milestone. I also dedicate
this thesis to my professors and mentors, who have guided me and nurtured my in-
tellectual growth. Their expertise and guidance have been invaluable in shaping my
research . This thesis is dedicated to all those who have supported, influenced, and in-
spired me on my journey to graduation. Thank you for believing in me and standing
by me every step of the way. “khadidja”
i
ii
This work is dedicated to my family, whose unwavering support and love have
been my strength. To my late father, who remains my guiding star and inspiration;
your memory continues to motivate me to strive for excellence.
To my friends, for their constant encouragement and companionship throughout
this journey.
To my teachers, for their invaluable guidance and wisdom that have shaped my
path.
Thank you all for being an integral part of my success.“Amina”
Abstract
iii
iv
Above all, we are grateful to God for giving us the strength, endurance, and health
we have needed over these years. We would like to express our sincere gratitude
to our supervisors Dr.fateh bougerra, Dr serairi fouzi and madame khacha for their
invaluable guidance, support, and encouragement throughout this project. We are
also thankful to the faculty and staff of the Department of Electronics and Telecom-
munications Systems at University Batna 2 and fablab laboratory for providing us
with the necessary resources and facilities to complete this work. Lastly, we extend
our heartfelt appreciation to our families and friends for their unwavering support
and understanding during the course of this project.
v
Contents
Dedication ii
Abstract iv
Acknowledgements v
vi
Contents vii
2 System description 13
2.1 introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.2 The control platform . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.2.1 Raspberry Pi . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.2.2 Raspberry Pi 4 specifications . . . . . . . . . . . . . . . . . . 14
2.3 Camera module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
2.3.1 The Raspberry Pi Camera Module . . . . . . . . . . . . . . . 15
2.3.2 the Raspberry Pi Camera Module specifications . . . . . . . . 16
2.4 The mobile platform . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.5 Additional components . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.5.1 The HC-SR04 sensor . . . . . . . . . . . . . . . . . . . . . . . 17
2.5.2 Connection wires . . . . . . . . . . . . . . . . . . . . . . . . . 18
3 pratical aspect 20
3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
3.1.1 Implementation Overview . . . . . . . . . . . . . . . . . . . . 20
3.2 Background . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
3.3 Problem Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
3.4 synoptic/function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Contents viii
3.5 training . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3.5.1 roboflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3.5.2 google collab . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
3.6 Software part . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
3.6.1 Operating system . . . . . . . . . . . . . . . . . . . . . . . . . 24
3.6.2 Programming language and required libraries . . . . . . . . . 24
3.7 Organigramme . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
4 Chapter 4 Name 27
4.1 Section 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.1.1 Subsection 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.2 Section 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.2.1 Subsection 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
A Title of appendix 30
List of Tables
ix
List of Figures
x
Acronyms
AI Artificial Intelligence
DL Deep Learning
ML Machine Learning
1.1 Intoduction
Artificial Intelligence (AI) has revolutionized the way we perceive and interact with
technology, enabling machines to perform tasks traditionally requiring human intel-
ligence. It involves imbuing computers, computer-controlled robots, or software with
the capacity to think intelligently, akin to the human mind. This is achieved through
1
1.3. Machine Learning 2
the examination of human brain patterns and analysis of cognitive processes. The
culmination of these investigations leads to the creation of intelligent software and
systems. AI emphasizes the capability to think deeply and analyze data comprehen-
sively.
Machine learning addresses the question of how to build computers that improve
automatically through experience. It is one of todayâs most rapidly growing technical
fields, lying at the intersection of computer science and statistics, and at the core
of artificial intelligence and data science. Recent progress in machine learning has
been driven both by the development of new learning algorithms and theory and by
the ongoing explosion in the availability of online data and low-cost computation.
The adoption of data-intensive machine-learning methods can be found throughout
science, technology and commerce, leading to more evidence-based decision-making
across many walks of life, including health care, manufacturing, education, financial
modeling, policing, and marketing.Jordan and Mitchell (2015)
Deep learning allows computational models that are composed of multiple process-
ing layers to learn representations of data with multiple levels of abstraction. These
methods have dramatically improved the state-of-the-art in speech recognition, visual
object recognition, object detection and many other domains such as drug discovery
and genomics. Deep learning discovers intricate structure in large data sets by using
1.4. Deep Learning 3
the backpropagation algorithm to indicate how a machine should change its inter-
nal parameters that are used to compute the representation in each layer from the
representation in the previous layer. Deep convolutional nets have brought about
breakthroughs in processing images, video, speech and audio, whereas recurrent nets
have shone light on sequential data such as text and speech.LeCun et al. (2015)
Figure 1.1: Differences between Artificial intelligence, machine learning and deep
learning.
A deep neural network (DNN) is a type of artificial neural network with multiple
layers between the input and output layers. These layers enable the network to learn
hierarchical representations of data, allowing it to model complex relationships and
make increasingly abstract interpretations. DNNs have gained popularity due to
their ability to handle large and complex datasets, making them well-suited for tasks
1.4. Deep Learning 4
such as image and speech recognition, natural language processing, and more.
There are several types of deep neural networks, each designed to address specific
tasks and data types. Some common types include:
1. Convolutional Neural Networks (CNNs): Particularly effective for image recog-
nition and classification tasks, CNNs use convolutional layers to extract features from
input images and pooling layers to reduce dimensionality.
2. Recurrent Neural Networks (RNNs): Well-suited for sequential data processing
tasks such as time series analysis, language modeling, and speech recognition. RNNs
have recurrent connections that allow them to retain information over time.
3. Long Short-Term Memory Networks (LSTMs): A specialized type of RNN
designed to address the vanishing gradient problem, LSTMs are capable of learning
long-term dependencies in sequential data, making them useful for tasks like speech
recognition and language translation.
4. Generative Adversarial Networks (GANs): Consisting of two neural networks,
a generator and a discriminator, GANs are used for generating new data instances
that resemble a given dataset. They are commonly used for image generation and
data augmentation.
5. Autoencoders: These networks are designed to learn efficient representations
of data by training to reconstruct their input. They can be used for tasks such as
dimensionality reduction, data denoising, and anomaly detection.
6. Deep Belief Networks (DBNs): Comprising multiple layers of stochastic, latent
variables, DBNs are capable of learning hierarchical representations of data. They
are often used for unsupervised learning tasks such as feature learning and density
1.5. Convolutional Neural Network (CNN) 5
estimation.
These are just a few examples of deep neural network architectures, and there
are many other variations and combinations tailored to specific applications and
domains.Liu et al. (2017)
such as image classification, object detection, and facial recognition. Despite their
efficacy, CNNs face challenges such as overfitting, which can hinder their generaliza-
tion capability. The rapid growth of CNNs is facilitated by powerful deep learning
frameworks such as TensorFlow, Keras, and PyTorch.
CNNs draw inspiration from the hierarchical architecture and local connectivity of
the human visual system.
The architecture of CNNs comprises several key components, including convolu-
tional layers, rectified linear units (ReLU), pooling layers, and fully connected layers.
This section elucidates the functionality of each component and its role in feature
extraction and prediction. Saha (2018)
Convolutional neural networks, or CNNs, are very good deep learning models that
are mostly applied to the interpretation of images and videos. These are the main
uses for them:
-Recognition and Categorization of Images:
.Improve search results by classifying and analyzing photos using search engines.
.Social media: Recognize and tag individuals in pictures.
.Recommender Systems: Provide analogous images by analyzing the visual con-
tent.
-Object Detection:
.vital for robots, self-driving automobiles, and surveillance systems by recognizing
and localizing things in photos.
-Recognizing faces:
.Analyze facial traits to identify faces: this technique is utilized in social media
tagging, smartphone unlock features, and security systems.
These uses highlight the adaptability and strength of CNNs in interpreting and
analyzing visual data.Pra
‘
1.Supervised Learning:
-In supervised learning, the model learns from labeled data. Itâs given input-
output pairs (features and corresponding labels) during training.
1.5. Convolutional Neural Network (CNN) 8
-The goal is to learn a mapping from inputs to outputs, so the model can make
accurate predictions on unseen data.
-Examples include image classification (where each image has a label), regression
(predicting a continuous value), and natural language processing tasks.
2.Unsupervised Learning:
-In unsupervised learning, the model learns from unlabeled data. It doesnât have
explicit output labels. -The goal is to discover patterns, structures, or relationships
within the data.
-Examples include clustering (grouping similar data points), dimensionality re-
duction (reducing features while preserving information), and anomaly detection
3.Semi-Supervised Learning:
-Semi-supervised learning combines elements of both supervised and unsupervised
learning. It uses a small amount of labeled data along with a larger amount of
unlabeled data.
-The idea is to leverage the unlabeled data to improve model performance.
-Examples include using labeled images along with a large set of unlabeled images
for training an image classifier.Robert (2024)
1.7 Conclusion
The definitions provided underscore the capability of deep learning to efficiently man-
age and process vast amounts of data, performing intricate mathematical operations
that can rival the expertise of human specialists in certain tasks, or tackle problems
that are beyond human capacity to solve within reasonable timeframes.
However, this significant advantage comes with its own set of drawbacks. Com-
plex deep learning models require substantial computing resources, typically only
available on high-end computers or specialized computing accelerators. Moreover,
the development of these models demands extensive resources, both in terms of
computational power and time. Such resources are often costly, prompting many
developers to utilize platforms like Google Colab, where computing resources are
rented out by big companies to facilitate model development.
Chapter 2
System description
2.1 introduction
In this section, we will introduce the primary components and technologies that form
the foundation of our project. We will discuss their specifications and elaborate on
the rationale behind selecting them.
Our image processing algorithms need to be performed on-board. There are some
embedded processing platforms known for that, like the NVIDIA Jetson, Odroid,
Asus Tinker Board⦠Based on availability once again, we decided to go with the
Rapsberry Pi 4 model B 8GB RAM.
2.2.1 Raspberry Pi
Raspberry Pi 4 is a small, low-cost computer device known for its high processing
power and advanced capabilities. It belongs to the fourth generation of the Raspberry
13
2.2. The control platform 14
Pi series and is designed to meet the needs of developers and enthusiasts in areas
such as programming, electronics, and artificial intelligence.
5. Storage: MicroSD card slot for operating system and data storage.
6. GPIO: 40-pin GPIO header (fully backwards-compatible with previous Rasp-
berry Pi boards).
7. Power: USB-C connector for power input (supports up to 3A).
8. Dimensions: 85mm à 56mm à 22mm.
These specifications make the Raspberry Pi 4 Model B a versatile and power-
ful single-board computer suitable for various applications, including DIY projects,
educational purposes, and embedded systems development.
There are a lot of cameras adapted for this use. We chose to go with the Raspberry
Pi Camera Module Rev 1.3 for availability and compatibility with our Raspberry Pi.
The specifications of the Raspberry Pi Camera Module (latest version, V2) are as
follows:
1. **Resolution**: 8 megapixels (3280 Ã 2464 pixels).
2. **Sensor**: Sony IMX219PQ CMOS sensor.
3. **Lens**: Fixed focus.
4. **Aperture**: f/2.0.
5. **Field of View (FOV)**: 62.2 degrees diagonal.
6. **Supported Video Modes**: - 1080p at 30fps - 720p at 60fps - VGA (640 Ã
480 pixels) at 90fps.
7. **Supported Still Image Modes**: - 3280 Ã 2464 pixels - 2592 Ã 1944 pixels
- 1920 Ã 1080 pixels (1080p) - 1280 Ã 720 pixels (720p) - 640 Ã 480 pixels (VGA).
2.4. The mobile platform 17
We chose the Keyestudio KS4032 4WD mecanum robot car for micro:bit due to its
omnidirectional movement capabilities, which allow for translations and rotations in
all directions using mecanum wheels. This smart DIY car is designed for micro:bit
and includes a car body with extended functions, a PCB base plate with integrated
motor drive sensors, 4 decelerating DC motors, mecanum wheels, various modules,
sensors, and acrylic boards.
distance to an object.
The HC-SR04 sensor is easy to use and integrate into robotics projects because
it has four wires: power, mass, trigger and echo. It can be controlled by a variety of
electronic controllers, such as the Arduino card.
HC-SR04 sensors are useful for robots that need to avoid obstacles or navigate
in an environment. They can also be used to detect moving objects, to measure
distances to objects etc.
Connection wires are electrical wires used to connect electronic components to the
raspberry pi. They are commonly used to connect sensors, actuators, displays and
other components to the raspberry pi to create electronic circuits.
2.5. Additional components 19
There are two types of connection wires: male-male connections and male-female
connections. Male-male connector wires are used to connect components that both
have male pins, while male-female connectors are used for connecting components
with a male and a female pins.
Connection wires are usually made of copper or copper alloy and are coated with
a plastic insulator to protect electrical wires and prevent short circuits. They are
available in a variety of colors to help identify and organize the different wires in a
circuit.
pratical aspect
3.1 Introduction
3.2 Background
The rapid advancements in artificial intelligence, computer vision, and robotics have
paved the way for innovative solutions across various industries. In the retail sector,
the increasing competition from online shopping platforms has compelled brick-and-
mortar stores to explore new ways to enhance customer experiences and maintain
their relevance. One promising approach is the integration of smart technologies, such
as autonomous human-following shopping trolleys, to provide a more personalized
20
3.3. Problem Statement 21
and efficient shopping experience. Traditional shopping trolleys, while serving their
purpose, often pose challenges for customers, especially those with limited mobility
or those who find it cumbersome to navigate crowded store aisles while pushing
a trolley. Moreover, the lack of interactive features and personalized assistance in
conventional trolleys may lead to a less engaging shopping experience. To address
these issues and bridge the gap between online and offline shopping, the concept of
smart human-following shopping trolleys has emerged.
Despite the potential benefits of smart human-following shopping trolleys, their im-
plementation faces several challenges. Firstly, robust human detection and tracking
in dynamic and crowded environments, such as shopping malls, is a complex task.
Traditional computer vision techniques may struggle to accurately identify and fol-
low the target person amidst occlusions, varying lighting conditions, and multiple
individuals in the scene. Secondly, autonomous navigation in indoor environments
requires precise localization, obstacle avoidance, and path planning capabilities. The
trolley must be able to seamlessly navigate through narrow aisles, avoid collisions
with static and moving obstacles, and maintain a safe following distance from the
target person. Ensuring smooth and reliable navigation while considering factors
such as speed, stability, and responsiveness is crucial for the trolley’s usability and
user acceptance. Lastly, integrating various hardware components, such as sensors,
cameras, and actuators, and developing a cohesive software architecture that enables
real-time processing, decision-making, and control is a significant challenge. The sys-
3.4. synoptic/function 22
3.4 synoptic/function
3.5 training
3.5.1 roboflow
Roboflow simplifies the process of annotating datasets for machine learning projects,
enabling teams to collaborate efficiently. The platform allows users to invite team
members, upload and share datasets, annotate images, and merge individual datasets
into a final one. This workflow not only speeds up the annotation process but
3.5. training 23
also ensures consistency and quality in the labeled data. Roboflow also supports
preprocessing and augmentations to enhance dataset quality, making it easier to
train robust machine learning models Roboflow (2024)
Training data in Google Colab for tensorflow involves a series of steps to set up
the environment, configure the model, and initiate the training process. Google
Colab provides an excellent platform for this due to its free access to powerful GPU
resources, which are crucial for training deep learning models efficiently.
The process begins with setting up the required dependencies, including the ten-
sorflow repository and necessary Python packages. Next, configuration files are cre-
ated for both the model architecture and training parameters. These configuration
files specify details such as the number of classes, paths to the training and validation
datasets, and various model-specific settings.
Once the setup is complete, the training process can be started using specific
commands in Colab. These commands define the image size, batch size, number of
epochs, and paths to the configuration files and pre-trained weights. During training,
it is essential to monitor performance metrics like mAP (mean Average Precision)
to ensure the model is learning correctly.
After training, the model’s performance is evaluated on a validation dataset, and
visualizations of the training results are generated using tools like TensorBoard or
custom plotting scripts. Finally, the trained model can be tested on new images to
assess its real-world performance.Natsunoyuki (2024)
3.6. Software part 24
The operating system for Raspberry Pi has been specifically created for it. The op-
erating system is Linux, tailored specifically for Raspberry Pi devices. It is renowned
for its dependability, adaptability, security, and low power usage. Preinstalled pro-
gramming languages and tools include C, C++, and Python.
Depending on our tastes, we can use any programming language, however Python is
the best option for AI, ML, DL, and data science.
The libraries that are going to be used are:
**OpenCV-Python: This Python binding library was created to address issues
related to computer vision. Python is a general-purpose programming language that
was created by Guido van Rossum. It gained a lot of popularity very fast, mostly
due to its ease of use and readable code. It allows the programmer to write code
that conveys ideas in fewer lines without sacrificing readability.
Python is slower than languages like C/C++. Having said that, C/C++ is a
simple way to extend Python, enabling us to develop computationally demanding
code in C/C++ and produce Python wrappers that can be utilized as Python mod-
ules. Due to the fact that real C++ code is running in the background, this offers
us two benefits: first, the code is just as quick as the original C/C++ code; second,
it is simpler to write.
3.6. Software part 25
**NumPy: The core Python module for scientific computing is called NumPy.
A multidimensional array object, different derived objects (like masked arrays and
matrices), and a variety of routines for quick operations on arraysâlike sorting, se-
lecting, I/O, logical, mathematical, and discrete Fourier transformsâas well as basic
statistical operations, random simulation, and much moreâare all provided by this
Python library.
**TensorFlow Lite: For mobile and embedded devices, TensorFlow Lite is a con-
densed version of TensorFlow. By offering pre-trained models that are optimized and
tools to effectively convert and deploy bespoke models, it facilitates on-device ma-
chine learning. Applications like mobile apps, Internet of Things devices, and edge
computing solutions that demand low latency and low power consumption are well
suited for TensorFlow Lite, which is compatible with several platforms. It is appro-
priate for real-time applications because it enables quick inference and low memory
consumption.
3.7. Organigramme 26
3.7 Organigramme
Chapter 4 Name
4.1 Section 1
4.1.1 Subsection 1
4.2 Section 2
4.2.1 Subsection 2
27
Bibliography
Michael I Jordan and Tom M Mitchell. Machine learning: Trends, perspectives, and
prospects. Science, 349(6245):255–260, 2015.
Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. nature, 521(7553):
436–444, 2015.
Weibo Liu, Zidong Wang, Xiaohui Liu, Nianyin Zeng, Yurong Liu, and Fuad E
Alsaadi. A survey of deep neural network architectures and their applications.
Neurocomputing, 234:11–26, 2017.
28
Bibliography 29
speeding-up-model-training-with-google-colab-b1ad7c48573e. Accessed:
2024-06-04.
Matt Richardson and Shawn Wallace. Getting started with raspberry PI. “ O’Reilly
Media, Inc.”, 2012.
Sumit Saha. A comprehensive guide to convolutional neural networks â the eli5 way.
Towards Data Science, 2018.
Appendix A
Title of appendix
30