koth/kcws

如何使用最新版本tensorflow?

hellomotor opened this issue · 1 comments

我使用的tensorflow版本为1.8.0版本(gpu), 按照训练说明--准备语料, 训练模型,导出模型, 一切都正常。
在使用新导出的模型进行分词时,
./bazel-bin/kcws/cc/test_seg -model_path kcws/models/seg_model_2.pbtxt -vocab_path kcws/models/basic_vocab.txt -test_sentence "这样的人才能经受住考验"
报告如下错误:
Could not create Tensorflow Graph: Not found: Op type not registered 'GatherV2' in binary running on localhost.localdomain. Make sure the Op and Kernel are registered in the binary running in this process.
经查看WORKSPACE里的脚本, 发现test_seg链接的tensorflow版本为1.2.0, 我想问题可能出在这里, 请问如何使kcws链接新版本的tensorflow, 谢谢!

在Closed Issue中找到了相关信息,谢谢!