SlideShare a Scribd company logo
1 of 22
Download to read offline
Getting Started with
DeepLearning using Scala
@OE_uia
Who I am:
Taisuke Oe (TW: @OE_uia, GITHUB: taisukeoe)
● Android App Developer in Scala
● ND4S creator
● ND4J contributor
Agenda / Disclaimer
What I’m going to talk:
- What is Deep Learning?
- What is Neural Network?
- How Neural Netowork works over training.
- DeepLearning4j architecture
What I’m NOT going to talk (in detail):
- Type of Neural Network
- Hyper parameter and its tuning
今日は深層学習とニューラルネットワークの基礎、 DeepLearning4jのアーキテクチャについて触れます
What is Machine Learning?
"Field of study that gives computers the ability to
learn without being explicitly programmed."
Arthur Samuel (1959)
機械学習とは、明示的にプログラムされなくてもコンピューターに学ぶ能力を付与する研究分野のこと。
What is Deep Learning?
- A category of Machine Learning,
especially for images, text, audio, etc.
- Accurate and reasonably fast.
- Train “Neural Networks” with updating its parameters
over iterations.
- Neural Network has a layered structure, and learns
features in each layer
深層学習は、ニューラルネットワークを使う機械学習の一分野で、画像、文章、音などを対象とする。
DeepLearning4j Archtecture
Canova DeepLearning4j
ND4J
DeepLearning4jの主な3つのモジュール。 DeepLearning4j, ND4J, Canova。
DeepLearning4j Archtecture
Canova DeepLearning4j
ND4J
General Vectorization
Library.
Vectorize raw data to
INDArray.
DeepLearning Framework.
Construct Neural Network
based on configuration.
N-dimensional Array
calculation Library.
DeepLearning4jが設定からニューラルネットを構築。 Canovaは生データをベクター化。 ND4Jはそれらの計算基盤。
DeepLearning4j Archtecture
Canova DeepLearning4j
Images
Text
Audio
ND4J
Canovaは、画像やテキスト、オーディオなどの生データを解釈する。
DeepLearning4j Archtecture
Canova DeepLearning4j
Images
Text
Audio
INDArray
ND4J
disclaimer: it’s a simplified example very much.
例えば、Canovaが生の画像を計算しやすいように N次元行列(この例では2次元)に変換する。
DeepLearning4j Archtecture
Canova DeepLearning4j
Images
Text
Audio
INDArray
ND4J
INDArray
ND4S
disclaimer: it’s a simplified example very much.
場合によっては、ND4SでN次元行列を計算ないしは学習しやすいように変換する。
DEMO
https://github.com/taisukeoe/matsuri-mnist-example
DEMO in REPL of:
https://github.com/deeplearning4j/nd4s
DeepLearning4j Archtecture
Canova DeepLearning4j
ND4J
N dimensional
Sample Data
disclaimer: it’s a simplified example very much.
DeepLearning4jによって構築されたニューラルネットが N次元行列の入力を受け取り、結果を表す N次元行列を返す
DeepLearning4j Archtecture
Canova DeepLearning4j
ND4J
N dimensional
Sample Data
disclaimer: it’s a simplified example very much.
この例では出力された行列の各列が各クラスに分類される確率を表す。 2が90%、3が10%という具合。
How DeepLearning works
N dimensional
Sample Data
Parameters in Neural Network (in this picture, Multi
Layer Perceptron) got updated over iterations
# of samples
トレーニングの際。サンプルをミニバッチごとに分けて入力させる。ニューラルネット内の状態が更新され続ける。
How DeepLearning works
N dimensional
Sample Data
# of samples
Neural Network has
states which are
updated over iteration.
DataSet has states
like a iterator.
Spit out samples in
each mini-batch.
トレーニングの際。サンプルをミニバッチごとに分けて入力させる。ニューラルネット内の状態が更新され続ける。
How DeepLearning works
N dimensional
Sample Data
# of samples
Neural Network has
states which are
updated over iteration.
Go to the detail:
How neuron unit
behaves:
トレーニングを通じて更新される、ニューラルネット内の「状態」の中身を見ていきましょう。
How Neuron works
構成単位ニューロン。各 (x:入力)に(w:重み)を乗じて(b:バイアス)を足したものを、活性化関数 fに渡して出力計算。
How Neuron works
mutable!
mutable!
immutable!
(w 重み)と(b バイアス)は変数で、トレーニングごとに更新される。 活性化関数 fは不変。
How Neural Net work in each layer
(全結合な)ニューラルネットの各層は、重み行列、バイアス行列、活性化関数からなる関数で表現される
Further information:
- Type of Neural Network
- Convolutional Neural Network
- Recurrent Neural Network
- etc
- Backpropagation
- Loss Function
- Learning rate
- Other hyper parameters
深層学習 http://www.amazon.co.jp/dp/B018K6C99A/
Coursera https://www.coursera.org/course/neuralnets
(w:重み)と(b:バイアス)を更新する方法は、誤差逆伝搬法と損失関数、学習係数などで決定される。詳しくは書籍など
How to improve results?
- Choose appropriate Neural Network(s)
- Tune hyper parameters of Neural Network(s).
- Pre-process input data to be efficiently trained.
学習結果を改善させるには?ニューラルネットワークのタイプを選ぶ、超パラメータを調整、入力データのプリプロセシン
Summary
- Deep Learning is a category of Machine Learning, which
is trained by Neural Networks with three or more layers.
- Neural Network maps input feature matrix to output
matrix which stands for possibilities of each class in
classification purpose.
- DeepLearning4j: Deep Learning framework in JVM
- Nd4j: N-dimensional array calculation library
- Canova: General vectorization library
- Nd4s: NumPy-like + Scala-like API for ND4J
深層学習は、3層以上からなるニューラルネットワークで行う機械学習のこと。N次元行列の生データを加工するなどして、パフォーマンスを上げる。

More Related Content

What's hot

2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで
2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで
2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep LearningまでHokuto Kagaya
 
LSTM (Long short-term memory) 概要
LSTM (Long short-term memory) 概要LSTM (Long short-term memory) 概要
LSTM (Long short-term memory) 概要Kenji Urai
 
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26Takashi Abe
 
Tutorial-DeepLearning-PCSJ-IMPS2016
Tutorial-DeepLearning-PCSJ-IMPS2016Tutorial-DeepLearning-PCSJ-IMPS2016
Tutorial-DeepLearning-PCSJ-IMPS2016Takayoshi Yamashita
 
Introduction to Deep Compression
Introduction to Deep CompressionIntroduction to Deep Compression
Introduction to Deep CompressionWEBFARMER. ltd.
 
[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions
[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions
[DL輪読会]Xception: Deep Learning with Depthwise Separable ConvolutionsDeep Learning JP
 
[ICLR2016] 採録論文の個人的まとめ
[ICLR2016] 採録論文の個人的まとめ[ICLR2016] 採録論文の個人的まとめ
[ICLR2016] 採録論文の個人的まとめYusuke Iwasawa
 
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)Etsuji Nakai
 
Deep Learningの技術と未来
Deep Learningの技術と未来Deep Learningの技術と未来
Deep Learningの技術と未来Seiya Tokui
 
輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions
輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions
輪読資料 Xception: Deep Learning with Depthwise Separable ConvolutionsKotaro Asami
 
Differentiable neural conputers
Differentiable neural conputersDifferentiable neural conputers
Differentiable neural conputersnaoto moriyama
 
ICLR2020読み会 (neural-tangents)
ICLR2020読み会 (neural-tangents)ICLR2020読み会 (neural-tangents)
ICLR2020読み会 (neural-tangents)RyuichiKanoh
 
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介KCS Keio Computer Society
 
はじめての人のためのDeep Learning
はじめての人のためのDeep Learningはじめての人のためのDeep Learning
はじめての人のためのDeep LearningTadaichiro Nakano
 
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7Kotaro Nakayama
 
ディープラーニングゼミ TensorFlowで学ぶ理論と実践
ディープラーニングゼミ TensorFlowで学ぶ理論と実践ディープラーニングゼミ TensorFlowで学ぶ理論と実践
ディープラーニングゼミ TensorFlowで学ぶ理論と実践Yota Ishida
 
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化marsee101
 

What's hot (20)

2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで
2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで
2014/5/29 東大相澤山崎研勉強会:パターン認識とニューラルネットワーク,Deep Learningまで
 
LSTM (Long short-term memory) 概要
LSTM (Long short-term memory) 概要LSTM (Long short-term memory) 概要
LSTM (Long short-term memory) 概要
 
MIRU2014 tutorial deeplearning
MIRU2014 tutorial deeplearningMIRU2014 tutorial deeplearning
MIRU2014 tutorial deeplearning
 
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26
多層NNの教師なし学習 コンピュータビジョン勉強会@関東 2014/5/26
 
Life with jupyter
Life with jupyterLife with jupyter
Life with jupyter
 
Tutorial-DeepLearning-PCSJ-IMPS2016
Tutorial-DeepLearning-PCSJ-IMPS2016Tutorial-DeepLearning-PCSJ-IMPS2016
Tutorial-DeepLearning-PCSJ-IMPS2016
 
Introduction to Deep Compression
Introduction to Deep CompressionIntroduction to Deep Compression
Introduction to Deep Compression
 
[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions
[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions
[DL輪読会]Xception: Deep Learning with Depthwise Separable Convolutions
 
[ICLR2016] 採録論文の個人的まとめ
[ICLR2016] 採録論文の個人的まとめ[ICLR2016] 採録論文の個人的まとめ
[ICLR2016] 採録論文の個人的まとめ
 
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)
「TensorFlow Tutorialの数学的背景」 クイックツアー(パート1)
 
Deep Learningの技術と未来
Deep Learningの技術と未来Deep Learningの技術と未来
Deep Learningの技術と未来
 
輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions
輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions
輪読資料 Xception: Deep Learning with Depthwise Separable Convolutions
 
Differentiable neural conputers
Differentiable neural conputersDifferentiable neural conputers
Differentiable neural conputers
 
ICLR2020読み会 (neural-tangents)
ICLR2020読み会 (neural-tangents)ICLR2020読み会 (neural-tangents)
ICLR2020読み会 (neural-tangents)
 
20150414seminar
20150414seminar20150414seminar
20150414seminar
 
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介
U-Net: Convolutional Networks for Biomedical Image Segmentationの紹介
 
はじめての人のためのDeep Learning
はじめての人のためのDeep Learningはじめての人のためのDeep Learning
はじめての人のためのDeep Learning
 
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7
JSAI's AI Tool Introduction - Deep Learning, Pylearn2 and Torch7
 
ディープラーニングゼミ TensorFlowで学ぶ理論と実践
ディープラーニングゼミ TensorFlowで学ぶ理論と実践ディープラーニングゼミ TensorFlowで学ぶ理論と実践
ディープラーニングゼミ TensorFlowで学ぶ理論と実践
 
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化
「ゼロから作るDeep learning」の畳み込みニューラルネットワークのハードウェア化
 

Viewers also liked

TensorFrames: Google Tensorflow on Apache Spark
TensorFrames: Google Tensorflow on Apache SparkTensorFrames: Google Tensorflow on Apache Spark
TensorFrames: Google Tensorflow on Apache SparkDatabricks
 
JavaOne 2016 Java SE Feedback #jjug #j1jp
JavaOne 2016 Java SE Feedback #jjug #j1jpJavaOne 2016 Java SE Feedback #jjug #j1jp
JavaOne 2016 Java SE Feedback #jjug #j1jpYuji Kubota
 
Learning from "Effective Scala"
Learning from "Effective Scala"Learning from "Effective Scala"
Learning from "Effective Scala"Kazuhiro Sera
 
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.GeeksLab Odessa
 
Distributed machine learning 101 using apache spark from the browser
Distributed machine learning 101 using apache spark from the browserDistributed machine learning 101 using apache spark from the browser
Distributed machine learning 101 using apache spark from the browserAndy Petrella
 
Brief introduction to Distributed Deep Learning
Brief introduction to Distributed Deep LearningBrief introduction to Distributed Deep Learning
Brief introduction to Distributed Deep LearningAdam Gibson
 
Practical Predictive Modeling in Python
Practical Predictive Modeling in PythonPractical Predictive Modeling in Python
Practical Predictive Modeling in PythonRobert Dempsey
 
Scala for Machine Learning
Scala for Machine LearningScala for Machine Learning
Scala for Machine LearningPatrick Nicolas
 
Scalable and Flexible Machine Learning With Scala @ LinkedIn
Scalable and Flexible Machine Learning With Scala @ LinkedInScalable and Flexible Machine Learning With Scala @ LinkedIn
Scalable and Flexible Machine Learning With Scala @ LinkedInVitaly Gordon
 
Using Deep Learning for Recommendation
Using Deep Learning for RecommendationUsing Deep Learning for Recommendation
Using Deep Learning for RecommendationEduardo Gonzalez
 
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SF
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SFH2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SF
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SFSri Ambati
 
Recurrent nets and sensors
Recurrent nets and sensorsRecurrent nets and sensors
Recurrent nets and sensorsAdam Gibson
 
How to ensure Presto scalability 
in multi use case
How to ensure Presto scalability 
in multi use case How to ensure Presto scalability 
in multi use case
How to ensure Presto scalability 
in multi use case Kai Sasaki
 
Scala Refactoring for Fun and Profit (Japanese subtitles)
Scala Refactoring for Fun and Profit (Japanese subtitles)Scala Refactoring for Fun and Profit (Japanese subtitles)
Scala Refactoring for Fun and Profit (Japanese subtitles)Tomer Gabel
 
Functional Programming For All - Scala Matsuri 2016
Functional Programming For All - Scala Matsuri 2016Functional Programming For All - Scala Matsuri 2016
Functional Programming For All - Scala Matsuri 2016Zachary Abbott
 

Viewers also liked (20)

Thinking in Cats
Thinking in CatsThinking in Cats
Thinking in Cats
 
TensorFrames: Google Tensorflow on Apache Spark
TensorFrames: Google Tensorflow on Apache SparkTensorFrames: Google Tensorflow on Apache Spark
TensorFrames: Google Tensorflow on Apache Spark
 
JavaOne 2016 Java SE Feedback #jjug #j1jp
JavaOne 2016 Java SE Feedback #jjug #j1jpJavaOne 2016 Java SE Feedback #jjug #j1jp
JavaOne 2016 Java SE Feedback #jjug #j1jp
 
Scala-Ls1
Scala-Ls1Scala-Ls1
Scala-Ls1
 
Learning from "Effective Scala"
Learning from "Effective Scala"Learning from "Effective Scala"
Learning from "Effective Scala"
 
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.
Java/Scala Lab 2016. Александр Конопко: Машинное обучение в Spark.
 
Distributed machine learning 101 using apache spark from the browser
Distributed machine learning 101 using apache spark from the browserDistributed machine learning 101 using apache spark from the browser
Distributed machine learning 101 using apache spark from the browser
 
Brief introduction to Distributed Deep Learning
Brief introduction to Distributed Deep LearningBrief introduction to Distributed Deep Learning
Brief introduction to Distributed Deep Learning
 
Practical Predictive Modeling in Python
Practical Predictive Modeling in PythonPractical Predictive Modeling in Python
Practical Predictive Modeling in Python
 
Scala for Machine Learning
Scala for Machine LearningScala for Machine Learning
Scala for Machine Learning
 
Scalable and Flexible Machine Learning With Scala @ LinkedIn
Scalable and Flexible Machine Learning With Scala @ LinkedInScalable and Flexible Machine Learning With Scala @ LinkedIn
Scalable and Flexible Machine Learning With Scala @ LinkedIn
 
Using Deep Learning for Recommendation
Using Deep Learning for RecommendationUsing Deep Learning for Recommendation
Using Deep Learning for Recommendation
 
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SF
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SFH2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SF
H2O Machine Learning and Kalman Filters for Machine Prognostics - Galvanize SF
 
Dependency injection
Dependency injectionDependency injection
Dependency injection
 
ScalaMatsuri 2016
ScalaMatsuri 2016ScalaMatsuri 2016
ScalaMatsuri 2016
 
Recurrent nets and sensors
Recurrent nets and sensorsRecurrent nets and sensors
Recurrent nets and sensors
 
Hubba Deep Learning
Hubba Deep LearningHubba Deep Learning
Hubba Deep Learning
 
How to ensure Presto scalability 
in multi use case
How to ensure Presto scalability 
in multi use case How to ensure Presto scalability 
in multi use case
How to ensure Presto scalability 
in multi use case
 
Scala Refactoring for Fun and Profit (Japanese subtitles)
Scala Refactoring for Fun and Profit (Japanese subtitles)Scala Refactoring for Fun and Profit (Japanese subtitles)
Scala Refactoring for Fun and Profit (Japanese subtitles)
 
Functional Programming For All - Scala Matsuri 2016
Functional Programming For All - Scala Matsuri 2016Functional Programming For All - Scala Matsuri 2016
Functional Programming For All - Scala Matsuri 2016
 

Similar to Getting Started with Deep Learning using Scala

ae-3. ディープラーニングの基礎
ae-3. ディープラーニングの基礎ae-3. ディープラーニングの基礎
ae-3. ディープラーニングの基礎kunihikokaneko1
 
Generative deeplearning #02
Generative deeplearning #02Generative deeplearning #02
Generative deeplearning #02逸人 米田
 
Deep learningの概要とドメインモデルの変遷
Deep learningの概要とドメインモデルの変遷Deep learningの概要とドメインモデルの変遷
Deep learningの概要とドメインモデルの変遷Taiga Nomi
 
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しようC# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しようFujio Kojima
 
PythonによるDeep Learningの実装
PythonによるDeep Learningの実装PythonによるDeep Learningの実装
PythonによるDeep Learningの実装Shinya Akiba
 
いきなりAi tensor flow gpuによる画像分類と生成
いきなりAi tensor flow gpuによる画像分類と生成いきなりAi tensor flow gpuによる画像分類と生成
いきなりAi tensor flow gpuによる画像分類と生成Yoshi Sakai
 
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用de:code 2017
 
20180729 Preferred Networksの機械学習クラスタを支える技術
20180729 Preferred Networksの機械学習クラスタを支える技術20180729 Preferred Networksの機械学習クラスタを支える技術
20180729 Preferred Networksの機械学習クラスタを支える技術Preferred Networks
 
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...de:code 2017
 
Deep Learningと画像認識   ~歴史・理論・実践~
Deep Learningと画像認識 ~歴史・理論・実践~Deep Learningと画像認識 ~歴史・理論・実践~
Deep Learningと画像認識   ~歴史・理論・実践~nlab_utokyo
 
「機械学習とは?」から始める Deep learning実践入門
「機械学習とは?」から始める Deep learning実践入門「機械学習とは?」から始める Deep learning実践入門
「機械学習とは?」から始める Deep learning実践入門Hideto Masuoka
 
DeNAにおける機械学習・深層学習活用
DeNAにおける機械学習・深層学習活用DeNAにおける機械学習・深層学習活用
DeNAにおける機械学習・深層学習活用Kazuki Fujikawa
 
Deep Learning技術の最近の動向とPreferred Networksの取り組み
Deep Learning技術の最近の動向とPreferred Networksの取り組みDeep Learning技術の最近の動向とPreferred Networksの取り組み
Deep Learning技術の最近の動向とPreferred Networksの取り組みKenta Oono
 
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化RCCSRENKEI
 
本の紹介「絵で見てわかるITインフラの仕組み」
本の紹介「絵で見てわかるITインフラの仕組み」本の紹介「絵で見てわかるITインフラの仕組み」
本の紹介「絵で見てわかるITインフラの仕組み」Takahiko Sato
 
Image net classification with Deep Convolutional Neural Networks
Image net classification with Deep Convolutional Neural NetworksImage net classification with Deep Convolutional Neural Networks
Image net classification with Deep Convolutional Neural NetworksShingo Horiuchi
 
Twitterのリアルタイム分散処理システム「Storm」入門
Twitterのリアルタイム分散処理システム「Storm」入門Twitterのリアルタイム分散処理システム「Storm」入門
Twitterのリアルタイム分散処理システム「Storm」入門AdvancedTechNight
 

Similar to Getting Started with Deep Learning using Scala (20)

ae-3. ディープラーニングの基礎
ae-3. ディープラーニングの基礎ae-3. ディープラーニングの基礎
ae-3. ディープラーニングの基礎
 
深層学習②
深層学習②深層学習②
深層学習②
 
Generative deeplearning #02
Generative deeplearning #02Generative deeplearning #02
Generative deeplearning #02
 
Efficient Det
Efficient DetEfficient Det
Efficient Det
 
Deep learningの概要とドメインモデルの変遷
Deep learningの概要とドメインモデルの変遷Deep learningの概要とドメインモデルの変遷
Deep learningの概要とドメインモデルの変遷
 
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しようC# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
 
PythonによるDeep Learningの実装
PythonによるDeep Learningの実装PythonによるDeep Learningの実装
PythonによるDeep Learningの実装
 
いきなりAi tensor flow gpuによる画像分類と生成
いきなりAi tensor flow gpuによる画像分類と生成いきなりAi tensor flow gpuによる画像分類と生成
いきなりAi tensor flow gpuによる画像分類と生成
 
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用
[AI08] 深層学習フレームワーク Chainer × Microsoft で広がる応用
 
20180729 Preferred Networksの機械学習クラスタを支える技術
20180729 Preferred Networksの機械学習クラスタを支える技術20180729 Preferred Networksの機械学習クラスタを支える技術
20180729 Preferred Networksの機械学習クラスタを支える技術
 
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...
[AI05] 目指せ、最先端 AI 技術の実活用!Deep Learning フレームワーク 「Microsoft Cognitive Toolkit 」...
 
Deep Learningと画像認識   ~歴史・理論・実践~
Deep Learningと画像認識 ~歴史・理論・実践~Deep Learningと画像認識 ~歴史・理論・実践~
Deep Learningと画像認識   ~歴史・理論・実践~
 
「機械学習とは?」から始める Deep learning実践入門
「機械学習とは?」から始める Deep learning実践入門「機械学習とは?」から始める Deep learning実践入門
「機械学習とは?」から始める Deep learning実践入門
 
DeNAにおける機械学習・深層学習活用
DeNAにおける機械学習・深層学習活用DeNAにおける機械学習・深層学習活用
DeNAにおける機械学習・深層学習活用
 
Deep Learning技術の最近の動向とPreferred Networksの取り組み
Deep Learning技術の最近の動向とPreferred Networksの取り組みDeep Learning技術の最近の動向とPreferred Networksの取り組み
Deep Learning技術の最近の動向とPreferred Networksの取り組み
 
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化
DEEP LEARNING、トレーニング・インファレンスのGPUによる高速化
 
本の紹介「絵で見てわかるITインフラの仕組み」
本の紹介「絵で見てわかるITインフラの仕組み」本の紹介「絵で見てわかるITインフラの仕組み」
本の紹介「絵で見てわかるITインフラの仕組み」
 
Image net classification with Deep Convolutional Neural Networks
Image net classification with Deep Convolutional Neural NetworksImage net classification with Deep Convolutional Neural Networks
Image net classification with Deep Convolutional Neural Networks
 
Cs中間報告
Cs中間報告Cs中間報告
Cs中間報告
 
Twitterのリアルタイム分散処理システム「Storm」入門
Twitterのリアルタイム分散処理システム「Storm」入門Twitterのリアルタイム分散処理システム「Storm」入門
Twitterのリアルタイム分散処理システム「Storm」入門
 

More from Taisuke Oe

Neural Network as a function
Neural Network as a functionNeural Network as a function
Neural Network as a functionTaisuke Oe
 
Composable Callbacks & Listeners
Composable Callbacks & ListenersComposable Callbacks & Listeners
Composable Callbacks & ListenersTaisuke Oe
 
ScalaDays 2015 SF report #rpscala
ScalaDays 2015 SF report #rpscalaScalaDays 2015 SF report #rpscala
ScalaDays 2015 SF report #rpscalaTaisuke Oe
 
Scala2.10.x bytecode problems in Android
Scala2.10.x bytecode problems in AndroidScala2.10.x bytecode problems in Android
Scala2.10.x bytecode problems in AndroidTaisuke Oe
 
2012 09-26-scala
2012 09-26-scala2012 09-26-scala
2012 09-26-scalaTaisuke Oe
 
AmazonElasticBeanstalk
AmazonElasticBeanstalkAmazonElasticBeanstalk
AmazonElasticBeanstalkTaisuke Oe
 
Smartphone security at ZenCoworking
Smartphone security at ZenCoworkingSmartphone security at ZenCoworking
Smartphone security at ZenCoworkingTaisuke Oe
 
Rememb ar 0117
Rememb ar 0117Rememb ar 0117
Rememb ar 0117Taisuke Oe
 
Share english communication tips jp
Share english communication tips jpShare english communication tips jp
Share english communication tips jpTaisuke Oe
 
Share english communication tips jp
Share english communication tips jpShare english communication tips jp
Share english communication tips jpTaisuke Oe
 

More from Taisuke Oe (10)

Neural Network as a function
Neural Network as a functionNeural Network as a function
Neural Network as a function
 
Composable Callbacks & Listeners
Composable Callbacks & ListenersComposable Callbacks & Listeners
Composable Callbacks & Listeners
 
ScalaDays 2015 SF report #rpscala
ScalaDays 2015 SF report #rpscalaScalaDays 2015 SF report #rpscala
ScalaDays 2015 SF report #rpscala
 
Scala2.10.x bytecode problems in Android
Scala2.10.x bytecode problems in AndroidScala2.10.x bytecode problems in Android
Scala2.10.x bytecode problems in Android
 
2012 09-26-scala
2012 09-26-scala2012 09-26-scala
2012 09-26-scala
 
AmazonElasticBeanstalk
AmazonElasticBeanstalkAmazonElasticBeanstalk
AmazonElasticBeanstalk
 
Smartphone security at ZenCoworking
Smartphone security at ZenCoworkingSmartphone security at ZenCoworking
Smartphone security at ZenCoworking
 
Rememb ar 0117
Rememb ar 0117Rememb ar 0117
Rememb ar 0117
 
Share english communication tips jp
Share english communication tips jpShare english communication tips jp
Share english communication tips jp
 
Share english communication tips jp
Share english communication tips jpShare english communication tips jp
Share english communication tips jp
 

Getting Started with Deep Learning using Scala

  • 1. Getting Started with DeepLearning using Scala @OE_uia
  • 2. Who I am: Taisuke Oe (TW: @OE_uia, GITHUB: taisukeoe) ● Android App Developer in Scala ● ND4S creator ● ND4J contributor
  • 3. Agenda / Disclaimer What I’m going to talk: - What is Deep Learning? - What is Neural Network? - How Neural Netowork works over training. - DeepLearning4j architecture What I’m NOT going to talk (in detail): - Type of Neural Network - Hyper parameter and its tuning 今日は深層学習とニューラルネットワークの基礎、 DeepLearning4jのアーキテクチャについて触れます
  • 4. What is Machine Learning? "Field of study that gives computers the ability to learn without being explicitly programmed." Arthur Samuel (1959) 機械学習とは、明示的にプログラムされなくてもコンピューターに学ぶ能力を付与する研究分野のこと。
  • 5. What is Deep Learning? - A category of Machine Learning, especially for images, text, audio, etc. - Accurate and reasonably fast. - Train “Neural Networks” with updating its parameters over iterations. - Neural Network has a layered structure, and learns features in each layer 深層学習は、ニューラルネットワークを使う機械学習の一分野で、画像、文章、音などを対象とする。
  • 7. DeepLearning4j Archtecture Canova DeepLearning4j ND4J General Vectorization Library. Vectorize raw data to INDArray. DeepLearning Framework. Construct Neural Network based on configuration. N-dimensional Array calculation Library. DeepLearning4jが設定からニューラルネットを構築。 Canovaは生データをベクター化。 ND4Jはそれらの計算基盤。
  • 9. DeepLearning4j Archtecture Canova DeepLearning4j Images Text Audio INDArray ND4J disclaimer: it’s a simplified example very much. 例えば、Canovaが生の画像を計算しやすいように N次元行列(この例では2次元)に変換する。
  • 10. DeepLearning4j Archtecture Canova DeepLearning4j Images Text Audio INDArray ND4J INDArray ND4S disclaimer: it’s a simplified example very much. 場合によっては、ND4SでN次元行列を計算ないしは学習しやすいように変換する。
  • 11. DEMO https://github.com/taisukeoe/matsuri-mnist-example DEMO in REPL of: https://github.com/deeplearning4j/nd4s
  • 12. DeepLearning4j Archtecture Canova DeepLearning4j ND4J N dimensional Sample Data disclaimer: it’s a simplified example very much. DeepLearning4jによって構築されたニューラルネットが N次元行列の入力を受け取り、結果を表す N次元行列を返す
  • 13. DeepLearning4j Archtecture Canova DeepLearning4j ND4J N dimensional Sample Data disclaimer: it’s a simplified example very much. この例では出力された行列の各列が各クラスに分類される確率を表す。 2が90%、3が10%という具合。
  • 14. How DeepLearning works N dimensional Sample Data Parameters in Neural Network (in this picture, Multi Layer Perceptron) got updated over iterations # of samples トレーニングの際。サンプルをミニバッチごとに分けて入力させる。ニューラルネット内の状態が更新され続ける。
  • 15. How DeepLearning works N dimensional Sample Data # of samples Neural Network has states which are updated over iteration. DataSet has states like a iterator. Spit out samples in each mini-batch. トレーニングの際。サンプルをミニバッチごとに分けて入力させる。ニューラルネット内の状態が更新され続ける。
  • 16. How DeepLearning works N dimensional Sample Data # of samples Neural Network has states which are updated over iteration. Go to the detail: How neuron unit behaves: トレーニングを通じて更新される、ニューラルネット内の「状態」の中身を見ていきましょう。
  • 17. How Neuron works 構成単位ニューロン。各 (x:入力)に(w:重み)を乗じて(b:バイアス)を足したものを、活性化関数 fに渡して出力計算。
  • 18. How Neuron works mutable! mutable! immutable! (w 重み)と(b バイアス)は変数で、トレーニングごとに更新される。 活性化関数 fは不変。
  • 19. How Neural Net work in each layer (全結合な)ニューラルネットの各層は、重み行列、バイアス行列、活性化関数からなる関数で表現される
  • 20. Further information: - Type of Neural Network - Convolutional Neural Network - Recurrent Neural Network - etc - Backpropagation - Loss Function - Learning rate - Other hyper parameters 深層学習 http://www.amazon.co.jp/dp/B018K6C99A/ Coursera https://www.coursera.org/course/neuralnets (w:重み)と(b:バイアス)を更新する方法は、誤差逆伝搬法と損失関数、学習係数などで決定される。詳しくは書籍など
  • 21. How to improve results? - Choose appropriate Neural Network(s) - Tune hyper parameters of Neural Network(s). - Pre-process input data to be efficiently trained. 学習結果を改善させるには?ニューラルネットワークのタイプを選ぶ、超パラメータを調整、入力データのプリプロセシン
  • 22. Summary - Deep Learning is a category of Machine Learning, which is trained by Neural Networks with three or more layers. - Neural Network maps input feature matrix to output matrix which stands for possibilities of each class in classification purpose. - DeepLearning4j: Deep Learning framework in JVM - Nd4j: N-dimensional array calculation library - Canova: General vectorization library - Nd4s: NumPy-like + Scala-like API for ND4J 深層学習は、3層以上からなるニューラルネットワークで行う機械学習のこと。N次元行列の生データを加工するなどして、パフォーマンスを上げる。