[부스트캠프 AI tech DL Basic] week04 (2022.02.09)

redgreen·2022년 2월 10일
0

07 Sequential Models - RNN

- Vanilla RNN(Recurrent Neural Network)

  • long-term dependencies가 약함

- LSTM(Long Short Term Memory)

  • forget gate: 버릴 정보를 결정함
  • input gate: cell state에 저장할 정보를 결정함
  • output gate: updated cell state를 이용해서 output을 만듦

- GRU(Gated Recurrent Unit)

  • gate가 2개(reset gate, update gate)
  • No cell state, just hidden state

(07 - 실습) LSTM(colab)

08 Sequential Models - Transformer

09강 Generative Models 1

  • explicit model: 입력이 주어졌을 때 확률 값을 얻어낼 수 있는 모델
  • implicit model: 단순히 generation만 할 수 있는 모델
  • unsupervised representation learning

Basic Discrete Distributions

  • Bernoulli dist.
    : XX ~ Ber(p)Ber(p)
  • Categorical dist.
    : YY ~ Cat(pCat(p1,...ppm)

Example

  • (r,g,b)(r, g, b) ~ p(R,G,B)p(R, G, B)
  • 256 x 256 x 256개의 경우(case)
    --> 2563 - 1개의 파라미터가 필요

Structure Through Independence

  • nn개의 픽셀들이 모두 independent하다고 가정
    : pp(xx1, ..., xxnn) = pp(xx1)pp(xx2)...pp(xxnn)
  • 가능한 경우의 수(possible state)?
    : 2nn
  • pp(xx1, ..., xxnn)를 위해 필요한 파라미터 수?
    : nn

Conditional Independence

  • Three important rules
    • Chain rule:
      pp(xx1, …, xxnn)
      = pp(xx1)pp(xx2 |xx1)pp(xx3 |xx1, xx2)⋯pp(xxnn |xx1, ⋯, xxnn−1)
      parmeter 수:
      • p(xp(x1)): 1 parameter
      • p(xp(x2x|x1)): 2 parameters
        :p(xp(x2x|x1=0)0), p(xp(x2x|x1=1)1)인 경우
      • p(xp(x3x|x1,x, x2)): 4 parameters
        Hence, 1 + 2 + 22+...+2n1n-1 = 2nn- 1

    • Bayes' rule:
    • conditional independence:
      -zz가 주어졌을 때 x,yx, yindependent하다면,
    • Markov assumption:
      i+1i+1 번째 값은 ii번째 값과 dependence하고 1...i11...i-1번째 값과는 independence 하다.
      - by leveraging Markov assumtion
      pp(xx1, …, xxnn)
      = pp(xx1)pp(xx2 |xx1)pp(xx3 |xx2)⋯pp(xxnn |xxnn−1)
      으로 chain rule식을 바꿀 수 있다.
      parameter
      : 2n12n - 1

Auto-regressive Model

  • 하나의 정보가 이전 정보(1개 or all)에 dependent 한 것
  • Let's use the chain rule to factor the joint dist.
    p(xp(x1:784)=p(x) = p(x1)p(x)p(x2x| x1)p(x)p(x3x|x1:2))⋯

NADE: Neural Autoregressive Density Estimator

  • explicit model

Pixel RNN

  • Row LSTM
  • Diagonal BiLSTM

10 Generative Models 2

Question

  • AutoEncoder는 generative model인가?
  • 엄밀한 의미에서 explicit한 모델

Variational Auto-encoder(논문)

  • Variational inference(VI)
    : posterior distribution을 근사하는 variational distribution을 최적화한 것이 목적

    • posterior distribution: ppθθ(zx)(z|x)
    • Variational distribution: qqϕϕ(zx)(z|x)
    • 특히 KL divergence between true posterior를 minimize하는 variational distribution을 찾는 것이 목적
  • ELBO?
    : loglogθP(x)P(x), 데이터 log-likelihood의 Evidence Lower Bound
  • KL Divergence(wiki)?
    :

Adversarial Auto-encoder(colab)



GAN(Generative Adversarial Network)(1시간만에 GAN이해하기)

GAN Objective

  • two player minimax game between Generator and Discriminator
profile
인공지능 꿈나무

0개의 댓글