Master Deep Learning with TensorFlow in Python
Data scientists, machine learning engineers, and AI researchers all have their own skillsets. But what is that one special thing they have in common?
They are all masters of deep learning.
We often hear about AI, or self-driving cars, or the ‘algorithmic magic’ at Google, Facebook, and Amazon. But it is not magic – it is deep learning. And more specifically, it is usually deep neural networks – the one algorithm to rule them all.
Cool, that sounds like a really important skill; how do I become a Master of Deep Learning?
There are two routes you can take:
The unguided route – This route will get you where you want to go, eventually, but expect to get lost a few times. If you are looking at this course you’ve maybe been there.
The 365 route – Consider our route as the guided tour. We will take you to all the places you need, using the paths only the most experienced tour guides know about. We have extra knowledge you won’t get from reading those information boards and we give you this knowledge in fun and easy-to-digest methods to make sure it really sticks.
Clearly, you can talk the talk, but can you walk the walk? – What exactly will I get out of this course that I can’t get anywhere else?
Good question! We know how interesting Deep Learning is and we love it! However, we know that the goal here is career progression, that’s why our course is business focused and gives you real world practice on how to use Deep Learning to optimize business performance.
We don’t just scratch the surface either – It’s not called ‘Skin-Deep’ Learning after all. We fully explain the theory from the mathematics behind the algorithms to the state-of-the-art initialization methods, plus so much more.
Theory is no good without putting it into practice, is it? That’s why we give you plenty of opportunities to put this theory to use. Implement cutting edge optimizations, get hands on with TensorFlow and even build your very own algorithm and put it through training!
Wow, that’s going to look great on your resume!
Speaking of resumes, you also get a certificate upon completion which employers can verify that you have successfully finished a prestigious 365 Careers course – and one of our best at that!
Now, I can see you’re bragging a little, but I admit you have peaked my interest. What else does your course offer that will make my resume shine?
Trust us, after this course you’ll be able to fill your resume with skills and have plenty left over to show off at the interview.
Of course, you’ll get fully acquainted with Google’ TensorFlow and NumPy, two tools essential for creating and understanding Deep Learning algorithms.
Explore layers, their building blocks and activations – sigmoid, tanh, ReLu, softmax, etc.
Understand the backpropagation process, intuitively and mathematically.
You’ll be able to spot and prevent overfitting – one of the biggest issues in machine and deep learning
Get to know the state-of-the-art initialization methods. Don’t know what initialization is? We explain that, too
Learn how to build deep neural networks using real data, implemented by real companies in the real world. TEMPLATES included!
Also, I don’t know if we’ve mentioned this, but you will have created your very own Deep Learning Algorithm after only 1 hour of the course.
It’s this hands-on experience that will really make your resume stand out
This all sounds great, but I am a little overwhelmed, I’m afraid I may not have enough experience.
We admit, you will need at least a little understanding of Python programming but nothing to worry about. We start with the basics and take you step by step toward building your very first (or second, or third etc.) Deep Learning algorithm – we program everything in Python and explain each line of code.
We do this early on and it will give you the confidence to carry on to the more complex topics we cover.
All the sophisticated concepts we teach are explained intuitively. Our beautifully animated videos and step by step approach ensures the course is a fun and engaging experience for all levels.
We want everyone to get the most out of our course, and the best way to do that is to keep our students motivated. So, we worked hard to ensure that students with varying skills are challenged without being overwhelmed. Each lecture builds upon the last and practical exercises mean that you can practice what you’ve learned before moving on to the next step.
And of course, we are available to answer any queries you have. In fact, we aim to answer any and all question within 1 business day. We don’t just chuck you in the pool then head to the bar and let you fend for yourself.
Remember, we don’t just want you to enrol – we want you to complete the course and become a Master of Deep Learning.
OK, awesome! I feel much better about my level of experience now, but we haven’t discussed yours! How do I know you can teach me to become a Master of Deep Learning?
That’s an understandable worry, but it’s one we have no problem removing.
We are 365 Careers and we’ve been creating online courses for ages. We have over 220,000 students and enjoy high ratings for all our Udemy courses. We are a team of experts who are all, at heart, teachers. We believe knowledge should be shared and not just through boring text books but in engaging and fun ways.
We are well aware how difficult it is to build your knowledge and skills in the data science field, it’s so new and has grown so fast that the education sector has struggled to keep up and offer any substantial methods of teaching these topic areas. We wanted to change things – to rock the boat – so we developed our unique teaching style, one that countless students have enjoyed and thrived with.
And between us, we think this course is one of our favourites, so if this is your first time with us, you’re in for a treat. If it’s not and you’ve taken one of our courses before, then, you’re still in for a treat!
I’ve been hurt before though, how can I be sure you won’t let me down?
Easy, with Udemy’s 30-day money back guarantee. We strive for the best and believe that our courses are the best out there. But you know what, everyone is different, and we understand that. So, we have no problem offering this guarantee, we want students who will complete and get the most out of this course. If you are one of the few who finds this course not what you wanted or expected then, get your money back. No questions, no risk, no problem.
Great, that takes a load of my shoulders. What next?
Click on the ‘Buy now’ button and take that first step toward a satisfying data science career and becoming a Master of Deep Learning.
Welcome! Course introduction
In this lesson we introduce ourselves and look into why machine learning is important and what some of its most common applications are. Starting from the origin of the term ‘machine learning’, we discuss different applications from natural language processing to self-driving cars.
The focus of this course is deep learning, and deep neural networks in particular. It is of utmost importance to us that we provide you with in-depth preparation. In this lesson we provide a quick overview of what will follow in the course.
Introduction to neural networks
To get into deep learning, one must learn the basics of machine learning. There are four major components: data, model, objective function, and the optimization algorithm. We introduce them and lay the groundwork for the section to come.
Before we begin explaining, we must cover two key concepts in machine learning: training and learning. We explore them through the example of a coffee machine.
Machine learning can be split into three major types: supervised, unsupervised, and reinforcement learning. This course focuses on supervised learning with TensorFlow; thus, we further differentiate between the two types of supervised learning: classification and regression.
The linear model is the basis of neural networks. In this lesson, we introduce xw+b as the basic linear model on which we later build the deep net.
Building on the basic linear model, we extend it to its matrix form for multiple inputs.
In this lesson, we further extend the linear model to multiple inputs and multiple outputs. This is also its most general form, which we will use later in the TensorFlow framework.
A picture is worth a thousand words. We explore a machine learning algorithm graphic of a regression and a classification through the linear model. We further make a note on why we must also employ non-linearities.
The third main building block of a deep learning algorithm is the objective function. We explain the concept and introduce the two most commonly used objective functions: the L2-norm loss and the cross-entropy loss.
In the presence of regression, we often employ the L2-norm loss. The L2-norm loss is equivalent to the OLS in statistics or the Euclidean distance in mathematics.
In the presence of classification, one of the most common objective functions is the cross-entropy loss. We look into an image classification example that helps us picture the classification problem better.
The final ingredient of a machine learning algorithm is the optimization algorithm. The most basic method is the gradient descent. We start from the 1-parameter gradient descent to get a good idea of the methodology.
Building on the 1-parameter gradient descent, we reach the n-parameter gradient descent, which is also the basic method of optimization used in machine learning.
Setting up the working environment
In this lesson we introduce the tools we will need in this course. They are the programming language Python, the most popular Python data science platform (Anaconda), the Jupyter notebook as the main place where we will program, and, finally, the machine learning framework on which we focus: TensorFlow.
We describe our choice of programming language and environment.
In this short lecture, we show how to download and install the Anaconda platform.
This lesson is about basic things you can do with Jupyter. We also show useful shortcuts for faster coding.
In this article you can find a PDF file with all Jupyter shortcuts. Enjoy!
To use the TensorFlow package, we must first install it. This is a very important lecture in which we show how that’s done.
‘pip install TensorFlow’ and ‘conda install TensorFlow’ are the two ways you can achieve that in Anaconda.
Minimal example - your first machine learning algorithm
The series of lectures in this section involve what is essentially the first machine learning algorithm many students see. It is extremely important for understanding the process. We don’t employ TensorFlow yet. This first lecture is the outline of the model.
In this lesson we generate data on which we will later train. This step is not part of the machine learning algorithm. Essentially, we will create fake data with a linear relationship. That’s the approach we have taken to prove that the machine learning methodology we showed so far is working.
An important step in the machine learning algorithm we have not discussed is the initialization of variables. This lecture tackles that problem in practice. Later in the course, we will feature a separate section on the issue.
The final part of this minimal machine learning example is the actual training of the model. That is not deep learning just yet, but the logic follows the neural networks one, which will later be unfolded into a deep net.
TensorFlow - An introduction
This lecture is an introduction to TensorFlow. We explain our choice of framework and compare TensorFlow and sklearn.
Now that we know why TensorFlow is the superior choice when it comes to neural networks, we explain the logic behind the TensorFlow framework.
TensorFlow works with tensors; thus, it requires the data to be organized in a TensorFlow-friendly way. One solution to the problem is through the NumPy file format *.npz
In TensorFlow, the model is programmed in a peculiar way. We take the same minimal example but show it in the context of the TensorFlow framework. Essentially, we expect the same result.
Like the model, the objective function and the optimization algorithm are implemented in a different way in TensorFlow.
After everything is complete, we run the code and comment on the result. Congrats! That’s your first machine learning algorithm with TensorFlow.
Going deeper: Introduction to deep neural networks
Once we are familiar with the machine learning logic and somewhat familiar with the TensorFlow framework, we are ready to carry on with deep learning. The building block of the deep neural network is the neuron layer.
Deep learning implies deep neural networks or deep nets. But what is a deep net?
To have deep learning and deep nets, we require (at least) several layers. However, they must be stacked with the help of non-linearities.
Stacking layers produces a deep net. But why do we need non-linearities?
In a machine learning context, non-linearities are also called activation functions. Henceforth, that’s how we will refer to them. In this lesson, we explain the basic rationale behind an activation function.
After looking into the most common activation functions, we notice that one of them is special. In this lecture we explore softmax activation and explain why it is used as the activation of the output layer in deep learning.
The most intuitive lesson, yet the hardest to grasp in mathematical terms. In this couple of lessons, we explore the intuition behind backpropagation, while in the next section, we look into the mathematics of it.
Now that we know what backpropagation is, let’s explore the intuition behind it through an example. We take a machine learning diagram of a neural network with a single hidden layer and backpropagate through it.
Backpropagation. A peek into the Mathematics of Optimization
The mathematics behind backpropagation must be quite interesting for anyone with a quantitative background. Here they are!
One of the most commonly asked questions in data science interviews is about overfitting. Two concepts are interrelated: underfitting and overfitting. We look into both and why each one of them yields in a suboptimal machine learning algorithm. We look into a regression example.
Once we know the difference between underfitting and overfitting, we look into a classification example.
Machine learning practitioners approach the overfitting issue by dividing the initial dataset into three parts: training, validation, and test. In this lesson we explain why this is the case.
Machine learning practitioners approach the overfitting issue by dividing the initial dataset into three parts: training, validation, and test. In this lesson we look into the test dataset.
Sometimes there is not enough data to split your dataset into training, validation, and test. N-fold cross-validation is one solution to the problem.
Training, validation, and test datasets cannot prevent overfitting on their own. They should be implemented together with an early stopping mechanism.
When you use clumsy or inappropriate methods, even the fastest computer in the world won’t be able to help you with your machine learning. As they say, the devil is in the details, and this saying is as true as it gets for initialization.
There are two simple types of initialization: random uniform and random normal initialization.
Simple initialization methods have major setbacks for a machine learning algorithm. A state-of-the-art solution to that problem is the Xavier (Glorot) initializer.
Gradient descent and learning rates
Since we’ve seen only the gradient descent, it is time to discuss improvements that will lead to enhanced machine learning algorithms. The stochastic gradient descent and batching as a whole are great improvements over the status quo.
In real life, loss functions are not as regular as we imagine them to be. Some issues are worth discussing when we use the gradient descent.
There are ways to take care of the local minima pitfalls, and momentum is one of them.
Choosing the learning rate of a machine learning algorithm is no easy task. But why choose one, when you can have a learning rate schedule?
Simply talking about the learning rate without seeing it doesn’t inform us as well as seeing a graph does. As they say, a picture is worth a thousand words.
Once, there were two leading adaptive learning rate schedules: AdaGrad and RMSprop. They are also the basis for advanced optimizers.
Adam, or the adaptive moment estimation, is the state-of-the-art optimization method. We introduce it so we can employ it later in our TensorFlow algorithms.
Adam, or the adaptive moment estimation, is the state-of-the-art optimization method. We introduce it so we can employ it later in our TensorFlow algorithms.
There are some basic preprocessing techniques, such as differences, percentages, and logarithms. They are so common, we rarely think about them.
One of the most powerful techniques for preprocessing is standardization, or feature scaling. It is probably the most commonly used preprocessing method in machine learning.
We like to use numerical data, such as exchange rates, trading volume, security prices, etc., as it is more intuitive. Often, though, we must deal with categorical data…
There are two main ways to deal with categorical data: one-hot encoding and binary encoding. We show both approaches and how to implement them.
The MNIST example
The MNIST dataset is the “Hello, world” of machine learning, and deep learning in particular. We introduce the problem and describe its use as our first deep neural network example with TensorFlow.
There are various ways to approach the MNIST. In this lecture we outline the solution, using deep learning (feed forward NNs) with TensorFlow.
We must import the TensorFlow library. We will also take advantage of the TensorFlow data provider for MNIST.
We outline our first deep neural network in TensorFlow.
We implement the relevant optimization methods, using the proper TensorFlow structure.
Whenever we do machine learning, we are interested in the prediction accuracy over the dataset. The concept is the same whether or not it is in the presence of TensorFlow.
While the MNIST is divided into training, validation, and testing, we must still set early stopping mechanisms.