Created
June 9, 2017 09:13
-
-
Save jaypatravali/eda03580879c442195ead7a0ca559596 to your computer and use it in GitHub Desktop.
print no of params in model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# get the number of model parameters | |
print('Number of model parameters: {}'.format( | |
sum([p.data.nelement() for p in model.parameters()]))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment