Deep Learning Concepts and Applications
Deep Learning Concepts and Applications
Melanie Swan
Philosophy & Economic Theory
Purdue University
Boulder Futurists: Solid State Depot Hackspace melanie@[Link]
Boulder CO, August 12, 2017
Slides: [Link]
Melanie Swan, Technology Theorist
Philosophy and Economic Theory, Purdue
University, Indiana, USA
Founder, Institute for Blockchain Studies
Singularity University Instructor; Institute for Ethics and
Emerging Technology Affiliate Scholar; EDGE
Essayist; FQXi Advisor
Economics and Financial
Traditional Markets Background Theory Leadership
12 Aug 2017
4
Deep Learning
Conceptual Definition:
Deep learning is a computer program that can
identify what something is
Technical Definition:
Deep learning is a class of machine learning
algorithms in the form of a neural network that
uses a cascade of layers (tiers) of processing
units to extract features from data and make
predictive guesses about new data
Source: [Link]
12 Aug 2017
9
Deep Learning
What is a Neural Net?
Motivation: create an Artificial Neural Network to solve
problems the same way a human brain would
12 Aug 2017
10
Deep Learning
What is a Neural Net?
Structure: input-processing-output
Mimic neuronal signal firing structure of brain with
computational processing units
Source: [Link]
12 Aug 2017 [Link]
11
Deep Learning
What is an Artificial Neural Network?
Collection of connected units called artificial
neurons (analogous to axons in a biological brain)
Organized in layers of signaling cascades
Each neuron transmits a signal to another neuron
Neurons may have state
Represented by a number between 0 and 1
Variable parameters
Neurons may have a weight that varies as learning
proceeds, which can increase or decrease the strength of
the signal that it sends downstream
Neurons may have a threshold (bias) such that only if the
aggregate signal is below (or above) that level is the
downstream signal sent
12 Aug 2017
12
Deep Learning
Why is it called Deep Learning?
Deep: Hidden layers (cascading tiers) of processing
“Deep” networks (5+ layers) versus “shallow” (1-2 layers)
Learning: Algorithms “learn” from data by modeling
features and updating probability weights assigned to
feature nodes in testing how relevant specific features
are in determining the general type of item
12 Aug 2017
13
Deep Learning
Supervised and Unsupervised Learning
Supervised (classify
labeled data)
Unsupervised (find
patterns in unlabeled
data)
Source: [Link]
12 Aug 2017
14
Deep Learning
Early success in Supervised Learning (2011)
YouTube: user-classified data
perfect for Supervised Learning
Source: Google Brain: Le, QV, Dean, Jeff, Ng, Andrew, et al. 2012. Building high-level features using large scale unsupervised
12 Aug 2017 learning. [Link]
15
Deep Learning
2 main kinds of Deep Learning neural nets
Convolutional Neural Nets
Image recognition
Convolve: roll up to higher
levels of abstraction in feature
sets
Recurrent Neural Nets
Speech, text, audio
recognition
Recur: iterate over sequential
inputs with a memory function
LSTM (Long Short-Term
Memory) remembers
sequences and avoids
gradient vanishing
Source: Yann LeCun, CVPR 2015 keynote (Computer Vision ), "What's wrong with Deep Learning" [Link]
12 Aug 2017
16
Deep Learning
Image Recognition and Computer Vision
History
Marv Minsky, 1966 Jeff Hawkins, 2004, Hierarchical Quoc Le, 2011, Google
“summer project” Temporal Memory (HTM) Brain cat recognition
Current state of
the art - 2017
12 Aug 2017
18
Deep Learning
Why do we need Deep Learning?
A contemporary data science method to keep up
with the growth in data, older learning algorithms no
longer performing
Source: [Link]
12 Aug 2017
19
Deep Learning
Agenda
Deep Learning
Definition
Technical details
Applications
Deep Qualia: Deep Learning and the Brain
Smart Network Convergence Theory
Conclusion
12 Aug 2017
21
Deep Learning
Linear Regression
House price
Source: [Link]
12 Aug 2017
22
Deep Learning
Logistic Regression
Source: [Link]
12 Aug 2017
23
Deep Learning
Logistic Regression
Higher-order mathematical
formulation Sigmoid Function
Sigmoid function
S-shaped and bounded
Maps the whole real axis into a finite
interval (0-1)
Non-linear
Can fit probability
Can apply optimization techniques
Source: [Link]
12 Aug 2017
24
Deep Learning
Sigmoid function: Taleb
Thesis: if can map a phenomenon onto
a sigmoid curve (“convexify” it), then
can control its risk
Antifragility = convexity = risk-manageable
Fragility = concavity
Non-linearity of dose-response in
medicine, and therefore suggested
treatment optimality
Source: [Link]
12 Aug 2017
25
Deep Learning
Regression
12 Aug 2017
26
Deep Learning
Deep Learning Architecture
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
Source: [Link]
12 Aug 2017
28
Deep Learning
Example: Image recognition
1. Obtain training data set
Source: Quoc V. Le, A Tutorial on Deep Learning, Part 1: Nonlinear Classifiers and The Backpropagation Algorithm, 2015, Google
12 Aug 2017 Brain, [Link]
29
Deep Learning
Deep Learning Architecture
4. Load spreadsheet of vectors into deep learning system
Each row of spreadsheet (784-element array) is an input
784-element array
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
X X X X X
Source: [Link] MNIST dataset: [Link]
12 Aug 2017
30
Deep Learning
What happens in the Hidden Layers?
First layer learns primitive features (line, edge, tiniest
unit of sound) by finding combinations of the input vector
data that occur more frequently than by chance
Logistic regression performed and encoded at each processing
node (Y/N (0,1)), does this example have this feature?
Feeds these basic features to next layer, which trains
itself to recognize slightly more complicated features
(corner, combination of speech sounds)
Feeds features to new layers until recognizes full objects
Source: Andrew Ng
12 Aug 2017
33
Deep Learning
Example: NVIDIA Facial Recognition
First hidden layer extracts all possible low-level features
from data (lines, edges, contours); next layers abstract
into more complex features of possible relevance
Source: Nvidia
12 Aug 2017
34
Deep Learning
Deep Learning
Source: Quoc V. Le et al, Building high-level features using large scale unsupervised learning, 2011, [Link]
12 Aug 2017
35
Deep Learning
Deep Learning Architecture
X .5 X .5 X .5 X
.75
X 0 0
Backward pass to update probabilities
X .5
X .5
X .5
X X 1 0
.25
X X X X X
Source: [Link] MNIST dataset: [Link]
12 Aug 2017
37
Deep Learning
More complicated in actual use
Convolutional neural net scale-up for
number recognition
Example data: MNIST dataset
[Link]
Source: [Link]
12 Aug 2017
38
Deep Learning
Structure of a Node: Computation Graph
Edge
(input value) 3
Node
(operation) Add
Edge ??
(output value)
Edge
4
(input value)
Architecture Example 1
Mult
??
Example 2
12 Aug 2017
39
Deep Learning
Neural net unit: perceptron, neuron, node
Sigmoid function means all inputs and outputs in the
system are (0,1)
(0,1)
Oper-
ation
(0,1) (0,1)
(0,1)
Source: [Link]
12 Aug 2017
40
Deep Learning
Other parameters: weights and bias
Weight and bias are variable parameters that
get adjusted as the system iterates and learns
Values have Operation node Values have Operation node
Weights has Bias Weights has Bias
B=3 =0 B=3
W1 = (-2) W1 = (-2)
Output
=0
=0
W2 = (-2) W2 = (-2)
Source: [Link]
12 Aug 2017
41
Deep Learning
Actual: same structure, more complicated
12 Aug 2017
42
Deep Learning
Neural net: massive scale-up of nodes
Source: [Link]
12 Aug 2017
43
Deep Learning
Same Structure
12 Aug 2017
44
Deep Learning
How does the neural net actually learn?
Structural system based on cascading layers of
neurons with variable parameters: weight and bias
Vary the weights and
biases to see if a
better outcome is
obtained
Repeat until the net
correctly classifies
the data
Source: [Link]
12 Aug 2017
45
Deep Learning
Backpropagation
Problem: Inefficient to test the combinatorial
explosion of all possible parameter variations
Source: [Link]
12 Aug 2017
46
Deep Learning
Backpropagation of error
Calculate the total error
Calculate the contribution to the error at each step
going backwards
Variety of Error Calculation methods: Mean Square Error
(MSE), sum of squared errors of prediction (SSE), Cross-
Entropy (Softmax), Softplus
12 Aug 2017
47
Deep Learning
Backpropagation
Heart of Deep Learning
Backpropagation: algorithm dynamically calculates
the gradient (derivative) of the loss function with
respect to the weights in a network to find the
minimum and optimize the function from there
Algorithms optimize the performance of the network by
adjusting the weights, e.g.; in the gradient descent algorithm
Error and gradient are computed for each node
Intermediate errors transmitted backwards through the
network (backpropagation)
Objective: optimize the weights so that the neural
network can learn how to correctly map arbitrary
inputs to outputs
Source: [Link]
12 Aug 2017 [Link]
48
Deep Learning
Gradient Descent
Gradient: derivative to find the minimum of a function
Gradient descent: optimization algorithm to find the
biggest errors (minima) most quickly
Error = MSE, log loss, cross-entropy; e.g.; least correct
predictions to correctly identify data
Source: [Link]
12 Aug 2017
49
Deep Learning
Loss Function
Optimization Technique
Mathematical tool used in statistics, finance, decision theory,
Laplace
biological modeling, computational neuroscience
State as non-linear equation to optimize
Minimize loss or cost
Maximize reward, utility, profit, or fitness
Loss function links instance of an event to its cost
Accident (event) means $1,000 damage on average (cost)
5 cm height (event) confers 5% fitness advantage (reward)
Deep learning: system feedback loop
Use penalty cost for incorrect classifications to train system
CNN (classification): cross-entropy; RNN (regression): MSE
12 Aug 2017
50
Deep Learning
Overfitting
Regularization
Introduce additional information
such as a lambda parameter in the
cost function (to update the theta
parameters in the gradient descent
algorithm)
Dropout: prevent complex
adaptations on training data by
dropping out units (both hidden and
visible)
Test new datasets
12 Aug 2017
51
Deep Learning
Research Topics
Layer depth vs. height (1x9, 3x3, etc.); L1/2 slow-downs
Source: [Link]
12 Aug 2017
53
Deep Learning
Convolutional net: Image Enhancement
Google DeepDream: Convolutional neural network
enhances (potential) patterns in images; deliberately
over-processing images
12 Aug 2017
55
Deep Learning
Deep Learning frameworks and libraries
Source: [Link]
12 Aug 2017 [Link]#[Link]-ifwsb
56
Deep Learning
What is TensorFlow?
Google’s open-source machine learning library
“Tensor” = multidimensional arrays used in NN operations
Source: [Link]
12 Aug 2017 the-future-of-computing-looks-like-1326915
58
Deep Learning
USB and Browser-based Machine Learning
Intel: Movidius Visual Processing
Unit (VPU): USB ML for IOT
Security cameras, industrial
equipment, robots, drones
Apple: ML acquisition Turi (Dato)
Browser-based Deep Learning
ConvNetJS; TensorFire
Javascript library to run Deep
Learning (Neural Networks) in a
browser
Smart Network in a browser
JavaScript Deep Learning
Blockchain EtherWallets
Source: Yann LeCun, CVPR 2015 keynote (Computer Vision ), "What's wrong with Deep Learning" [Link]
12 Aug 2017
62
Deep Learning
Tumor Image Recognition
Computer-Aided
Diagnosis with
Deep Learning
Architecture
Breast tissue
lesions in images
and pulmonary
nodules in CT
Scans
Source: [Link]
12 Aug 2017
63
Deep Learning
Melanoma Image Recognition
Source: [Link]
12 Aug 2017
64
Deep Learning
DIY Image Recognition: use Contrast
Apple or Orange? Melanoma risk or healthy skin?
Source: [Link]
12 Aug 2017
65
Deep Learning
Deep Learning and Genomics
Large classes of hypothesized but unknown correlations
Genotype-phenotype disease linkage unknown
Computer-identifiable patterns in genomic data
CNN: genome symmetries; RNN: textual analysis
Source: [Link]
12 Aug 2017
66
Deep Learning
Deep Learning and the Brain
12 Aug 2017
67
Deep Learning
Deep Qualia machine? General purpose AI
Mutual inspiration of neurological and computing research
12 Aug 2017
68
Deep Learning
Deep Qualia machine?
Visual cortex is hierarchical with intermediate layers
The ventral (recognition) pathway in the visual cortex has multiple
stages: Retina - LGN - V1 - V2 - V4 - PIT – AIT
Human brain simulation projects
Swiss Blue Brain project, European Human Brain Project
Source: [Link]
12 Aug 2017
70
Deep Learning
Agenda
Deep Learning
Definition
Technical details
Applications
Deep Qualia: Deep Learning and the Brain
Smart Network Convergence Theory
Conclusion
12 Aug 2017
72
Deep Learning
Smart Network Convergence Theory
12 Aug 2017
73
Deep Learning
Smart Network Convergence Theory
Two Fundamental Eras of Network Computing
Source: [Link]
12 Aug 2017
75
Deep Learning
Blockchain Deep Learning nets
Provide increasingly sophisticated automated network
computational infrastructure
Make predictive guesses of reality states of the world
Predictive inference (deep learning) and cryptographic nonce-
guesses (blockchain)
Instantiate decentralization
Hierarchical models do not scale
12 Aug 2017
76
Deep Learning
Next Phase
12 Aug 2017
77
Deep Learning
Example: Autonomous Driving
Requires the smart network functionality
of deep learning and blockchain
12 Aug 2017
78
Deep Learning
The Very Small
Blockchain Deep Learning nets in Cells
Medical nanorobotics for cell repair
Deep Learning: identify what things are
(diagnosis)
Blockchain: secure automation technology
Bio-cryptoeconomics: secure automation
of medical nanorobotics for cell repair
Medical nanorobotics as coming-onboard
repair platform for the human body
High number of agents and “transactions”
Identification and automation is obvious
Sources: Swan, M. Blockchain Thinking: The Brain as a DAC (Decentralized Autonomous Corporation). Technology and Society Magazine,
12 Aug 2017 IEEE 2015; 34(4): 41-52 , [Link]
79
Deep Learning
The Very Large
Blockchain Deep Learning nets in Space
Automated space
construction bots/agents
Deep Learning: identify
what things are
(classification)
Blockchain: secure
automation technology
Applications: asteroid
mining, terraforming,
radiation-monitoring,
space-based solar power,
debris tracking net
12 Aug 2017
80
Deep Learning
Agenda
Deep Learning
Definition
Technical details
Applications
Deep Qualia: Deep Learning and the Brain
Smart Network Convergence Theory
Conclusion
12 Aug 2017
82
Deep Learning
Human-machine collaboration
Team-members excel at different things
Differently-abled agents in society
12 Aug 2017
83
Deep Learning
Conceptual Definition:
Deep learning is a computer program that can
identify what something is
Technical Definition:
Deep learning is a class of machine learning
algorithms in the form of a neural network that
uses a cascade of layers (tiers) of processing
units to extract features from data and make
predictive guesses about new data
12 Aug 2017
86
Deep Learning
Conclusion
Next-generation global infrastructure:
Deep Learning Blockchain Networks
merging deep learning systems and
blockchain technology
12 Aug 2017
87
Deep Learning
Resources
Neural Networks and Deep Learning, Michael Nielsen,
[Link]
Deep Learning, Ian Goodfellow, Yoshua Bengio, Aaron
Courville, [Link] learning and deep neural nets
Machine Learning Guide podcast, Tyler Renelle,
[Link]
notMNIST dataset [Link]
Metacademy; [Link]; [Link]
[Link]
Source: Yann LeCun, CVPR 2015 keynote (Computer Vision ), "What's wrong with Deep Learning" [Link]
12 Aug 2017
91
Deep Learning