Check failed: (reporter->AssertEQ(data->shape[data->shape.size() - 1], weight->shape[1])) is false: DenseRel: input dimension doesn't match, data shape=[1, 512], weight shape=[512, 1000]

I got the same error with torch v1.9.1. I downgraded it to v1.8.0 and it works.