Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

train_baseline error:IndexError: index 0 is out of bounds for axis 0 with size 0 #16

Open
fendouai opened this issue Apr 19, 2019 · 0 comments

Comments

@fendouai
Copy link

Train Epoch 0 loss 63.578703 855.35 (sec) <<
Valid Epoch 0 loss 24.911499
P:0.920358 R:0.946347 F:0.933171

Traceback (most recent call last):
File "train_baseline.py", line 176, in
train()
File "train_baseline.py", line 118, in train
predict= model.predict_step(sess, input_x)
File "/home/bigdata/CWS_Dict/same-domain/models/BaselineModel.py", line 126, in predict_step
viterbi_sequence, _=crf.viterbi_decode(unary_score[:length],transition_param)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/contrib/crf/python/ops/crf.py", line 299, in viterbi_decode
trellis[0] = score[0]
IndexError: index 0 is out of bounds for axis 0 with size 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant