2. Review Bayes
嗗Metodologi Bayesian reasoning
嗗Pendekatan probabilistik untuk menghasilkan inferensi.
嗗Quantity of interest -> Distribusi probabilitas.
嗗Pemilihan yang optimal -> Reasoning (Probabilitas dan observasi data).
嗗Pendekatan kuantitatif, menimbang bukti yang mendukung alternatif hipotesis.
3. Bayesian Learning
嗗Bayesian Learning merupakan suatu metode
pembelajaran yang dikenal dalam machine learning.
嗗Dua alasan bayesian learning dipelajari dalam
machine learning yakni :
–Bayesian Learning menghitung secara eksplisit
probabilitas untuk setiap hipotesis, seperti klasifikasi
pada Naive Bayes.
–Bayesian Learning memberikan perspektif dalam
memahami algoritma pembelajaran lainnya
4. Teorema Bayes
Teorema Bayes menyediakan cara untuk menghitung
probabilitas dari suatu hipotesis berdasarkan probabilitas
sebelumnya, probabilitas mengamati berbagai data yang
diberikan hipotesis, dan data yang diamati itu sendiri.
7. Kemampuan Bayesian Method
Menangani data set yang tidak lengkap.
Pembelajaran mengenai Causal Networks
Memfasiitasi kombinasi dari domain knowledge
dan data.
Efisien dan mempunyai prinsip untuk
menghindari overfitting data.
10. Naive Bayes Classifier
嗗Keuntungan
–Mudah diimplementasikan.
–Hasil yang baik bila diimplementasikan pada beberapa
kondisi.
嗗Kekurangan
–Asumsi : Conditional independence, loss acuracy.
–Tidak dapat memodelkan dependensi atribut.
嗗Untuk menjawab kekurangan pada Naive Bayes ini digunakan
Bayes Belief Network.
12. Objective & Motivation
嗗Objective: Explain the concept of Bayesian Network.
嗗Reference: www.cse.ust.hk/bnbook
Predisposing factors symptoms test result
diseases treatment outcome.
Class label for thousands of superpixels.
13. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
14. The Probabilistic Approach to
Reasoning Under Certainty
嗗Domain Variable: X1, X2, X3, …, Xn
嗗Knowledge about the problem domain is
represented by a Joint Probability P(X1, X2, X3, …,
Xn)
15. The Probabilistic Approach to
Reasoning Under Certainty
Example : Alarm (Pearl 1988)
嗗hnCalls (J), MaryCalls (M)
嗗Knowledge required by the probabilistic approach in
order to solve this problem: P(B,E,A,J,M)
嗗Problem: Estimate the probability of a burglary
based who has or has not called.
嗗Variables: Burglary (B), Earthquake (E), Alaram (A),
JohnCalls (J), MaryCalls (M)
嗗Knowledge required by the probabilistic approach in
order to solve this problem: P(B,E,A,J,M)
17. Inference with Joint Probability
Distribution
± What is probability of Burglary given that Mary
Called, P(B=y|M=y)?
± Steps:
1.Compute Marginal Probability
2.Compute answer (reasoning by conditioning):
18. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
23. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
24. Bayesian Network
嗗 Each node represent a
random variable
嗗 Between nodes as influences
Recall in introduction
嗗 Bayesian Networks are
networks of random variables.
嗗 The topology of network
determines the relationship
between attributes
27. Dependent Vs Independent
嗗JohnCalls dan MeryCalls are
Dependent
嗗JohnCalss is Independent of
MeryCalss given Alarm
嗗Burglary and Earthquake are
Independent
嗗Burglary is dependent of
Earthquake given Alarm
29. Bayesian network topology
Serial Connection
嗗C depend on B, and B depend on
A
嗗If the value of B is known, then A
should be independent from C
(then A d-separated with C)
Divergen Connection
嗗B, C, D.., F depend on A
嗗if the value of A is known, B, C,
D,..F should be independent each
others (d-separated)
嗗otherwise B, C, D,.. dependent
30. Bayesian network topology
Convergen Connection
嗗A depend on B, C, D,,... F
嗗if value of A is unknown, then B, C,
E, ... F should be independent
each others (d-separated)
嗗Otherwise B,C,E,...F dependent
each others
31. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
32. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
34. Bayesian Network Building
Komponen Bayesian Network
嗗Kualitatif → Berupa directed acyclic graph (DAG)
dimana atribut direpresentasikan oleh node sedangkan
edge menggambarkan kausalitas antar node
嗗Kuantitatif → Berupa Conditional Probabilitas Table
(CPT) yang memberikan informasi besarnya probabilitas
untuk setiap nilai atribut berdasarkan parent dari atribut
bersangkutan
13 Nopember 2012
35. Excercise Diet
Heart
Disease
Heartburn
Chest PainBlood
Pressure
HD = Yes
E = Yes
D = Healthy
0,25
E = Yes
D = Unhealthy
0,45
E = No
D = Healthy
0,55
E = No
D = Unhealthy
0,75
CP =
Yes
HD = Yes
Hb = Yes
0,8
HD = Yes
Hb = No
0,5
D = No
Hb = Yes
0,4
HD = Yes
Hb = No
0,1
Hb = Yes
D = Healthy 0,8
D =
Unhealthy
0,85
Hb = Yes
HD = Yes 0,85
HD = No 0,2
E = Yes
0,7
D = Healthy
0,25
13 Nopember 2012
Contoh Bayesian Network
36. Tahapan yang dilakukan:
嗗Konstruksi struktur atau tahap kualitatif, yaitu
mencari keterhubungan antara variabel-variabel yang
dimodelkan
嗗Estimasi parameter atau tahap kuantitatif, yaitu
menghitung nilai-nilai probabilitas
13 Nopember 2012
Bayesian Network Building
37. Bayesian Network Building
Ada dua pendekatan yang digunakan untuk mengkonstruksi
struktur Bayesian Network yaitu
1.Metode Search and Scoring (Scored Based)
Menggunakan metode pencarian untuk mendapatkan struktur yang
cocok dengan data, di mana proses konstruksi dilakukan secara iteratif
2. Metode Dependency Analysis (Constraint Based)
Mengidentifikasi/menganalisa hubungan bebas bersyarat (conditional
independence test) atau disebut juga CI-test antar atribut, dimana CI
menjadi “constraint” dalam membangun struktur Bayesian Network.
13 Nopember 2012
38. Algoritma BN building
嗗Search & Scoring Based (Chow-Liu Tree
Construction, K2, Kutato, Benedict, CB, dll)
嗗Dependency Analysis Based ( TPDA, Boundary
DAG, SRA, SGS, PC, dll)
13 Nopember 2012
Bayesian Network Building
39. MMutual Information
Mutual Information
MI dari dua variabel acak merupakan nilai ukur yang
menyatakan keterikatan/ketergantungan (mutual
dependence) antara kedua variabel tersebut.
13 Nopember 2012
Bayesian Network Building
50. Gradient ascent training
嗗Mirip seperti neural networks
–Asumsi bahwa setiap entry dalam CPT adalah sebuah wight
–Bentuk gradient dalam likelihooda, P(D|h), with respect to
the weight.
–Update weights in the direction of the gradient
52. Gradient ascent training
嗗Let wijk denote one entry in the conditional probability
table for variable Yi in the network
wijk = P(Yi = yij |Parents(Yi ) = the list uik of values)
e.g., if Yi = Campfire, then uik might be (Storm = T, BusTourGroup = F)
嗗Perform gradient ascent by repeatedly
1.update all wijk using training data D
1.then, renormalize the wijk to assure
53.
54. Outline
1.Probabilistic Modeling with Joint Distribution
2.Conditional Independence
3.Bayesian Networks
4.Manual Construction of Bayesian Networks
5.Inference
6.Some example
55. Inference
嗗Suatu metode yang ada dalam bayesian
network yang digunakan untuk mengambil
suatu keputusan
嗗Inferensi berangkat dari suatu target variabel
jika diketahui variabel yang lain (observed
variable)
嗗P(A | X) - dimana A adalah target variabel
(question), dan X adalah observed variable
(evidence)
58. Inference dalam Bayesian Network
嗗Probabilistic Inference
–Diagnostic inference
–Causal inference
–Inter-causal inference
–Mixed inference
嗗Exact inference
–Inference by enumeration
–Variable elemination algorithm
嗗Approximate inference - digunakan apabila terdapat
unobserved variable
59. Probabilistic Inference
嗗Suatu proses untuk mencari / menghitung nilai
dari distribusi probabilitas posterior jika
diketahui beberapa evidence yang ada
嗗Evidence yang diketahui dapat berupa
dependent atribute, maupun conditional
dependent attribute
61. Probabilistic Inference
嗗Causal Inference (from
cause to effect)
–P(J|B) = P(J,B) / P(B)
–Mencari suatu kesimpulan
dengan evidence berupa
cause (Q = john calls,
E=burglary)
64. 嗗Inference by Enumeration
–Untuk menghitung nilai dari probabilitas dari variable Q
dengan evidence E (E1, E2,...Ek) dapat menggunakan aturan
conditional independentPersamaan tersebut dapat dihitung
dengan dengan menjumlahkan
– persamaan dari full joint distribution
Exact Inference