Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
b3semi_7.pdf
Search
MARUYAMA
March 09, 2017
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
b3semi_7.pdf
MARUYAMA
March 09, 2017
More Decks by MARUYAMA
See All by MARUYAMA
vampire.pdf
tmaru0204
0
200
Misspelling_Oblivious_Word_Embedding.pdf
tmaru0204
0
210
Simple_Unsupervised_Summarization_by_Contextual_Matching.pdf
tmaru0204
0
200
Controlling_Text_Complexity_in_Neural_Machine_Translation.pdf
tmaru0204
0
180
20191028_literature-review.pdf
tmaru0204
0
170
Hint-Based_Training_for_Non-Autoregressive_Machine_Translation.pdf
tmaru0204
0
160
Soft_Contextual_Data_Augmentation_for_Neural_Machine_Translation_.pdf
tmaru0204
0
190
An_Embarrassingly_Simple_Approach_for_Transfer_Learning_from_Pretrained_Language_Models_.pdf
tmaru0204
0
170
Addressing_Trobulesome_Words_in_Neural_Machine_Translation.pdf
tmaru0204
0
180
Featured
See All Featured
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
920
Designing for humans not robots
tammielis
254
26k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
300
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
490
Odyssey Design
rkendrick25
PRO
2
860
How Software Deployment tools have changed in the past 20 years
geshan
2
35k
Building a Scalable Design System with Sketch
lauravandoore
464
34k
Building Flexible Design Systems
yeseniaperezcruz
330
41k
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
350
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.4k
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Transcript
自然言語処理のための機械学習 第7回 B3 丸山 拓海 自然言語処理研究室
自然言語処理のための機械学習 2 2. 文書及び単語の数学的表現 3. クラスタリング 4. 分類 5. 系列ラベリング
1. 必要な数学的知識
4. 分類 3 4.2 ナイーブベイズ分類器 4.3 サポートベクトルマシン 4.4 カーネル法 4.5
対数線形モデル 4.1 分類とは
4.3 サポートベクトルマシン 4 4.3.1 はじめに 4.3.2 マージン最大化 4.3.3 厳密制約下のSVMモデル 4.3.4
緩和制約下のSVMモデル 4.3.5 多値分類器への拡張
4.3.1 はじめに 5 ▪サポートベクトルマシン(Support Vector Machine, SVM) : 線形二値分類器 正クラス
( positive class), 負クラス ( negative class) 訓練データ = (%), (%) , ()), ()) , … , (|,|), (|,|) 正, 負クラスに属する事例のクラスラベル: +1, -1 = ・ − ≥ 0: 正クラス < 0: 負クラス
4.3.2 マージン最大化 6 ▪ 分離平面 (separating plane) : ・ =
を満たす の集合 : 正例 : 負例
4.3.2 マージン最大化 7 ▪ 分離平面 (separating plane) : ・ =
を満たす の集合
4.3.2 マージン最大化 8 ▪ マージン (margin) : 分類平面と, その平面に 最も近い訓練事例の間の距離
▪ マージン最大化 :どちらのクラスからも なるべく遠い位置で分ける
4.3.2 マージン最大化 9 ▪ マージン最大化 ∗ 6 マージン: |6 −
∗ | ・(6 −∗ ) = |||6 − ∗ | (1) ・ =
4.3.2 マージン最大化 10 ▪ マージン最大化 6 マージン: |6 − ∗
| ・(6 −∗ ) = |||6 − ∗ | (1) パラメータを調整し, 分離平面・ = を定数倍すると, ・6 = + 1 ・(6 −∗ ) = ・6 - ・∗ = + 1 − = 1 (2) ・6 = + 1 ・ = ∗
4.3.2 マージン最大化 11 ▪ マージン最大化 6 ・(6 −∗ ) =
|||6 − ∗ | (1) ・(6 −∗ ) = 1 (2) ・6 = + 1 |6 − ∗ | = || マージン最大化 → を最小化する ・ =
4.3.3 厳密制約下でのSVMモデル 12 ▪ 制約条件 訓練事例は, 正しく分類できる (;) = +1
: ・(;) − ≥ 1 6 ・ = ・6 = + 1 (;) = −1 : ・(;) − ≤ −1 ・6 = − 1 (;)(・(;) − ) ≥ 1
4.3.3 厳密制約下でのSVMモデル 13 ▪ 厳密制約下でのSVMモデル . . ; ・ ;
− − 1 ≥ 0 ; ∀ . % ) ラグランジュの未定乗数法により解く , , = 1 2 − G ; ; ・ ; − − 1 ; K , , = − G ; ; ; = 0 , , = G ; ; ; = 0 ∗ = G ; ; ; (3) G ; ; ; = 0 (4)
4.3.3 厳密制約下でのSVMモデル 14 ▪ 厳密制約下でのSVMモデル (3)より, 分離平面の式 = ・ −
は, = G ; ; ; ・ − (5) (3), (4), (5)をもとのラグランジュ関数に代入 ∗, , = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ;
4.3.3 厳密制約下でのSVMモデル 15 ▪ 厳密制約下でのSVMモデル 双対問題(dual problem) ラグランジュの鞍点理論より, . ∗,
, = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ; . . G ; ; ; = 0, ; ≥ 0
4.3.3 厳密制約下でのSVMモデル 16 例題) 訓練データ = (%), −1 , ()),
1 に対し, SVMを構築せよ。 ただし, (%) = 0, 1 , ()) = 1, 1 とする。 ∗, , = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ; 1 1 o ) % G ; ; ; = 0, ; ≥ 0
4.3.3 厳密制約下でのSVMモデル 17 例題) 訓練データ = (%), −1 , ()),
1 に対し, SVMを構築せよ。 ただし, (%) = 0, 1 , ()) = 1, 1 とする。 ∗, , = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ; 1 1 o ) % (%)・(%)=1 (%)・())=())・(%) =1 ())・())=2
4.3.3 厳密制約下でのSVMモデル 18 例題) 訓練データ = (%), −1 , ()),
1 に対し, SVMを構築せよ。 ただし, (%) = 0, 1 , ()) = 1, 1 とする。 ∗, , = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ; 1 1 o ) % (%)・(%)=1 (%)・())=())・(%) =1 ())・())=2 ∗, , = − 1 2 % ) − ) ) + % ) + % + )
4.3.3 厳密制約下でのSVMモデル 19 例題) 訓練データ = (%), −1 , ()),
1 に対し, SVMを構築せよ。 ただし, (%) = 0, 1 , ()) = 1, 1 とする。 1 1 o ) % ∗, , = − 1 2 % ) − ) ) + % ) + % + ) % % + ) ) = −% + ) = 0 より, ∗, , = − 1 2 % ) + 2% ∗, , % = −% + 2 = 0 % = ) = 2
4.3.3 厳密制約下でのSVMモデル 20 例題) 訓練データ = (%), −1 , ()),
1 に対し, SVMを構築せよ。 ただし, (%) = 0, 1 , ()) = 1, 1 とする。 1 1 o ) % % = ) = 2 ∗ = G ; ; ; = 2× −1 × 0,1 + 2×1× 1,1 = (2, 0) = ∗・6 − 1 = 2, 0 ・ 1, 1 − 1 = 1 = 2, 0 ・ − 1 = 0 = 0.5, 0.5
4.3.3 厳密制約下でのSVMモデル 21 例題) 構築したSVMを用いて = 1, 0 を分類せよ。 1
1 o ) % = 2, 0 ・ − 1 よって, = 1, 0 は正例 0.5 = 2, 0 ・ 1, 0 − 1 = 1 > 0
4.3.4 緩和制約下でのSVMモデル 22 訓練データの例外的な事例を考慮 制約条件を緩める ; ・ ; − −
1 ≥ − ; ; ≥ 0 . . ; ・ ; − ≥ 1 − ;; ∀ . % ) + C ∑ ; ; ; :正の定数 ∗, , , = − 1 2 G ; Q ; Q ; ・ R ;,Q + G ; ; ; ≥ 0 0 ≤ ; ≤
4.3.5 多値分類器への拡張 23 ▪ one – versus – rest法 ▪
ペアワイズ法
まとめ 24 4.3.1 はじめに 4.3.2 マージン最大化 4.3.3 厳密制約下のSVMモデル 4.3.4 緩和制約下のSVMモデル
4.3.5 多値分類への拡張