Skip to content

ryoryon66/normalizing_flow

Repository files navigation

normalizing flow with coupling layers

Visualized how the prior distribution changes into the target distribution.

The prior distribution used in this code is N(0,I) and the target distribution is eclipse-shaped. demo demo image demo

Double moon version

demo

model architecture

NormalizingFlow(
  (layers): ModuleList(
    (0-9): 10 x CouplingLayer(
      (s): Sequential(
        (0): Linear(in_features=2, out_features=128, bias=True)
        (1): ReLU()
        (2): Linear(in_features=128, out_features=128, bias=True)
        (3): ReLU()
        (4): Linear(in_features=128, out_features=1, bias=True)
        (5): Tanh()
      )
      (t): Sequential(
        (0): Linear(in_features=2, out_features=128, bias=True)
        (1): ReLU()
        (2): Linear(in_features=128, out_features=128, bias=True)
        (3): ReLU()
        (4): Linear(in_features=128, out_features=1, bias=True)
      )
    )
  )
)

About

visualize normalizing flow algorithm

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages