Deep Learning with Tensorflow: Part 1 — theory and setup | by Matteo Kofler | Towards Data Science

Hi everyone, welcome to this blog series about Tensorflow. In part 1, I’ll give you some basic information about the framework and I’ll show you how to set up your coding environment on Windows 10. Let’s dive into it.
TensorFlow is a framework created by Google for creating Deep Learning models. Deep Learning is a category of machine learning models (=algorithms) that use multi-layer neural networks.
Machine Learning has enabled us to build complex applications with great accuracy. Whether it has to do with images, videos, text or even audio, Machine Learning can solve problems from a wide range. Tensorflow can be used to achieve all of these applications.
The reason for its popularity is the ease with which developers can build and deploy applications. The GitHub projects which we’ll look closer at due the next parts are very powerful but also so easy to work with. Moreover, Tensorflow was created with processing power limitations in mind. The library can be ran on computers of all kinds, even on smartphones (yes, even on that overpriced thing with half an apple on it). I can guarantee you, working on a Intel Core i3 with 8 GB of RAM, you won’t have performance issues.
The human brain consists of billions of neurons which are interconnected by synapses. If “enough” synaptic inputs to the neuron fires, then the neuron will also fire. This process is called thinking. To replicate that process on computers, we need machine learning and neural networks. In case you aren’t that settled on this terms, I’ll explain them.
Quite simply, machine learning allows computers to ‘learn’. Traditionally, we always got computers to do things by providing a strict set of instructions. Machine Learning uses a very different approach. Instead of giving the computer a set of instructions on how to do something, we give it instructions on how to learn to do something. For example: think of a system that can classify pictures of animals as ‘cat’, ‘dog’, or ‘mouse’. Instead of manually finding unique characteristics from images of those animals and then coding it up, machine learning takes in images of those animals and finds characteristics and differences by itself. This process of teaching the computer is referred to as training.
Deep learning is a Technique for implementing Machine Learning. It uses neural networks to learn, sometimes, using decision trees may also be referred to as deep learning, but for the most part deep learning involves the use of neural networks.
So, what is a neural network? Here’s an analogy: imagine a neural network as a series of doors one after another and think of yourself as the ‘input’ to the neural network. Every time you open a door, you become a different person. By the time you open the last door, you have become a very different person. When you exit through the last door, you become the ‘output’ of the neural network. Each door, in this case, represents a layer. A neural network, therefore, is a collection of layers that transform the input in some way to produce an output.
If you want to know more, give the following article a try:https://medium.com/towards-data-science/tensorflow-for-absolute-beginners-28c1544fb0d6
This manual is meant for Tensorflow 1.2.1 with Python 3.6. Before following it, you might also want to take a look at the official installation guide.
Tensorflow programs are written in Python, which you can download at https://www.python.org/downloads/
You can choose between Python 3 and Python 2, but I would highly recommend you to install a version newer as 3.5, simply because these versions already come with a integrated PIP-Package. Otherwise, you have to install that as well.
The next step is to install Python. Open a command line as administrator(!), and write the following line:
pip3 install --upgrade tensorflow
If you want to test the installation, write this:
python >>> import tensorflow as tf>>> hello = tf.constant('Hello, Tensorflow')>>> sess = tf.Session()>>> print(sess.run(hello))
You should see a “Hello, Tensorflow” output now.
Congratulations! You just learned the theoretical basics of Tensorflow and set up everything to dig in deeper in the matter. The next part will be about image processing and recognition with Inception. So stay tuned till next time!
__
Link to Part 2: https://medium.com/@m_ko/deep-learning-with-tensorflow-part-2-image-classification-58fcdffa7b84