-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AffineAutoregressive leaks global state #42
Comments
Thanks for catching this! The |
@feynmanliang could you post a code snippet here to reproduce? This would save me some time |
|
Make the argument in question an optional and instantiate object in method if None |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This static attribute https://github.com/stefanwebb/flowtorch/blob/master/flowtorch/bijectors/affine_autoregressive.py#L18 is a global singleton and leaks across runs.
To repro unexpected behavior:
AffineAutoregressive
against a 2D distribution (default_param_fn.permutation
gets set to a size 2 permutation)AffineAutoregressive
and train it against something that is not 2D; this will fail becausedefault_param_fn.permutation
is already set so the new shape is not used.The text was updated successfully, but these errors were encountered: