0
1
00:00:00,870 --> 00:00:01,670
Hello.
1

2
00:00:01,710 --> 00:00:02,280
Welcome back.
2

3
00:00:02,880 --> 00:00:11,010
So when building and deploying machine learning algorithms on EDGE devices like mobile phones and embedded
3

4
00:00:11,010 --> 00:00:18,620
devices such as smartwatches and those and those other devices found in smart phones, 
4

5
00:00:18,670 --> 00:00:26,680
we have to keep three key factors in mind. And edge over here includes embedded devices, like smartwatches,
5

6
00:00:26,690 --> 00:00:29,750
the smart home alarm etc.
6

7
00:00:29,760 --> 00:00:35,790
So whenever you think of EDGE device in our case we're dealing with the microcontroller essentially.
7

8
00:00:36,300 --> 00:00:37,460
Right.
8

9
00:00:37,590 --> 00:00:43,900
So the first one we have to keep in mind, the first factor, is what is known as latency.
9

10
00:00:44,250 --> 00:00:47,880
And this simply means delay in data transfer.
10

11
00:00:47,880 --> 00:00:55,500
This becomes a problem when the machine learning model exists in the cloud and therefore to make a prediction,
11

12
00:00:55,860 --> 00:01:00,830
you will have to send your input to the cloud.
12

13
00:01:00,870 --> 00:01:06,120
Another factor we have to consider is the privacy and security.
13

14
00:01:06,120 --> 00:01:11,620
The third factor of consideration is the network reliability.
14

15
00:01:11,640 --> 00:01:18,930
There are ways to develop and deploy machine learning algorithms on your microcontroller and doing predictions
15

16
00:01:18,930 --> 00:01:22,710
locally without having to connect to the cloud.
16

17
00:01:22,710 --> 00:01:28,220
We are going to explore some of those ways in this course.
17

18
00:01:28,630 --> 00:01:36,490
Some some examples of machine learning on edge devices include Smart Home Security visitor tracking,
18

19
00:01:36,550 --> 00:01:39,290
plant disease detection, drone
19

20
00:01:39,340 --> 00:01:48,640
avionics device optimization, on-device translations etc. I am sure you may have seen other examples
20

21
00:01:48,700 --> 00:01:49,600
out there.
21

22
00:01:49,600 --> 00:01:55,120
My hope is that by the end of this course you'll be able to come up with your own deep learning solutions
22

23
00:01:55,120 --> 00:01:57,700
to the problems facing where you live.
23

24
00:01:58,660 --> 00:02:05,290
Now let's see some limitations of machine learning on microcontrollers.
24

25
00:02:05,290 --> 00:02:12,370
Of course when we are dealing with something as computationally intensive as machine learning it comes
25

26
00:02:12,370 --> 00:02:14,420
with certain requirements.
26

27
00:02:14,530 --> 00:02:22,150
One of them is high processing power. When deploying machine learning algorithms on microcontrollers
27

28
00:02:22,180 --> 00:02:29,050
we have to keep in mind the low memory footprint of microcontrollers. In this table here it gives an
28

29
00:02:29,050 --> 00:02:36,400
example of some of the popular microcontrollers out there, their processing frequency which is their processing
29

30
00:02:36,400 --> 00:02:39,820
power and how much memory they have.
30

31
00:02:39,880 --> 00:02:46,390
We will have to do with things like compressing our model and using optimized data types in order
31

32
00:02:46,390 --> 00:02:49,570
to overcome these limitations.
32

33
00:02:49,570 --> 00:02:58,070
Now we are going to take a look at some libraries out there for doing machine learning on ARM processors.
33

34
00:02:58,090 --> 00:03:04,380
Currently there are two major libraries designed for optimized machine learning performance on ARM cortex
34

35
00:03:04,390 --> 00:03:05,270
processors.
35

36
00:03:05,290 --> 00:03:12,100
The first one of course is the CMSIS NN and CMSIS stands for the cortex microcontroller software
36

37
00:03:12,250 --> 00:03:17,600
interface standard that and the NN stands for neural network.
37

38
00:03:17,650 --> 00:03:25,280
CMSIS NN is a collection of optimized neural network functions for cortex-M processors.
38

39
00:03:25,330 --> 00:03:31,780
The library is optimized because it takes full advantage of the ARM cortex M hardware like the use of
39

40
00:03:31,780 --> 00:03:36,760
floating point and SIMD capabilities of the microcontroller.
40

41
00:03:36,760 --> 00:03:44,710
We should treat CMSIS thoroughly in its own section. CMSIS NN is managed by ARM.
41

42
00:03:45,460 --> 00:03:52,610
The next popular library is cube MX dot AI and this is managed by SΤ microelectronics.
42

43
00:03:53,000 --> 00:03:54,100
,
43

44
00:03:54,190 --> 00:04:00,810
It also allows us to deploy optimizeδ machine learning modules on ΑΡΜ cortex Μ processors.
44

45
00:04:00,820 --> 00:04:07,930
However this one works with only microcontrollers from ST microelectronics but of course with patience
45

46
00:04:07,990 --> 00:04:16,170
and determination, it is quite possible to make it work with any cortex microcontroller right.
46

47
00:04:16,420 --> 00:04:21,090
So in the next lesson we should start talking about the introduction to neural network.
47

48
00:04:21,080 --> 00:04:23,980
This is all there is for this one and I shall see you later.
