Open shenao1994 opened 4 years ago
I don't really have enough information to help you debug this. All I can say is that there should be one fewer cutpoint than the number of classes that you're predicting. In your case, you have 6 classes, and you should have 5 cutpoints.
@shenao1994 https://data.princeton.edu/wws509/notes/c6s5
For those that stumble upon this, the error is because your model that you are passing into OrdinalLogisticModel
outputs n_classes
values - it should output a single scalar value.
RuntimeError: The size of tensor a (5) must match the size of tensor b (6) at non-singleton dimension 1 I'm working on a six classification task[0, 1, 2, 3, 4, 5].I found that cutpoints = num_ class - 1 in the code。 But in this way, the dimensions of cutpoints and X are not equal. I've seen your example, but I still don't know how to solve it. thank you!