erickrf/nlpnet

KeyError while using nlpnet-test.py with --id

bakszero opened this issue · 1 comments

nlpnet-test.py srl -v --gold outputs/projected/final_nlpnet.txt --data py3-models/ --id
/home/baks/GSOC/new/local/lib/python2.7/site-packages/h5py/init.py:36: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88
from ._conv import register_converters as _register_converters
/home/baks/GSOC/new/local/lib/python2.7/site-packages/h5py/init.py:45: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88
from . import h5a, h5d, h5ds, h5f, h5fd, h5g, h5r, h5s, h5t, h5p, h5z
/home/baks/GSOC/new/local/lib/python2.7/site-packages/h5py/_hl/group.py:22: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88
from .. import h5g, h5i, h5o, h5r, h5t, h5l, h5p
Loading network
Done
Loading text reader...
Loading vocabulary
Done. Dictionary size is 3639 types
Done
Traceback (most recent call last):
File "/home/baks/GSOC/new/bin/nlpnet-test.py", line 708, in
evaluate_srl_identify(args.gold)
File "/home/baks/GSOC/new/bin/nlpnet-test.py", line 580, in evaluate_srl_identify
gold_itd, net_itd)
File "/home/baks/GSOC/new/bin/nlpnet-test.py", line 296, in sentence_recall
net_tag = network_tag_dict[net_tag]
KeyError: 48

Sorry for the late answer. It sounds like one of the files in the data directory is not compatible with the trained model. Are you sure you didn't mix any files?