In your second code snippet you are not using the model, so where does the pooling operation come from?
Anyway, could you post the shapes of drop1 in your forward method?
Also, could you update to the latest nightly build, as we’ve seen this error for an invalid grid size calling into the pooling kernel, which should have been fixed already.