├── .gitattributes ├── .github └── workflows │ └── build_lint_test.yml ├── .gitignore ├── LICENSE.md ├── README.md ├── environment.yml ├── examples ├── conditional_moons.ipynb └── moons.ipynb ├── nflows ├── __init__.py ├── distributions │ ├── __init__.py │ ├── base.py │ ├── discrete.py │ ├── mixture.py │ ├── normal.py │ └── uniform.py ├── flows │ ├── __init__.py │ ├── autoregressive.py │ ├── base.py │ └── realnvp.py ├── nn │ ├── __init__.py │ ├── nde │ │ ├── __init__.py │ │ └── made.py │ └── nets │ │ ├── __init__.py │ │ ├── mlp.py │ │ └── resnet.py ├── transforms │ ├── UMNN │ │ ├── MonotonicNormalizer.py │ │ └── __init__.py │ ├── __init__.py │ ├── autoregressive.py │ ├── base.py │ ├── conv.py │ ├── coupling.py │ ├── linear.py │ ├── lu.py │ ├── made.py │ ├── nonlinearities.py │ ├── normalization.py │ ├── orthogonal.py │ ├── permutations.py │ ├── qr.py │ ├── reshape.py │ ├── splines │ │ ├── __init__.py │ │ ├── cubic.py │ │ ├── linear.py │ │ ├── quadratic.py │ │ └── rational_quadratic.py │ ├── standard.py │ └── svd.py ├── utils │ ├── __init__.py │ ├── torchutils.py │ └── typechecks.py └── version.py ├── requirements.txt ├── setup.cfg ├── setup.py └── tests ├── __init__.py ├── distributions ├── __init__.py ├── discrete_test.py └── normal_test.py ├── flows ├── __init__.py ├── autoregressive_test.py ├── base_test.py └── realnvp_test.py ├── transforms ├── __init__.py ├── autoregressive_test.py ├── base_test.py ├── conv_test.py ├── coupling_test.py ├── linear_test.py ├── lu_test.py ├── made_test.py ├── nonlinearities_test.py ├── normalization_test.py ├── orthogonal_test.py ├── permutations_test.py ├── qr_test.py ├── reshape_test.py ├── splines │ ├── __init__.py │ ├── cubic_test.py │ ├── linear_test.py │ ├── quadratic_test.py │ └── rational_quadratic_test.py ├── standard_test.py ├── svd_test.py └── transform_test.py └── utils └── torchutils_test.py /.gitattributes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/.gitattributes -------------------------------------------------------------------------------- /.github/workflows/build_lint_test.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/.github/workflows/build_lint_test.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/.gitignore -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/LICENSE.md -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/README.md -------------------------------------------------------------------------------- /environment.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/environment.yml -------------------------------------------------------------------------------- /examples/conditional_moons.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/examples/conditional_moons.ipynb -------------------------------------------------------------------------------- /examples/moons.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/examples/moons.ipynb -------------------------------------------------------------------------------- /nflows/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /nflows/distributions/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/__init__.py -------------------------------------------------------------------------------- /nflows/distributions/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/base.py -------------------------------------------------------------------------------- /nflows/distributions/discrete.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/discrete.py -------------------------------------------------------------------------------- /nflows/distributions/mixture.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/mixture.py -------------------------------------------------------------------------------- /nflows/distributions/normal.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/normal.py -------------------------------------------------------------------------------- /nflows/distributions/uniform.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/distributions/uniform.py -------------------------------------------------------------------------------- /nflows/flows/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/flows/__init__.py -------------------------------------------------------------------------------- /nflows/flows/autoregressive.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/flows/autoregressive.py -------------------------------------------------------------------------------- /nflows/flows/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/flows/base.py -------------------------------------------------------------------------------- /nflows/flows/realnvp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/flows/realnvp.py -------------------------------------------------------------------------------- /nflows/nn/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /nflows/nn/nde/__init__.py: -------------------------------------------------------------------------------- 1 | from nflows.nn.nde.made import MixtureOfGaussiansMADE 2 | -------------------------------------------------------------------------------- /nflows/nn/nde/made.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/nn/nde/made.py -------------------------------------------------------------------------------- /nflows/nn/nets/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/nn/nets/__init__.py -------------------------------------------------------------------------------- /nflows/nn/nets/mlp.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/nn/nets/mlp.py -------------------------------------------------------------------------------- /nflows/nn/nets/resnet.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/nn/nets/resnet.py -------------------------------------------------------------------------------- /nflows/transforms/UMNN/MonotonicNormalizer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/UMNN/MonotonicNormalizer.py -------------------------------------------------------------------------------- /nflows/transforms/UMNN/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/UMNN/__init__.py -------------------------------------------------------------------------------- /nflows/transforms/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/__init__.py -------------------------------------------------------------------------------- /nflows/transforms/autoregressive.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/autoregressive.py -------------------------------------------------------------------------------- /nflows/transforms/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/base.py -------------------------------------------------------------------------------- /nflows/transforms/conv.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/conv.py -------------------------------------------------------------------------------- /nflows/transforms/coupling.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/coupling.py -------------------------------------------------------------------------------- /nflows/transforms/linear.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/linear.py -------------------------------------------------------------------------------- /nflows/transforms/lu.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/lu.py -------------------------------------------------------------------------------- /nflows/transforms/made.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/made.py -------------------------------------------------------------------------------- /nflows/transforms/nonlinearities.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/nonlinearities.py -------------------------------------------------------------------------------- /nflows/transforms/normalization.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/normalization.py -------------------------------------------------------------------------------- /nflows/transforms/orthogonal.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/orthogonal.py -------------------------------------------------------------------------------- /nflows/transforms/permutations.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/permutations.py -------------------------------------------------------------------------------- /nflows/transforms/qr.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/qr.py -------------------------------------------------------------------------------- /nflows/transforms/reshape.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/reshape.py -------------------------------------------------------------------------------- /nflows/transforms/splines/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/splines/__init__.py -------------------------------------------------------------------------------- /nflows/transforms/splines/cubic.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/splines/cubic.py -------------------------------------------------------------------------------- /nflows/transforms/splines/linear.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/splines/linear.py -------------------------------------------------------------------------------- /nflows/transforms/splines/quadratic.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/splines/quadratic.py -------------------------------------------------------------------------------- /nflows/transforms/splines/rational_quadratic.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/splines/rational_quadratic.py -------------------------------------------------------------------------------- /nflows/transforms/standard.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/standard.py -------------------------------------------------------------------------------- /nflows/transforms/svd.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/transforms/svd.py -------------------------------------------------------------------------------- /nflows/utils/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/utils/__init__.py -------------------------------------------------------------------------------- /nflows/utils/torchutils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/utils/torchutils.py -------------------------------------------------------------------------------- /nflows/utils/typechecks.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/utils/typechecks.py -------------------------------------------------------------------------------- /nflows/version.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/nflows/version.py -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/requirements.txt -------------------------------------------------------------------------------- /setup.cfg: -------------------------------------------------------------------------------- 1 | [metadata] 2 | description-file = README.md 3 | 4 | [tool:pytest] 5 | pep8maxlinelength = 88 6 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/setup.py -------------------------------------------------------------------------------- /tests/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/distributions/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/distributions/discrete_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/distributions/discrete_test.py -------------------------------------------------------------------------------- /tests/distributions/normal_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/distributions/normal_test.py -------------------------------------------------------------------------------- /tests/flows/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/flows/autoregressive_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/flows/autoregressive_test.py -------------------------------------------------------------------------------- /tests/flows/base_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/flows/base_test.py -------------------------------------------------------------------------------- /tests/flows/realnvp_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/flows/realnvp_test.py -------------------------------------------------------------------------------- /tests/transforms/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/transforms/autoregressive_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/autoregressive_test.py -------------------------------------------------------------------------------- /tests/transforms/base_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/base_test.py -------------------------------------------------------------------------------- /tests/transforms/conv_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/conv_test.py -------------------------------------------------------------------------------- /tests/transforms/coupling_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/coupling_test.py -------------------------------------------------------------------------------- /tests/transforms/linear_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/linear_test.py -------------------------------------------------------------------------------- /tests/transforms/lu_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/lu_test.py -------------------------------------------------------------------------------- /tests/transforms/made_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/made_test.py -------------------------------------------------------------------------------- /tests/transforms/nonlinearities_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/nonlinearities_test.py -------------------------------------------------------------------------------- /tests/transforms/normalization_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/normalization_test.py -------------------------------------------------------------------------------- /tests/transforms/orthogonal_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/orthogonal_test.py -------------------------------------------------------------------------------- /tests/transforms/permutations_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/permutations_test.py -------------------------------------------------------------------------------- /tests/transforms/qr_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/qr_test.py -------------------------------------------------------------------------------- /tests/transforms/reshape_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/reshape_test.py -------------------------------------------------------------------------------- /tests/transforms/splines/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/transforms/splines/cubic_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/splines/cubic_test.py -------------------------------------------------------------------------------- /tests/transforms/splines/linear_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/splines/linear_test.py -------------------------------------------------------------------------------- /tests/transforms/splines/quadratic_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/splines/quadratic_test.py -------------------------------------------------------------------------------- /tests/transforms/splines/rational_quadratic_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/splines/rational_quadratic_test.py -------------------------------------------------------------------------------- /tests/transforms/standard_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/standard_test.py -------------------------------------------------------------------------------- /tests/transforms/svd_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/svd_test.py -------------------------------------------------------------------------------- /tests/transforms/transform_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/transforms/transform_test.py -------------------------------------------------------------------------------- /tests/utils/torchutils_test.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bayesiains/nflows/HEAD/tests/utils/torchutils_test.py --------------------------------------------------------------------------------