Giter VIP home page Giter VIP logo

normalizing-flows's Introduction

Normalizing Flows

Note: There are some bugs in the implementation of VAE+PF. For an updated Pytorch implementation, please check: abdulfatir/planar-flow-pytorch.

Accompanying documentation

  1. Normalizing Flows: Planar and Radial Flows
  2. Technical Report

Results

Variational Inference with Normalizing Flows (Rezende and Mohamed)

The function that planar flow uses doesn't have analytic inverse which makes it unsuitable for direct likelihood estimation using the data. It can work well in VAEs though because inversion isn't required. However, for cases when the analytic target density is available, KL-divergence can be minimized explicitly (excluding constant terms). Following are the results for two complex 2D densities similar to the ones in the paper. The second column shows samples obtained using MCMC (See notebooks/Metropolis-Hastings.ipynb). The third and fourth columns show results using planar flows of different lengths (see notebooks/PlanarFlow-Example1.ipynb and notebooks/PlanarFlow-Example2.ipynb). During the experiments I found that minimizing KL is not always stable and doesn't always reach a good solution (especially for density 2).

True Density Samples (using Metropolis-Hastings) Samples (using Planar Flow; K = 4) Samples (using Planar Flow; K = 16)

VAE with Planar Flow

[REMOVED]

There are some bugs in the implementation of VAE+PF. For an updated Pytorch implementation, please check: abdulfatir/planar-flow-pytorch.

Note

Originally, this repository contained notes and code on normalizing flows which we did as a part of a course project (CS6202 @ NUS). Some ideas are borrowed from this repo.

normalizing-flows's People

Contributors

abdulfatir avatar devamanyu avatar remmyzen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

normalizing-flows's Issues

Some questions about the results of the experiment

Thanks for sharing, but I want to know why VAE's Test Lower Bound on the MNIST dataset can reach -79.4๏ผŸ In the original paper (Variational Inference with Normalizing Flows), when K=20, the value of Test Lower Bound of VAE is -86.5.

constraint for invertibility

Thanks for the nice work. May I know how and where do you enforce the constraint required to obtain invertible flows? Specifically, the condition w^Tu >= -1 as described in the appendix of the Normalizing flows paper.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.