Closed the-butterfly closed 5 years ago
emmm…… The problem is due to the different behavior of torch.nonzero() in Pytorch 1.0.
And just change file seg_ctc_ent_log_fb.py
in line 119, replace it by:
# if len(token_equals.size()) == 2: previous
if token_equals.size(0) != 0: # compatible for pytorch 1.0
When use pytorch 1.0, the loss function may not work. Like following:
BUT it works pretty good in pytorch v0.4.1, Can anyone help? @liuhu-bigeye @jin-s13