Cost error.Do not undestand, where I made mistake

The dimension mismatch means that you “hard-coded” the number of classes in your “one hot” routine.

The other error is that you are passing the results as logits to the cost function, right? So you need to specify “True” for that flag. Here’s a thread with a bit more info.

1 Like