bear63 / sceneReco

ctpn+crnn Scene character recognition
943 stars 371 forks source link

confusion about squeeze(2) in the file crnnport.py #11

Closed FrBernkastel closed 6 years ago

FrBernkastel commented 7 years ago

According to my experiment, i found that the dimension of preds (line 75) is 3. After preds.max(2), its dimension is 2. As a result, preds.squeeze(2) throws an exception, since axis 2 exceeds the range of dimension.

So, the command line reminds me that "RuntimeError: dimension out of range (expected to be in range of [-2, 1], but got 2) "

power630 commented 7 years ago

i've got the same problem

FrBernkastel commented 7 years ago

And I deleted this line and everything is OK.

power630 commented 7 years ago

thanks a lot @FrBernkastel