【发布时间】:2017-05-09 01:50:10
【问题描述】:
当我在训练数据 (train.txt) 上运行 CRF++ 时,出现以下错误
C:\Users\2012\Desktop\CRF_Software_Package\CRF++-0.58>crf_learn template train.d
ata model
CRF++: Yet Another CRF Tool Kit
Copyright (C) 2005-2013 Taku Kudo, All rights reserved.
reading training data: tagger.cpp(393) [feature_index_->buildFeatures(this)]
0.00 s
我的训练数据包含 Unicode 字符,数据是使用记事本保存的(编码 = Unicode big indian)
我不确定是模板问题还是训练数据格式问题。如何检查训练数据的格式?
【问题讨论】:
-
您找出问题所在了吗?我得到了同样的结果,我的 template_file 只包含
U01:%x[0,1],请您指出解决方案吗? -
您只需更改包含训练集的文件的编码。尝试使用 UTF-8。
-
@Wahedsaw 我将编码更改为 UTF-8,仍然是同样的错误。您还知道其他解决方案吗?
-
@cerr 您的问题可能有所不同。 [0,1] 可能是指存储标签的列,您不能这样做!