I think it is easy to calculate the number of elements in PyTorch. Suppose you have a model called net. You can use the following snippet to calculate the number of parameter in your model:
count = 0
for p in net.parameters():
    count += p.data.nelement()