Skip to content
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

Add tests exposing BatchNormalization bug(s)? when used in GANs. #5647

Closed
wants to merge 1 commit into from

Conversation

mjdietzx
Copy link
Contributor

@mjdietzx mjdietzx commented Mar 8, 2017

Reproducing:

Both tests fail due to bug. They will pass if batch_normalization flag is set to False in generator and discriminator for their respective tests.

@fchollet
Copy link
Member

fchollet commented Mar 9, 2017

Since this is a unit test, it should be reducible to something much shorter and much simpler. This looks like an integration test for GANs. Surely the issue you're trying to evidence has nothing to do with GANs themselves.

@buggi22
Copy link

buggi22 commented Mar 15, 2017

In case it might help, here's a short script that isolates and reproduces the error, running with the TensorFlow backend:
https://gist.github.com/buggi22/753ef6e8bde23d97310e354a8450a2b7

@fchollet
Copy link
Member

@buggi22 this is helpful. It looks like an update reuse issue when applying a model that contained a BN layer to new inputs. The issue will deal with:

  • BN layer call method
  • base Layer add_update method
  • Container call method

Anyone wants to look into it?

@abhaikollara
Copy link
Contributor

In case it helps,

  • The issue only occurs for Tensorflow
  • For the code given by @buggi22 the error disappears if you fit m2 before creating m3. See here

@fchollet
Copy link
Member

This is helpful. In particular the second point sounds like it should be enough to figure out the cause. Unfortunately I still won't have time to look into it for the time being. Hopefully someone else can...

@fchollet
Copy link
Member

fchollet commented Apr 6, 2017

Fixed; added unit test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants