Skip to content

Commit 876136e

Browse files
committed
added intro
1 parent d4b0f3c commit 876136e

File tree

1 file changed

+203
-0
lines changed

1 file changed

+203
-0
lines changed
Lines changed: 203 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,203 @@
1+
---
2+
title: 'Introduction to Generative Models'
3+
description: 'Introduction to Generative Models'
4+
pubDate: '2025-09-11'
5+
heroImage: '../../assets/blog-placeholder-3.jpg'
6+
---
7+
8+
import T from '../../components/TypstMath.astro'
9+
10+
This Lecture is an general introduction to generative modelling.
11+
12+
### Introduction
13+
14+
This is an introduction to the main settings encountered in generative modelling. The first Lectures will introduce the main algorithms and concept for the vanilla unconditional generative modelling task.
15+
At the end of the course, we will make excursions to class-conditional and text-conditional generative modelling.
16+
17+
18+
#### Unconditional Generative Modelling
19+
20+
**What** In *unconditional* generative modelling, we are given a set of unlabelled data
21+
22+
<T block v='text("Data: ") underbrace({x_1, x_2, x_3,dots, x_n}, n "observations") in bb(R)^d .' />
23+
24+
25+
export const catGallery = [
26+
{
27+
url: "https://images.pexels.com/photos/57416/cat-sweet-kitty-animals-57416.jpeg?auto=compress&cs=tinysrgb&w=800",
28+
caption: "x1",
29+
alt: "Cute cat 1"
30+
},
31+
{
32+
url: "https://images.pexels.com/photos/20787/pexels-photo.jpg?auto=compress&cs=tinysrgb&w=800",
33+
caption: "x2",
34+
alt: "Cute cat 2"
35+
},
36+
{
37+
url: "https://images.pexels.com/photos/1183434/pexels-photo-1183434.jpeg?auto=compress&cs=tinysrgb&w=800",
38+
caption: "x3",
39+
alt: "Cute cat 3"
40+
},
41+
{
42+
url: "https://images.pexels.com/photos/979247/pexels-photo-979247.jpeg?auto=compress&cs=tinysrgb&w=800",
43+
caption: "x4",
44+
alt: "Cute cat 4"
45+
},
46+
{
47+
url: "https://images.pexels.com/photos/2558605/pexels-photo-2558605.jpeg?auto=compress&cs=tinysrgb&w=800",
48+
caption: "x5",
49+
alt: "Cute cat 5"
50+
},
51+
{
52+
url: "https://images.pexels.com/photos/1276553/pexels-photo-1276553.jpeg?auto=compress&cs=tinysrgb&w=800",
53+
caption: "x6",
54+
alt: "Cute cat 5"
55+
}
56+
]
57+
58+
<figure>
59+
<div style={{
60+
display: "grid",
61+
gridTemplateColumns: "repeat(auto-fit, minmax(200px, 1fr))",
62+
gap: "1rem",
63+
alignItems: "start"
64+
}}>
65+
{catGallery.map((cat, idx) => (
66+
<figure key={idx} style={{ margin: 0 }}> {/* remove default margin */}
67+
<img
68+
src={cat.url}
69+
alt={cat.alt}
70+
style={{ width: "100%", height: "auto", objectFit: "cover", display: "block" }}
71+
/>
72+
<figcaption style={{
73+
textAlign: "center",
74+
fontSize: "0.85rem",
75+
color: "#6b7280",
76+
margin: 0, // remove figcaption margin
77+
marginTop: "0.25rem" // optional small spacing
78+
}}>
79+
{cat.caption}
80+
</figcaption>
81+
</figure>
82+
))}
83+
</div>
84+
85+
<figcaption style={{
86+
textAlign: "center",
87+
marginTop: "1rem",
88+
fontStyle: "italic",
89+
color: "#6b7280"
90+
}}>
91+
A dataset of cat photos (source, Pexels.com).
92+
</figcaption>
93+
</figure>
94+
95+
**Assumption** The core underlying assumption of generative modelling is that the data $x_1, \dots, x_n$, is drawn from some *unknown* underlying distribution $p_{data}$: for all $i \in 1, \dots, n$
96+
97+
<T block v='x_i ~ underbrace(p_"data", "unknown") .' />
98+
99+
**Goal** Using the empirical data distribution $x_1, \dots, x_n \sim p_{data}$, the goal is to *generate* new samples $x^{\text{new}}$ that look like they were drawn from the same *unknown* distribution $p_{data}$
100+
101+
102+
<T block v='x^"new" ~ p_"data" .' />
103+
104+
105+
#### Class-Conditional Generative Modelling
106+
107+
**What** In *class-conditional* generative modelling, we are given a set of labelled data
108+
109+
<T block v='text("Data: ") underbrace({(x_1, y_1),dots, (x_n, y_n)}, n "labelled observations") in bb(R)^d times bb(R) .' />
110+
111+
112+
export const catDogGallery = [
113+
{
114+
url: "https://images.pexels.com/photos/57416/cat-sweet-kitty-animals-57416.jpeg?auto=compress&cs=tinysrgb&w=800",
115+
caption: "x1, y1=cat",
116+
alt: "Cute cat 1"
117+
},
118+
{
119+
url: "https://images.pexels.com/photos/20787/pexels-photo.jpg?auto=compress&cs=tinysrgb&w=800",
120+
caption: "x2, y2=cat",
121+
alt: "Cute cat 2"
122+
},
123+
{
124+
url: "https://images.pexels.com/photos/1183434/pexels-photo-1183434.jpeg?auto=compress&cs=tinysrgb&w=800",
125+
caption: "x3, y3=cat",
126+
alt: "Cute cat 3"
127+
},
128+
{
129+
url: "https://images.pexels.com/photos/58997/pexels-photo-58997.jpeg?auto=compress&cs=tinysrgb&w=800",
130+
caption: "x4, y4=dog",
131+
alt: "Cute cat 4"
132+
},
133+
{
134+
url: "https://images.pexels.com/photos/731022/pexels-photo-731022.jpeg?auto=compress&cs=tinysrgb&w=800",
135+
caption: "x5, y5=dog",
136+
alt: "Cute cat 5"
137+
},
138+
{
139+
url: "https://images.pexels.com/photos/551628/pexels-photo-551628.jpeg?auto=compress&cs=tinysrgb&w=800",
140+
caption: "x6, y6=dog",
141+
alt: "Cute cat 5"
142+
}
143+
]
144+
145+
<figure>
146+
<div style={{
147+
display: "grid",
148+
gridTemplateColumns: "repeat(auto-fit, minmax(200px, 1fr))",
149+
gap: "1rem",
150+
alignItems: "start"
151+
}}>
152+
{catDogGallery.map((cat, idx) => (
153+
<figure key={idx} style={{ margin: 0 }}> {/* remove default margin */}
154+
<img
155+
src={cat.url}
156+
alt={cat.alt}
157+
style={{ width: "100%", height: "auto", objectFit: "cover", display: "block" }}
158+
/>
159+
<figcaption style={{
160+
textAlign: "center",
161+
fontSize: "0.85rem",
162+
color: "#6b7280",
163+
margin: 0, // remove figcaption margin
164+
marginTop: "0.25rem" // optional small spacing
165+
}}>
166+
{cat.caption}
167+
</figcaption>
168+
</figure>
169+
))}
170+
</div>
171+
172+
<figcaption style={{
173+
textAlign: "center",
174+
marginTop: "1rem",
175+
fontStyle: "italic",
176+
color: "#6b7280"
177+
}}>
178+
A labelled dataset of cat and dog photos (source, Pexels.com).
179+
</figcaption>
180+
</figure>
181+
182+
183+
**Assumption** The core underlying assumption of generative modelling is that the data $x_1, \dots, x_n$, is drawn from some *unknown* underlying distribution $p_{data}( \cdot | y_i)$: for all $i \in 1, \dots, n$
184+
185+
<T block v='x_i ~ underbrace(p_"data" (dot | y_i), "unknown") .' />
186+
187+
**Goal** Using the empirical data distribution $x_i \sim p_{data}(\cdot | y_i)$, the goal is to *generate* new samples $x^{\text{new}}$ that look like they were drawn from the same *unknown* distribution $p_{data}$
188+
189+
190+
<T block v='x^"new cat" ~ p_"data" (dot | y="cat") ,' />
191+
<T block v='x^"new dog" ~ p_"data" (dot | y="dog") .' />
192+
193+
#### Text-Conditional Generative Modelling
194+
195+
### Unconditional Generative Modelling
196+
197+
#### 1 and 2-Dimensional Examples
198+
199+
#### Maximum Likelihood
200+
201+
### References
202+
- https://people.cs.umass.edu/~domke/courses/sml/10probabilistic.pdf
203+
- https://people.cs.umass.edu/~domke/courses/sml/11em.pdf

0 commit comments

Comments
 (0)