SeanNaren / warp-ctc

Pytorch Bindings for warp-ctc
Apache License 2.0
756 stars 271 forks source link

TypeError: initializer for ctype 'struct THIntTensor *' must be a pointer to same type, not cdata 'struct THCudaTensor * #49

Closed zhly0 closed 6 years ago

zhly0 commented 6 years ago

Is anybody encounter this problem?

zhengwh commented 6 years ago
loss = criterion(preds, text, preds_size, label_len)

only preds can be cuda type, the other three shoud be cpu paramters


preds torch.Size([65, 8, 5530]) True text torch.Size([78]) False preds_size torch.Size([8]) False length torch.Size([8]) False


maybe this will helps you

zhly0 commented 6 years ago

Thanks for reply,I will try!