ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
Cara Kerja CNN
Tinjauan Pustaka – Landasan Teori (CNN)
Arsitektur CNN
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0 1 0 1 0 0
0 1 0 0 0 1 1
0 1 1 0 1 0 1
0 1 1 1 0 0 1
((1x1)+(0x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0x0)
+(0x0)+(1x0)+(0x0)+(0x0)+(0x0)+(1x0)+(1x0)
+(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0x0)+(1x0)
+(0x0)+(1x0)+(1x0)+(1x0)+(0x0)+(0x0)+(1x0))/28
0,07
Matriks Filter 4x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 pertama
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 1 1 1 1 0 0
0 1 0 0 1 1 1
1 1 1 0 1 0 1
0 1 1 1 0 0 1
((1x0)+(1x1)+(1x0)+(1x0)+(1x0)+(0x0)+(0x0)
+(0x0)+(1x0)+(0x1)+(0x0)+(1x0)+(1x0)+(1x0)
+(1x0)+(1x0)+(1x1)+(0x1)+(1x0)+(0x0)+(1x0)
+(0x0)+(1x0)+(1x0)+(1x0)+(0x1)+(0x0)+(1x0))/28
0,07
Matriks Filter 4x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 pertama
0,07
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
0 0 0 0 0 0 0
0 0 0 0 1 1 1
1 1 0 0 0 0 1
0 1 0 0 0 0 1
0,07
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 pertama
0,07
0,11
((0x0)+(0x0)+(1x1)+(1x0)+(1x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x1)+(1x0)+(1x0)+(1x0)
+(1x0)+(1x0)+(1x0)+(0x0)+(1x1)+(0x0)+(1x0)
+(0x0)+(1x0)+(1x0)+(0x0)+(0x1)+(1x1)+(1x0))/28
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
0 0 1 1 1 0 0
0 0 0 0 1 1 1
1 1 0 0 1 0 1
0 1 1 0 0 1 1
0,07
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 pertama
0,07
0,11
0,07
((0x0)+(0x0)+(0x0)+(0x1)+(0x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(1x0)+(1x0)
+(1x0)+(1x0)+(0x0)+(0x0)+(0x0)+(0x1)+(0x0)
+(0x0)+(1x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1))/28
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
ReLu, Max-Pooling, Fully-connectd Matriks 4x7 pertama
0,07
0,07
0,11
0,07
ReLU Max-Pooling
0,11
0,11
0,07
0,07
0,11
0,07
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0,1 1 0 1 0 0,1
0 1 0 0 0,1 1 1
0 1 1 0 1 0,1 1
0,1 1 1 1 0 0 1
((1x1)+(0,1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0)
+(0x0)+(1x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0)
+(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0)
+(0,1x0)+(1x0)+(1x0)+(1x1)+(0x0)+(0x0)+(1x0))/28
0.14
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0,1 1 0 1 0 0,1
0 0 0 0 0,1 1 0
0 0 1 0 1 0,1 0
0,1 0 1 1 0 0 0
((1x0)+(0,1x1)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0)
+(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(1x0)+(0x0)
+(0x0)+(0x0)+(1x0)+(0x1)+(1x0)+(0,1x0)+(0x0)
+(0,1x0)+(0x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0x0))/28
0.0036
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 kedua
0.14
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0,1 1 0 1 0 0,1
0,1 0 0 0 0,1 1 0
0,1 0,1 1 0,1 1 0,1 0,1
0,1 0 1 1 0 0 0
((1x0)+(0,1x0)+(1x1)+(0x0)+(1x0)+(0x0)+(0,1x0)
+(0,1x0)+(0x0)+(0x0)+(0x1)+(0,1x0)+(1x0)+(0x0)
+(0,1x0)+(0,1x0)+(1x0)+(0,1x0)+(1x1)+(0,1x0)+(0,1x0)
+(0,1x0)+(0x0)+(1x0)+(1x0)+(0x0)+(0x1)+(0x0))/28
0.0036
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 kedua
0.14
0.07
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0,1 0,2 0,4 1 0 0,1
0,1 0 0 0,6 0,1 1 0
0,1 0,1 1 0,1 1 0,1 0,1
0,1 0 1 1 0,8 0 0
((1x0)+(0,1x0)+(0,2x0)+(0,4x1)+(1x0)+(0x0)+(0,1x0)
+(0,1x0)+(0x0)+(0x0)+(0,6x0)+(0,1x1)+(1x0)+(0x0)
+(0,1x0)+(0,1x0)+(1x0)+(0,1x0)+(1x0)+(0,1x1)+(0,1x0)
+(0,1x0)+(0x0)+(1x0)+(1x0)+(0,8x0)+(0x0)+(0x1))/28
0.0036
Matriks Filter 4x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 4x7 kedua
0.14
0.07
0.02
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
ReLu, Max-Pooling, Fully-connectd Matriks 4x7 pertama
0,14
0.0036
0.07
0.02
ReLU Max-Pooling
0,14
0,11
0,14
0,14
0.0036
0.07
0.02
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((1x1)+(0,1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0)
+(0x0)+(1x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0)
+(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0))/21
0.14
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 pertama
1 0,1 1 0 1 0 0,1
0 1 0 0 0,1 1 1
0 1 1 0 1 0,1 1
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((1x0)+(0,1x1)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0)
+(0,6x0)+(1x0)+(0,7x1)+(0,9x0)+(0,1x0)+(1x0)+(1x0)
+(0x0)+(1x0)+(1x0)+(0,2x1)+(1x0)+(0,1x0)+(1x0))/21
0.14
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 pertama
1 0,1 1 0 1 0 0,1
0,6 1 0,7 0,9 0,1 1 1
0 1 1 0,2 1 0,1 1
0.05
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((1x0)+(0,1x0)+(1x1)+(0,7x0)+(1x0)+(0,3x0)+(0,1x0)
+(0,6x0)+(1x0)+(0,7x0)+(0,9x1)+(0,1x0)+(1x0)+(1x0)
+(0,25x0)+(1x0)+(1x0)+(0,2x0)+(1x1)+(0,1x0)+(1x0))/21
0.14
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 pertama
1 0,1 1 0,7 1 0,3 0,1
0,6 1 0,7 0,9 0,1 1 1
0,25 1 1 0,2 1 0,1 1
0.05
0.14
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((1x0)+(0,1x0)+(0x0)+(0,7x1)+(0x0)+(0,3x0)+(0,1x0)
+(0,6x0)+(1x0)+(0,7x0)+(0,9x0)+(0,1x1)+(0x0)+(1x0)
+(0,25x0)+(1x0)+(1x0)+(0,2x0)+(1x0)+(0,1x1)+(1x0))/21
0.14
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 pertama
1 0,1 0 0,7 0 0,3 0,1
0,6 1 0,7 0,9 0,1 0 1
0,25 1 1 0,2 1 0,1 1
0.05
0.14
0.04
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0,1x0)+(0x0)+(0,7x0)+(0x1)+(0,3x0)+(0,1x0)
+(0,6x0)+(1x0)+(0,7x0)+(0,9x0)+(0,1x0)+(1x1)+(1x0)
+(0,25x0)+(1x0)+(0x0)+(0,2x0)+(0x0)+(0,1x0)+(1x1))/21
0.14
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 pertama
0 0,1 0 0,7 0 0,3 0,1
0,6 1 0,7 0,9 0,1 1 1
0,25 1 0 0,2 0 0,1 1
0.05
0.14
0.09
0.04
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama
0,14
0.05
0.14
0.04
0.09
ReLU Max-Pooling
0,14
0,11
0,14
0,14
0,14
0.05
0.14
0.04
0.09
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x1)+(0,1x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0,1x0)
+(0x0)+(0x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0)
+(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0))/21
0.05
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 kedua
0 0,1 0 0 0 0 0,1
0 0 0 0 0,1 1 1
0 1 1 0 1 0,1 1
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0,1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0,1x0)
+(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(0x0))/21
0.05
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 kedua
0 0,1 0 0 0 0 0,1
0 0 0 0 0,1 0 0
0 0 0 0 0 0,1 0
0.0048
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0,1x0)+(0x1)+(0x0)+(0,7x0)+(0x0)+(0,1x0)
+(0x0)+(0x0)+(0,2x0)+(0,7x1)+(0,1x0)+(0x0)+(0x0)
+(0x0)+(0,4x0)+(0x0)+(0x0)+(0x1)+(0,1x0)+(0,8x0))/21
0.05
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 kedua
0 0,1 0 0 0,7 0 0,1
0 0 0,2 0,7 0,1 0 0
0 0,4 0 0 0 0,1 0,8
0.0048
0.03
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0,1x0)+(1x0)+(1x1)+(0,7x0)+(0x0)+(0,1x0)
+(1x0)+(0x0)+(0,2x0)+(0,7x0)+(0,1x1)+(0x0)+(0x0)
+(0x0)+(0,4x0)+(1x0)+(1x0)+(0x0)+(0,1x0)+(0,8x1))/21
0.05
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 kedua
0 0,1 1 1 0,7 0 0,1
1 0 0,2 0,7 0,1 0 0
0 0,4 1 1 0 0,1 0,8
0.0048
0.03
0.09
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0,1x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0,1x0)
+(1x0)+(0x0)+(0x0)+(0,7x0)+(0x0)+(0x1)+(0x0)
+(0x0)+(0x0)+(1x0)+(1x0)+(0x0)+(0,1x0)+(0,8x1))/21
0.05
Matriks Filter 3x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 3x7 kedua
0 0,1 1 1 0 0 0,1
1 0 0 0,7 0 0 0
0 0 1 1 0 0,1 0,8
0.0048
0.03
0.09
0.04
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama
0.05
0.0048
0.03
0.09
0.04
ReLU Max-Pooling
0.09
0,11
0,14
0,14
0.09
0.05
0.0048
0.03
0.09
0.04
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 0 0,7 0 0 0,2 0
0,5 1 0 0,6 0 0,7 0,4
((1x1)+(0x0)+(0,7x0)+(0x0)+(0x0)+(0,2x0)+(0x0)
+(0,5x0)+(1x1)+(0x0)+(0,6x0)+(0x0)+(0,7x0)+(0,4x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
0 0 0 0 0 0,2 0
0,5 1 0 0,6 0 0 0,4
((0x0)+(0x1)+(0x0)+(0x0)+(0x0)+(0,2x0)+(0x0)
+(0,5x0)+(1x0)+(0x1)+(0,6x0)+(0x0)+(0x0)+(0,4x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
0.00000000
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
0 1 0 1 0,9 0,2 1
0,5 1 0 0,6 0,8 0 0,4
((0x0)+(1x0)+(0x1)+(1x0)+(0,9x0)+(0,2x0)+(1x0)
+(0,5x0)+(1x0)+(0x0)+(0,6x1)+(0,8x0)+(0x0)+(0,4x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
0,00000000
0,04
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 1 1 1 0,9 0,2 1
0,5 1 1 0,6 0,8 0 0,4
((1x0)+(1x0)+(1x0)+(1x1)+(0,9x0)+(0,2x0)+(1x0)
+(0,5x0)+(1x0)+(1x0)+(0,6x1)+(0,8x1)+(0x0)+(0,4x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
0,00000000
0,04
0,17
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 1 1 1 0 0,2 1
0,5 1 1 0 0 0 0
((1x0)+(1x0)+(1x0)+(1x0)+(0x1)+(0,2x0)+(1x0)
+(0,5x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0x1)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
0,00000000
0,04
0,17
0,00000000
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
1 1 0 1 0 1 1
0 1 1 0 0 1 0
((1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(1x1)+(1x0)
+(0x0)+(1x0)+(1x0)+(0x0)+(0x0)+(1x0)+(0x1))/14
0,14
Matriks Filter 2x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
Proses convolution Matriks 2x7 pertama
0,00000000
0,04
0,17
0,00000000
0,07
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama
0,14
0,00000000
0,04
0,17
0,00000000
0,07
ReLU Max-Pooling
0,17
0,11
0,14
0,14
0.09
0,17
0,14
0,00000000
0,04
0,17
0,00000000
0,07
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)
+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
1 0 0 0 0 0 0
0 1 0 0 0 0 0
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0,14
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0,14
0,14
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0,14
0,140,14
0,14
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0))/14
0,14
Matriks Filter 2x7
Word Representations
Proses perhitungan (sliding)
Activation Maps
0,14
0,140,14
0,14
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0,14
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
1 0 0 0 0 0 0
0 1 0 0 0 0 0
0 0 1 0 0 0 0
0 0 0 1 0 0 0
0 0 0 0 1 0 0
0 0 0 0 0 1 0
0 0 0 0 0 0 1
((0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)
+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1))/14
0,14
Matriks Filter 2x7 Word Representations
Proses perhitungan (sliding)
Activation Maps
0,14
0,140,14
0,14
0,14
0 0 0 0 0 1 0
0 0 0 0 0 0 1
0,14
Proses convolution Matriks 2x7 kedua
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-
connected
ReLu, Max-Pooling, Fully-connectd Matriks 2x7 kedua
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
0,14
ReLU Max-Pooling
0,14
0,11
0,14
0,14
0.09
0,17
0,14
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
0,11
0,14
0,14
0.09
0,17
0,14
W1=0,1
W2=0,3W3=0,3
W4=0,4
W5=0,4
W6=0,3
W7=0,2
W8=0,1
W9=0,7
W10=0,8
W11=0,9 W12=0,1
M11
M21
FC11
FC21
FC31
FC41
FC51
FC61
0,35BFC 0,35BFC
Tinjauan Pustaka – Landasan Teori (CNN)
M11 = ((FC11*W1 )+(FC21*W3)+(FC31*W5)+(FC41*W7)+(FC51*W9)+(FC61*W11))+(BFC*1)
M21 = ((FC11*W2 )+(FC21*W4)+(FC31*W6)+(FC41*W8)+(FC51*W10)+(FC61*W12))+(BFC*1)
M11 = ((0,11*0,1 )+(0,14*0,3)+(0,14*0,4)+(0,09*0,2)+(0,17*0,7)+(0,14*0,19))+(0,35*1)
M11 = 0.6226
M21 = ((0,11*0,3 )+(0,14*0,4)+(0,14*0,3)+(0,09*0,1)+(0,17*0,8)+(0,14*0,1))+(0,35*1)
M21 = 0.64
Softmax(M11) = exp(M11) / (exp(M11)+exp(M21))
Softmax(M11) = 1.86376754 / 3.76024842
Softmax(M11) = 0.49565011
Softmax(M21) = exp(M21) / (exp(M11)+exp(M21))
Softmax(M21) = 1.89648088 / 3.76024842
Softmax(M21) = 0.50434989
Perhitungan Forward Propagation menggunakan Softmax Activation
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
0,11
0,14
0,14
0.09
0,17
0,14
0.49565011
0.50434989
FC11
FC21
FC31
FC41
FC51
FC61
W1=0,1
W2=0,3W3=0,3
W4=0,4
W5=0,4
W6=0,3
W7=0,2
W8=0,1
W9=0,7
W10=0,8
W11=0,9 W12=0,1
Tinjauan Pustaka – Landasan Teori (CNN)
Fully-connected
0,11
0,14
0,14
0.09
0,17
0,14
1
0
Ground Truth
0.49565011
0.50434989
GT11
GT21
FC11
FC21
FC31
FC41
FC51
FC61
W1=0,1
W2=0,3W3=0,3
W4=0,4
W5=0,4
W6=0,3
W7=0,2
W8=0,1
W9=0,7
W10=0,8
W11=0,9 W12=0,1
Tinjauan Pustaka – Landasan Teori (CNN)
E-M11 = 1/2*((GT11 - M11)2
)
E-M11 = 1/2*((1 - 0.49565011)2
)
E-M11 = 0.12718441
E-M21 = 1/2*((GT21 - M21)2
)
E-M21 = 1/2*((0 - 0.50434989)2
)
E-M21 = 0.12718441
E-Total = E-M21 + E-M21
E-Total = 0.12718441 + 0.12718441
E-Total = 0.25436882
Menghitung Error
Tinjauan Pustaka – Landasan Teori (CNN)
GM11 = 0.49565011 * (1 – 0.49565011) * 0.12718441 = 0.03179370
BackpropagationGM11 = M11 * (1-M11) * E-M11
GM21 = 0.50434989 * (1 – 0.50434989) * 0.12718441 = 0.03179370
DW1 = 0,1 * 0,11 * 0.03179370 = 0.0003497307
Error Gradient
Ubah Delta hingga W12….
Ubah Delta FC
Ubah Delta Weight
DFC1 = 0,11 * (1-0,11) * 0.03179370 * 0,1 = 0.000311260323
Ubah hingga FC61….
GM21 = M21 * (1-M21) * E-M21
DW1 = LR * FC11 * GM11
DFC1 = FC11 * (1-FC11) * GM11 * W1
Tinjauan Pustaka – Landasan Teori (CNN)
Ubah Delta BFC
DBFC = LR * BFC * DFC11
DBFC = 0,1 * 0,45 * 0.000311260323 = 0.00001401
DMF4x7(MF11) = 0,1 * 1 * 0.000311260323 = 0.00003113
Ubah hingga Delta Weight seluruh Matriks Filter
Ubah Delta Weight Matriks Filter
Matriks Filter 4x7 Pertama
DMF4x7(MF11)= LR * MF4x7(MF11) * DFC11
DBMF = 0,1 * 0 * 0.000311260323 = 0
Ubah Delta BMF
DBMF = LR * BM * DFC11
Ubah hingga Delta Bias Matriks Filter seluruh Matriks Filter
Update Weight terbaru dari Matriks Filter
MF4x7(MF11) = 1 + 0.00003113 = 1.00003113
Update seluruh weight dari Matriks Filter
MF4x7(MF11) = MF4x7(MF11) + DMF4x7(MF11)
Update Bias terbaru dari BMF
BMF = BMF + DBMF
BMF = 0 + 0 = 0
Update seluruh Bias Matriks Filter dari
Matriks Filter
Update Bias terbaru dari BFC
BFC = BFC + DBFC
BFC = 0,45 + 0.00001401 = 0.45001401
Update Weight terbaru dari weight FC
Update seluruh weight terbaru dari weight FC
W1 = 0,1 + 0.0003497307 = 0.1003497307
W1 = W1 + DW1
Tinjauan Pustaka – Landasan Teori (CNN)
Setelah tahap backpropagation, proses sliding dilakukan
lagi dengan data teks yang baru sampai proses
menghitung nilai loss. Proses ini dijalankan terus sampai
mendapatkan nilai loss terendah. Ketika sudah
mendapatkan nilai loss terendah, maka proses selesai dan
model selesai dibuat. Model inilah yang akan digunakan
dalam pengetesan nantinya.

More Related Content

Perhitungan matematis CNN untuk Analisis Sentimen

  • 2. Tinjauan Pustaka – Landasan Teori (CNN) Arsitektur CNN
  • 3. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0 1 0 1 0 0 0 1 0 0 0 1 1 0 1 1 0 1 0 1 0 1 1 1 0 0 1 ((1x1)+(0x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0x0) +(0x0)+(1x0)+(0x0)+(0x0)+(0x0)+(1x0)+(1x0) +(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0x0)+(1x0) +(0x0)+(1x0)+(1x0)+(1x0)+(0x0)+(0x0)+(1x0))/28 0,07 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 pertama
  • 4. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 1 0 0 1 1 1 1 1 1 0 1 0 1 0 1 1 1 0 0 1 ((1x0)+(1x1)+(1x0)+(1x0)+(1x0)+(0x0)+(0x0) +(0x0)+(1x0)+(0x1)+(0x0)+(1x0)+(1x0)+(1x0) +(1x0)+(1x0)+(1x1)+(0x1)+(1x0)+(0x0)+(1x0) +(0x0)+(1x0)+(1x0)+(1x0)+(0x1)+(0x0)+(1x0))/28 0,07 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 pertama 0,07
  • 5. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 0 0 0 0 1 0 1 0 0 0 0 1 0,07 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 pertama 0,07 0,11 ((0x0)+(0x0)+(1x1)+(1x0)+(1x0)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(0x1)+(1x0)+(1x0)+(1x0) +(1x0)+(1x0)+(1x0)+(0x0)+(1x1)+(0x0)+(1x0) +(0x0)+(1x0)+(1x0)+(0x0)+(0x1)+(1x1)+(1x0))/28
  • 6. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 1 1 1 0 0 0 0 0 0 1 1 1 1 1 0 0 1 0 1 0 1 1 0 0 1 1 0,07 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 pertama 0,07 0,11 0,07 ((0x0)+(0x0)+(0x0)+(0x1)+(0x0)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(1x0)+(1x0) +(1x0)+(1x0)+(0x0)+(0x0)+(0x0)+(0x1)+(0x0) +(0x0)+(1x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1))/28
  • 7. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected ReLu, Max-Pooling, Fully-connectd Matriks 4x7 pertama 0,07 0,07 0,11 0,07 ReLU Max-Pooling 0,11 0,11 0,07 0,07 0,11 0,07
  • 8. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0,1 1 0 1 0 0,1 0 1 0 0 0,1 1 1 0 1 1 0 1 0,1 1 0,1 1 1 1 0 0 1 ((1x1)+(0,1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0) +(0x0)+(1x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0) +(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0) +(0,1x0)+(1x0)+(1x0)+(1x1)+(0x0)+(0x0)+(1x0))/28 0.14 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 kedua
  • 9. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0,1 1 0 1 0 0,1 0 0 0 0 0,1 1 0 0 0 1 0 1 0,1 0 0,1 0 1 1 0 0 0 ((1x0)+(0,1x1)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0) +(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(1x0)+(0x0) +(0x0)+(0x0)+(1x0)+(0x1)+(1x0)+(0,1x0)+(0x0) +(0,1x0)+(0x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0x0))/28 0.0036 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 kedua 0.14
  • 10. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0,1 1 0 1 0 0,1 0,1 0 0 0 0,1 1 0 0,1 0,1 1 0,1 1 0,1 0,1 0,1 0 1 1 0 0 0 ((1x0)+(0,1x0)+(1x1)+(0x0)+(1x0)+(0x0)+(0,1x0) +(0,1x0)+(0x0)+(0x0)+(0x1)+(0,1x0)+(1x0)+(0x0) +(0,1x0)+(0,1x0)+(1x0)+(0,1x0)+(1x1)+(0,1x0)+(0,1x0) +(0,1x0)+(0x0)+(1x0)+(1x0)+(0x0)+(0x1)+(0x0))/28 0.0036 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 kedua 0.14 0.07
  • 11. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0,1 0,2 0,4 1 0 0,1 0,1 0 0 0,6 0,1 1 0 0,1 0,1 1 0,1 1 0,1 0,1 0,1 0 1 1 0,8 0 0 ((1x0)+(0,1x0)+(0,2x0)+(0,4x1)+(1x0)+(0x0)+(0,1x0) +(0,1x0)+(0x0)+(0x0)+(0,6x0)+(0,1x1)+(1x0)+(0x0) +(0,1x0)+(0,1x0)+(1x0)+(0,1x0)+(1x0)+(0,1x1)+(0,1x0) +(0,1x0)+(0x0)+(1x0)+(1x0)+(0,8x0)+(0x0)+(0x1))/28 0.0036 Matriks Filter 4x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 4x7 kedua 0.14 0.07 0.02
  • 12. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected ReLu, Max-Pooling, Fully-connectd Matriks 4x7 pertama 0,14 0.0036 0.07 0.02 ReLU Max-Pooling 0,14 0,11 0,14 0,14 0.0036 0.07 0.02
  • 13. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((1x1)+(0,1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0) +(0x0)+(1x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0) +(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0))/21 0.14 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 pertama 1 0,1 1 0 1 0 0,1 0 1 0 0 0,1 1 1 0 1 1 0 1 0,1 1
  • 14. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((1x0)+(0,1x1)+(1x0)+(0x0)+(1x0)+(0x0)+(0,1x0) +(0,6x0)+(1x0)+(0,7x1)+(0,9x0)+(0,1x0)+(1x0)+(1x0) +(0x0)+(1x0)+(1x0)+(0,2x1)+(1x0)+(0,1x0)+(1x0))/21 0.14 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 pertama 1 0,1 1 0 1 0 0,1 0,6 1 0,7 0,9 0,1 1 1 0 1 1 0,2 1 0,1 1 0.05
  • 15. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((1x0)+(0,1x0)+(1x1)+(0,7x0)+(1x0)+(0,3x0)+(0,1x0) +(0,6x0)+(1x0)+(0,7x0)+(0,9x1)+(0,1x0)+(1x0)+(1x0) +(0,25x0)+(1x0)+(1x0)+(0,2x0)+(1x1)+(0,1x0)+(1x0))/21 0.14 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 pertama 1 0,1 1 0,7 1 0,3 0,1 0,6 1 0,7 0,9 0,1 1 1 0,25 1 1 0,2 1 0,1 1 0.05 0.14
  • 16. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((1x0)+(0,1x0)+(0x0)+(0,7x1)+(0x0)+(0,3x0)+(0,1x0) +(0,6x0)+(1x0)+(0,7x0)+(0,9x0)+(0,1x1)+(0x0)+(1x0) +(0,25x0)+(1x0)+(1x0)+(0,2x0)+(1x0)+(0,1x1)+(1x0))/21 0.14 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 pertama 1 0,1 0 0,7 0 0,3 0,1 0,6 1 0,7 0,9 0,1 0 1 0,25 1 1 0,2 1 0,1 1 0.05 0.14 0.04
  • 17. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0,1x0)+(0x0)+(0,7x0)+(0x1)+(0,3x0)+(0,1x0) +(0,6x0)+(1x0)+(0,7x0)+(0,9x0)+(0,1x0)+(1x1)+(1x0) +(0,25x0)+(1x0)+(0x0)+(0,2x0)+(0x0)+(0,1x0)+(1x1))/21 0.14 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 pertama 0 0,1 0 0,7 0 0,3 0,1 0,6 1 0,7 0,9 0,1 1 1 0,25 1 0 0,2 0 0,1 1 0.05 0.14 0.09 0.04
  • 18. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama 0,14 0.05 0.14 0.04 0.09 ReLU Max-Pooling 0,14 0,11 0,14 0,14 0,14 0.05 0.14 0.04 0.09
  • 19. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x1)+(0,1x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0,1x0) +(0x0)+(0x1)+(0x0)+(0x0)+(0,1x0)+(1x0)+(1x0) +(0x0)+(1x0)+(1x1)+(0x0)+(1x0)+(0,1x0)+(1x0))/21 0.05 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 kedua 0 0,1 0 0 0 0 0,1 0 0 0 0 0,1 1 1 0 1 1 0 1 0,1 1
  • 20. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0,1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0,1x0) +(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(0x1)+(0x0)+(0,1x0)+(0x0))/21 0.05 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 kedua 0 0,1 0 0 0 0 0,1 0 0 0 0 0,1 0 0 0 0 0 0 0 0,1 0 0.0048
  • 21. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0,1x0)+(0x1)+(0x0)+(0,7x0)+(0x0)+(0,1x0) +(0x0)+(0x0)+(0,2x0)+(0,7x1)+(0,1x0)+(0x0)+(0x0) +(0x0)+(0,4x0)+(0x0)+(0x0)+(0x1)+(0,1x0)+(0,8x0))/21 0.05 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 kedua 0 0,1 0 0 0,7 0 0,1 0 0 0,2 0,7 0,1 0 0 0 0,4 0 0 0 0,1 0,8 0.0048 0.03
  • 22. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0,1x0)+(1x0)+(1x1)+(0,7x0)+(0x0)+(0,1x0) +(1x0)+(0x0)+(0,2x0)+(0,7x0)+(0,1x1)+(0x0)+(0x0) +(0x0)+(0,4x0)+(1x0)+(1x0)+(0x0)+(0,1x0)+(0,8x1))/21 0.05 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 kedua 0 0,1 1 1 0,7 0 0,1 1 0 0,2 0,7 0,1 0 0 0 0,4 1 1 0 0,1 0,8 0.0048 0.03 0.09
  • 23. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0,1x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0,1x0) +(1x0)+(0x0)+(0x0)+(0,7x0)+(0x0)+(0x1)+(0x0) +(0x0)+(0x0)+(1x0)+(1x0)+(0x0)+(0,1x0)+(0,8x1))/21 0.05 Matriks Filter 3x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 3x7 kedua 0 0,1 1 1 0 0 0,1 1 0 0 0,7 0 0 0 0 0 1 1 0 0,1 0,8 0.0048 0.03 0.09 0.04
  • 24. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama 0.05 0.0048 0.03 0.09 0.04 ReLU Max-Pooling 0.09 0,11 0,14 0,14 0.09 0.05 0.0048 0.03 0.09 0.04
  • 25. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0 0,7 0 0 0,2 0 0,5 1 0 0,6 0 0,7 0,4 ((1x1)+(0x0)+(0,7x0)+(0x0)+(0x0)+(0,2x0)+(0x0) +(0,5x0)+(1x1)+(0x0)+(0,6x0)+(0x0)+(0,7x0)+(0,4x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama
  • 26. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0,2 0 0,5 1 0 0,6 0 0 0,4 ((0x0)+(0x1)+(0x0)+(0x0)+(0x0)+(0,2x0)+(0x0) +(0,5x0)+(1x0)+(0x1)+(0,6x0)+(0x0)+(0x0)+(0,4x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama 0.00000000
  • 27. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 1 0 1 0,9 0,2 1 0,5 1 0 0,6 0,8 0 0,4 ((0x0)+(1x0)+(0x1)+(1x0)+(0,9x0)+(0,2x0)+(1x0) +(0,5x0)+(1x0)+(0x0)+(0,6x1)+(0,8x0)+(0x0)+(0,4x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama 0,00000000 0,04
  • 28. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 1 1 1 0,9 0,2 1 0,5 1 1 0,6 0,8 0 0,4 ((1x0)+(1x0)+(1x0)+(1x1)+(0,9x0)+(0,2x0)+(1x0) +(0,5x0)+(1x0)+(1x0)+(0,6x1)+(0,8x1)+(0x0)+(0,4x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama 0,00000000 0,04 0,17
  • 29. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 1 1 1 0 0,2 1 0,5 1 1 0 0 0 0 ((1x0)+(1x0)+(1x0)+(1x0)+(0x1)+(0,2x0)+(1x0) +(0,5x0)+(1x0)+(1x0)+(0x1)+(0x0)+(0x1)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama 0,00000000 0,04 0,17 0,00000000
  • 30. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 1 0 1 0 1 1 0 1 1 0 0 1 0 ((1x0)+(1x0)+(0x0)+(1x0)+(0x0)+(1x1)+(1x0) +(0x0)+(1x0)+(1x0)+(0x0)+(0x0)+(1x0)+(0x1))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps Proses convolution Matriks 2x7 pertama 0,00000000 0,04 0,17 0,00000000 0,07
  • 31. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected ReLu, Max-Pooling, Fully-connectd Matriks 3x7 pertama 0,14 0,00000000 0,04 0,17 0,00000000 0,07 ReLU Max-Pooling 0,17 0,11 0,14 0,14 0.09 0,17 0,14 0,00000000 0,04 0,17 0,00000000 0,07
  • 32. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0) +(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 1 0 0 0 0 0 0 0 1 0 0 0 0 0 Proses convolution Matriks 2x7 kedua
  • 33. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0) +(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0,14 Proses convolution Matriks 2x7 kedua
  • 34. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0,14 0,14 Proses convolution Matriks 2x7 kedua
  • 35. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0,14 0,140,14 0,14 Proses convolution Matriks 2x7 kedua
  • 36. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0)+(0x0) +(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 0,14 0,140,14 0,14 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0,14 Proses convolution Matriks 2x7 kedua
  • 37. Tinjauan Pustaka – Landasan Teori (CNN) 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 ((0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1)+(0x0) +(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(0x0)+(1x1))/14 0,14 Matriks Filter 2x7 Word Representations Proses perhitungan (sliding) Activation Maps 0,14 0,140,14 0,14 0,14 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0,14 Proses convolution Matriks 2x7 kedua
  • 38. Tinjauan Pustaka – Landasan Teori (CNN) Fully- connected ReLu, Max-Pooling, Fully-connectd Matriks 2x7 kedua 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 0,14 ReLU Max-Pooling 0,14 0,11 0,14 0,14 0.09 0,17 0,14
  • 39. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected 0,11 0,14 0,14 0.09 0,17 0,14 W1=0,1 W2=0,3W3=0,3 W4=0,4 W5=0,4 W6=0,3 W7=0,2 W8=0,1 W9=0,7 W10=0,8 W11=0,9 W12=0,1 M11 M21 FC11 FC21 FC31 FC41 FC51 FC61 0,35BFC 0,35BFC
  • 40. Tinjauan Pustaka – Landasan Teori (CNN) M11 = ((FC11*W1 )+(FC21*W3)+(FC31*W5)+(FC41*W7)+(FC51*W9)+(FC61*W11))+(BFC*1) M21 = ((FC11*W2 )+(FC21*W4)+(FC31*W6)+(FC41*W8)+(FC51*W10)+(FC61*W12))+(BFC*1) M11 = ((0,11*0,1 )+(0,14*0,3)+(0,14*0,4)+(0,09*0,2)+(0,17*0,7)+(0,14*0,19))+(0,35*1) M11 = 0.6226 M21 = ((0,11*0,3 )+(0,14*0,4)+(0,14*0,3)+(0,09*0,1)+(0,17*0,8)+(0,14*0,1))+(0,35*1) M21 = 0.64 Softmax(M11) = exp(M11) / (exp(M11)+exp(M21)) Softmax(M11) = 1.86376754 / 3.76024842 Softmax(M11) = 0.49565011 Softmax(M21) = exp(M21) / (exp(M11)+exp(M21)) Softmax(M21) = 1.89648088 / 3.76024842 Softmax(M21) = 0.50434989 Perhitungan Forward Propagation menggunakan Softmax Activation
  • 41. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected 0,11 0,14 0,14 0.09 0,17 0,14 0.49565011 0.50434989 FC11 FC21 FC31 FC41 FC51 FC61 W1=0,1 W2=0,3W3=0,3 W4=0,4 W5=0,4 W6=0,3 W7=0,2 W8=0,1 W9=0,7 W10=0,8 W11=0,9 W12=0,1
  • 42. Tinjauan Pustaka – Landasan Teori (CNN) Fully-connected 0,11 0,14 0,14 0.09 0,17 0,14 1 0 Ground Truth 0.49565011 0.50434989 GT11 GT21 FC11 FC21 FC31 FC41 FC51 FC61 W1=0,1 W2=0,3W3=0,3 W4=0,4 W5=0,4 W6=0,3 W7=0,2 W8=0,1 W9=0,7 W10=0,8 W11=0,9 W12=0,1
  • 43. Tinjauan Pustaka – Landasan Teori (CNN) E-M11 = 1/2*((GT11 - M11)2 ) E-M11 = 1/2*((1 - 0.49565011)2 ) E-M11 = 0.12718441 E-M21 = 1/2*((GT21 - M21)2 ) E-M21 = 1/2*((0 - 0.50434989)2 ) E-M21 = 0.12718441 E-Total = E-M21 + E-M21 E-Total = 0.12718441 + 0.12718441 E-Total = 0.25436882 Menghitung Error
  • 44. Tinjauan Pustaka – Landasan Teori (CNN) GM11 = 0.49565011 * (1 – 0.49565011) * 0.12718441 = 0.03179370 BackpropagationGM11 = M11 * (1-M11) * E-M11 GM21 = 0.50434989 * (1 – 0.50434989) * 0.12718441 = 0.03179370 DW1 = 0,1 * 0,11 * 0.03179370 = 0.0003497307 Error Gradient Ubah Delta hingga W12…. Ubah Delta FC Ubah Delta Weight DFC1 = 0,11 * (1-0,11) * 0.03179370 * 0,1 = 0.000311260323 Ubah hingga FC61…. GM21 = M21 * (1-M21) * E-M21 DW1 = LR * FC11 * GM11 DFC1 = FC11 * (1-FC11) * GM11 * W1
  • 45. Tinjauan Pustaka – Landasan Teori (CNN) Ubah Delta BFC DBFC = LR * BFC * DFC11 DBFC = 0,1 * 0,45 * 0.000311260323 = 0.00001401 DMF4x7(MF11) = 0,1 * 1 * 0.000311260323 = 0.00003113 Ubah hingga Delta Weight seluruh Matriks Filter Ubah Delta Weight Matriks Filter Matriks Filter 4x7 Pertama DMF4x7(MF11)= LR * MF4x7(MF11) * DFC11 DBMF = 0,1 * 0 * 0.000311260323 = 0 Ubah Delta BMF DBMF = LR * BM * DFC11 Ubah hingga Delta Bias Matriks Filter seluruh Matriks Filter Update Weight terbaru dari Matriks Filter MF4x7(MF11) = 1 + 0.00003113 = 1.00003113 Update seluruh weight dari Matriks Filter MF4x7(MF11) = MF4x7(MF11) + DMF4x7(MF11) Update Bias terbaru dari BMF BMF = BMF + DBMF BMF = 0 + 0 = 0 Update seluruh Bias Matriks Filter dari Matriks Filter Update Bias terbaru dari BFC BFC = BFC + DBFC BFC = 0,45 + 0.00001401 = 0.45001401 Update Weight terbaru dari weight FC Update seluruh weight terbaru dari weight FC W1 = 0,1 + 0.0003497307 = 0.1003497307 W1 = W1 + DW1
  • 46. Tinjauan Pustaka – Landasan Teori (CNN) Setelah tahap backpropagation, proses sliding dilakukan lagi dengan data teks yang baru sampai proses menghitung nilai loss. Proses ini dijalankan terus sampai mendapatkan nilai loss terendah. Ketika sudah mendapatkan nilai loss terendah, maka proses selesai dan model selesai dibuat. Model inilah yang akan digunakan dalam pengetesan nantinya.