Paper Database & Bibliography
/
Image Translation Literature Search
/
GAN
/
SGAN: Semi-supervised GAN
Search
Share
SGAN: Semi-supervised GAN
라온피플(주) : 네이버 블로그
Python, Machine & Deep Learning
Python, Machine Learning & Deep Learning
Real Data
p
m
o
d
e
l
(
y
=
k
+
1
∣
x
)
=
e
x
p
(
l
k
+
1
)
Σ
j
=
1
k
+
1
e
x
p
(
l
j
)
p_{model}(y=k+1|x)=\frac{exp(l_{k+1})}{\Sigma^{k+1}_{j=1}exp(l_j)}
p
m
o
d
e
l
(
y
=
k
+
1∣
x
)
=
Σ
j
=
1
k
+
1
e
x
p
(
l
j
)
e
x
p
(
l
k
+
1
)
Fake Data
p
m
o
d
e
l
(
y
=
k
+
1
∣
x
,
i
<
k
+
1
)
=
e
x
p
(
l
i
)
Σ
j
=
1
k
+
1
e
x
p
(
l
j
)
p_{model}(y=k+1|x,i<k+1)=\frac{exp(l_{i})}{\Sigma^{k+1}_{j=1}exp(l_j)}
p
m
o
d
e
l
(
y
=
k
+
1∣
x
,
i
<
k
+
1
)
=
Σ
j
=
1
k
+
1
e
x
p
(
l
j
)
e
x
p
(
l
i
)
Discriminator Loss
L
D
=
L
D
s
u
p
e
r
v
i
s
e
d
+
L
D
u
n
s
u
p
e
r
v
i
s
e
d
L_D=L_{D_{supervised}}+L_{D_{unsupervised}}
L
D
=
L
D
s
u
p
er
v
i
se
d
+
L
D
u
n
s
u
p
er
v
i
se
d
L
D
s
u
p
.
=
−
E
x
,
y
p
d
a
t
a
l
o
g
[
p
m
o
d
e
l
(
y
=
i
∣
x
,
i
<
k
+
1
)
]
L_{D_{sup.}}=-\mathbb{E}_{x,y~p_{data}}log[p_{model}(y=i|x,i<k+1)]
L
D
s
u
p
.
=
−
E
x
,
y
p
d
a
t
a
l
o
g
[
p
m
o
d
e
l
(
y
=
i
∣
x
,
i
<
k
+
1
)]
→ 이미 class를 알고 있기 때문에.
L
D
u
n
s
u
p
.
=
L_{D_{unsup.}}=
L
D
u
n
s
u
p
.
=
−
E
x
,
y
p
d
a
t
a
l
o
g
[
1
−
p
m
o
d
e
l
(
y
=
k
+
1
∣
x
)
]
\mathbb{-E}_{x,y~p_{data}}log[1-p_{model}(y=k+1|x)]
−
E
x
,
y
p
d
a
t
a
l
o
g
[
1
−
p
m
o
d
e
l
(
y
=
k
+
1∣
x
)]
−
E
x
G
l
o
g
[
p
m
o
d
e
l
(
y
=
k
+
1
∣
x
)
]
-\mathbb{E}_{x~G}log[p_{model}(y=k+1|x)]
−
E
x
G
l
o
g
[
p
m
o
d
e
l
(
y
=
k
+
1∣
x
)]
→ real data를 '진짜'로 분류하는 것 + fake data를 '가짜'로 분류해야 하는 것
Generator Loss
L
G
f
e
a
t
u
r
e
m
a
t
c
h
i
n
g
=
∣
∣
E
x
p
d
a
t
a
f
(
x
)
−
E
x
G
f
(
x
)
∣
∣
2
2
L_{G_{feature matching}}=||\mathbb{E}_{x~p_{data}}f(x)-\mathbb{E}_{x~G}f(x)||^2_2
L
G
f
e
a
t
u
re
ma
t
c
hin
g
=
∣∣
E
x
p
d
a
t
a
f
(
x
)
−
E
x
G
f
(
x
)
∣
∣
2
2