
Security News
VulnCon 2025: NVD Scraps Industry Consortium Plan, Raising Questions About Reform
At VulnCon 2025, NIST scrapped its NVD consortium plans, admitted it can't keep up with CVEs, and outlined automation efforts amid a mounting backlog.
glasflow is a Python library containing a collection of Normalizing flows using PyTorch. It builds upon nflows.
glasflow is available to install via pip
:
pip install glasflow
or via conda
:
conda install glasflow -c conda-forge
Important: glasflow
supports using CUDA devices but it is not a requirement and in most uses cases it provides little to no benefit.
By default the version of PyTorch installed by pip
or conda
will not necessarily match the drivers on your system, to install a different version with the correct CUDA support see the PyTorch homepage for instructions: https://pytorch.org/.
To define a RealNVP flow:
from glasflow import RealNVP
# define RealNVP flow. Change hyperparameters as necessary.
flow = RealNVP(
n_inputs=2,
n_transforms=5,
n_neurons=32,
batch_norm_between_transforms=True
)
Please see glasflow/examples for a typical training regime example.
glasflow uses a fork of nflows which is included as submodule in glasflow and can used imported as follows:
import glasflow.nflows as nflows
It contains various bugfixes which, as of writing this, are not included in a current release of nflows
.
There is also the option to use an independent install of nflows (if installed) by setting an environment variable.
export GLASFLOW_USE_NFLOWS=True
After setting this variable glasflow.nflows
will point to the version of nflows installed in the current python environment.
Note: this must be set prior to importing glasflow.
Pull requests are welcome. You can review the contribution guidelines here. For major changes, please open an issue first to discuss what you would like to change.
If you use glasflow in your work please cite our DOI. We also recommend you also cite nflows following the guidelines in the nflows readme.
FAQs
Normalising flows using nflows
We found that glasflow demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
At VulnCon 2025, NIST scrapped its NVD consortium plans, admitted it can't keep up with CVEs, and outlined automation efforts amid a mounting backlog.
Product
We redesigned our GitHub PR comments to deliver clear, actionable security insights without adding noise to your workflow.
Product
Our redesigned Repositories page adds alert severity, filtering, and tabs for faster triage and clearer insights across all your projects.