Machine Learning

Amine Neifer
8 min readJan 26, 2020

--

Thinking about machine learning, if we break it down, we come to two words:

Machine: a word we’ve been used to , us Humans, for so long, and it is a mechanical device that is built to make actions that will make human’s life simpler, because, machines can be so strong (like machines that help for construction uses), so precise and so fast (like computers), unlike us. Almost every machine nowadays is related to a computer or is simply a computer.

Learning: well, who am I to explain learning, anybody could read about it in Wikipedia but all that matters in our case, that learning was always a Human quality, yes animals can learn too, but, well, you got me right!

Before coming to the magical link between these two, for those who are developers, those who used computers and could figure out that their computers are dumb because it doesn’t fix itself, can’t do anything that it hasn’t been programmed to do. I, simply, when I make a decision to code a program, here’s what my mind thinks:

“Noob computer! how could this dumb computer know when to stop going the while loop, how could this dumb computer know what to expect from the final user if I didn’t explicitly make it clear and code it”. While debugging my programs, all I think about, is the “computer is dumb and I need to make everything so simple to him”, because if you take an inexperienced fella who never back-flipped in his life and tell him to do a back-flip, he’ll just keep staring at you, he knows nothing about back-flipping, he needs to know, what to do , how to do it, what to do in case of this and what to do in case of that, he simply needs some learning, and practicing

Anyway, recombining these two little words would form a sentence with a powerful meaning, a very rich field full of researches, that most big companies in the world like Google and Facebook are studying and implementing in their work to simply make their products. Every computer/mobile user has benefited from this technology, if you don’t know, let me tell you that face recognition technology is actually a good example for machine learning, when you tag yourself or somebody tags you in a picture with you face on it, with good number of pictures, a computer could recognize you in any other picture you are in. Facebook uses this technology, any user could relate to this. Recommendation engines, we see this in YouTube, and Netflix, how do they simply suggest some cool videos that you might end up clicking on those videos and stop using the search section. All of these use machine learning algorithms made by professionals. Quite fascinating isn’t it!

Machine Learning has a lot of methods, every method has a number of algorithms that you can use, well there’s a variety, and each one of them has some advantages and disadvantages, you should use the algorithm each project depending on some criteria, like, how precise you want the output to be, or, how fast you want the machine to get the result.

Okay, now, let’s take a look at some of the ML methods.

Supervised Learning

In supervised Learning, we provide the computer with labeled pictures, most common examples are giving pictures of dogs and labeling them with dog, and pictures of cats and labeling them with cat, after a certain amount of pictures, if you enter a dogs picture, the computer can guess it right, well, in a a precision based on number of pictures you entered other things too, like taking a picture of the dog from behind, taking a picture of only his head, taking a picture of his full body. This is used to classify pictures like, google photos do if you ever used it, you’d notice.

Unsupervised Learning

In unsupervised Learning, seems to be contrary to the last one! it’s obvious that it doesn’t take labeled picture, but what’s not obvious, is, what does it do !? it’s goal was to discover hidden patterns within a dataset, finding similarities and differences that maybe, us humans, didn’t notice or can’t notice.

Decision Tree Learning

Now this is quite simple because it’s easy to put it in an example and the examples can be easily interpreted, you’ll see. Well, take an example, we have Billy, a 10 year old boy, how to know whether he is going to school tomorrow or not? let’s see this little picture to make it clear.

so simple isn’t it ? so, analyzing this, we feed our ML program with some data, taking our picture, we give it information, about the age and whether a person eats pizza or exercises in the morning or not. And it just outputs whether the person is fit or not. If you’re a developer or a programmer you would think of it as a succession of if statements looking like this:

Deep Learning

this takes us to another topic, a question that’s so common to hear people asking, which is “what’s the difference between Deep Learning (DL), Artificial intelligence (AI) and Machine Learning (ML)?”. So I will answer this question and after that I will explain and Deep Learning and make it even more clear.

so let’s start with AI, I couldn’t find a better definition to it than the computer scientist John McCarthy, who says “AI involves machines that can perform tasks that are characteristic of human intelligence”. Anyhow, AI can be presented in two different categories, general and narrow. General AI would be a total duplication of the characteristics of human intelligence. The narrow AI doesn’t cover all of the human brain capabilities, but considering what it can do !? well it does it very well! like recognizing cats in a picture, or recognizing voice or speech. Well, didn’t you already notice that it pretty much reminds you of ML ? well, I’m happy to tell you dear reader that “machine learning is simply a way of achieving AI”. Said Arthur Samuel and defined it saying that it is “the ability to learn without being explicitly programmed.”

Deep Learning is a subset of machine learning, inspired by the structure and function of the human brain namely the interconnecting of many neurons. Artificial Neural Networks (ANNs) are algorithms that mimic the biological structure of the brain. It would be hard to explain it because it is not that simple so I will just share with you this little video.

DL is quite crucial when it comes to precision, it used in a variety of tasks like computer vision, speech recognition, playing board and video games, medical diagnoses.

Since this big field is so fascinating, why some developers don’t even think about contributing to it ? Well, because of it’s mathematics. As probability and statistics take a big role in finding hidden insights iteratively with computer science and algorithms, which can be used in building intelligent robots and applications. You can use algorithms and make an application using machine learning and it will actually work, but, if you don’t have a thoroughly mathematical understanding of a lot of techniques, you won’t even understand what are you doing and what the algorithms are doing, and what’s the point of that ? You are not learning, you are just copy-pasting… Which is just dumb and not recommended especially for a developer.

In conclusion, reading some articles there in google I can site the minimum level of mathematics you need for ML,

  • Linear Algebra, as Skyler Speakman said “Linear Algebra is the mathematics of the 21st century”, as it comes up everywhere, namely, Decomposition/Factorization, Symmetric Matrices, Orthogonalization & Orthonormalization, Matrix Operations, Projections, Vector Spaces and Norms which are needed for understanding the optimization methods used for ML.
  • Probability and Statistics, some agree that ML is just “doing statistics on a Mac”, as some of the fundamental Statistical and Probability Theory is needed for ML such as Combinatorics, Standard Distibutions (Bernouilli, Binomial, Uniform and Gaussian) and many more!
  • Multivariate Calculus, as Differential and Integral Calculus are crucial in our topic (same as for many others).
  • Algorithms and Complex Optimizations
  • Others, like Metric spaces, continuous functions, limits, Cauchy Kernel and many of the fundamentals.

In conclusion

Machine Learning is taking over most of fields (medical field, agriculture, fashion, video games etc…) , it’s used alot in our life, it is found in every phone, in most of the computer applications, in entrepreneurship as there’s what we call Business Intelligence, which uses ML and it is so popular among businesses as it takes a very big part in taking decisions in a company. As for mathematics, it’s the mother of all sciences, it is used in Physics, science, Mechanics, Technology, agriculture… so, finding out that it plays a big role in machine learning wasn’t much of a surprise to me!

To write this blog, I did a little research and here are my resources:

--

--