I’m running some debug tests right now with all my code in place. I’m getting an error on
Traceback (most recent call last):
File “./model.py”, line 446, in
File “./model.py”, line 418, in main
dev_las, dev_uas = model.eval(dev_sents, dev_arcs)
File “.\parser.py”, line 416, in minibatch_parse
– line where I call model.predict –
File “./model.py”, line 337, in predict
feats = self.transducer.pps2feats(partial_parses)
File “.\deptrans\data.py”, line 232, in pps2feats
File “.\data.py”, line 231, in
feats = (self.pp2feat(pp) for pp in pps)
File “.\data.py”, line 172, in pp2feat
word, tag = pp.sentence[sentence_idx]
IndexError: tuple index out of range
Not sure how I go about fixing this problem… It doesn’t seem like my problem - rather the error happens when calling model.predict. The stacktrace also doesn’t doesn’t have any clear indicators that it is my problem either.
The stacktrace shows that the problem comes from converting a partial parse to a feature vector triple (data.py > pp2feat).
Any insight would be appreciated.
edit: okay I think I figured it out, something to do with my batches
edit2: okay found the problem, rubber ducking helps