chokkan / crfsuite

CRFsuite: a fast implementation of Conditional Random Fields (CRFs)
http://www.chokkan.org/software/crfsuite/
Other
641 stars 208 forks source link

why some reference lable is null generated by tag -r #88

Open zhugw opened 7 years ago

zhugw commented 7 years ago

After training

crfsuite learn -m review.model train.data

I got a model then I test it's effect

crfsuite tag -r -m review.model test.data > result

but I found many null

cat -n result | grep 'null'
    33  (null)  N
    35  (null)  N
    37  (null)  N
    46  (null)  N
    50  (null)  N
    59  (null)  N
    68  (null)  N
    77  (null)  N
    97  (null)  N
   118  (null)  N
   134  (null)  N
   139  (null)  N
   196  (null)  N
   205  (null)  N
   263  (null)  N
   273  (null)  N
   287  (null)  N
   288  (null)  N
   324  (null)  N
   330  (null)  N
   342  (null)  N
   343  (null)  N
   347  (null)  N
   349  (null)  N
   366  (null)  N

but actually in test.data they have tagged,

cat -n result | grep 'null' | awk '{print $1}' | xargs -i{} sed -n '{}p' test.data | awk '{print $1}'
SEV-KY-95
LJ-119
LJ-119
SEV-PY-50
CPU-CM-146
HX-116
LOG-HGL-137
HX-116
HH-94
TH-18
LOG-HK-92
CAM-HX-116
KY-95
GY-149
NET-HX-151
SYS-BL-30
NET-WY-97
NET-WY-97
NET-BK-100
SCN-KY-95
BAT-BNY-168
BAT-RY-53
KY-95
BAT-HX-151
KY-95