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

changed nn.Tanh() output layers to nn.Sigmoid() #63

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

HareshKarnan
Copy link

@HareshKarnan HareshKarnan commented Jul 7, 2022

The input image is normalized between 0-1, so the output should be a nn.Sigmoid() layer instead of nn.Tanh(). Note that nn.Tanh() may also work, but using nn.Sigmoid() is more appropriate and will make the learning easier since the network can now only output values between 0-1 every pixel.

@DerEchteFeuerpfeil
Copy link

Had the same issue with the VanillaVAE out-of-the-box when converting first iteration samples to a PIL Image. Commenting to bump this up.

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.

None yet

2 participants