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

Question about initialization in class MyConvo2d? #1

Closed
jionie opened this issue Feb 14, 2019 · 1 comment
Closed

Question about initialization in class MyConvo2d? #1

jionie opened this issue Feb 14, 2019 · 1 comment

Comments

@jionie
Copy link

jionie commented Feb 14, 2019

Hi! Thanks for your great code! I have one question about weights initialization in MyConvo2d. It seems that you had set self.he_init = he_init, but you didn't use it. And in test_compare_tf_to.py, weights_init(m) seems don't use he_init too.

@jalola
Copy link
Owner

jalola commented Feb 15, 2019

Hi Joinie,

Yes, we don't use random weight initialization in this repo because this is testing repo (of course we do use he_init in main GAN repo).

As we mentioned in the README: "We inject the same weights init and inputs into layers of TensorFlow and Pytorch that we want to compare. For example, we set 5e-2 for the weights of Conv2d layer in both TensorFlow and Pytorch. Then we passed the same random input to those 2 layers and finally we compared 2 outputs from TensorFlow tensor and Pytorch tensor."

We assign weight = 0.05 here:

Hope it clarifies.

@jalola jalola closed this as completed Feb 18, 2019
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

No branches or pull requests

2 participants