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

[compute_numeric_gradient] Use torch.flatten instead of view(-1). #5

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

Conversation

mhaz
Copy link

@mhaz mhaz commented Jan 21, 2022

I ran into technical issues when doing the convolutional network exercise from assignment 3 for the 2019 iteration of the class.
The issue was the same as #4 and stemmed from using .view(-1) to flatten the f(x+h) and f(x-h) tensors in the numerical gradient evaluation. Using flatten instead seems to fix the problem.

Unfortunately, I ran into another runtime error the "Batchnorm for deep convolutional networks" subsection. It seems to stem from the implementation of FastConv, but this might be more than I can chew right now.

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.

1 participant