With hidden_size = 2, I get the following error:

RuntimeError: input and target have different number of elements: input[1 x 100 x 2] has 200 elements, while target[1 x 100 x 1] has 100 elements at /Users/soumith/miniconda2/conda-bld/pytorch_1503975723910/work/torch/lib/THNN/generic/MSECriterion.c:1234