Deep Learning Intro

This is the introduction to deep learning

Let us start with a simple examples

Loading Libraries

In [7]:
# Numerical Computations
import numpy as np

# For Deep Learning 
import keras

# Visualisation 
import matplotlib.pyplot as plt
%matplotlib inline
Using TensorFlow backend.

Problem: A Noisy Function

$$ Z = 2X^2 - 3Y^2 + 5 + \epsilon $$

In [16]:
x = np.arange(start = -1, stop = 1, step = 0.01)
y = np.arange(start = -1, stop = 1, step = 0.01)
In [13]:
len(x), len(y)
Out[13]:
(200, 200)
In [21]:
X,Y = np.meshgrid(x,y)
c = np.ones((200, 200))
e = np.random.rand(200,200)*0.1
In [22]:
Z = 2*X*X - 3*Y*Y + 5*c + e
In [28]:
#!wget http://bit.do/dl-vis
In [29]:
#!mv dl-vis vis.py
In [30]:
#!pip install altair
In [31]:
import vis
In [32]:
vis.plot3d(X,Y,Z)

Deep Learning 101

Step 1: Get the input and output data

In [ ]:
input_xy = np.c_[X.reshape()]