あまり深く理解してないので識者のツッコミ大歓迎
取り敢えず最低限だけ
# 補完を有効にする| #!/usr/bin/python | |
| # crf.py (by Graham Neubig) | |
| # This script trains conditional random fields (CRFs) | |
| # stdin: A corpus of WORD_POS WORD_POS WORD_POS sentences | |
| # stdout: Feature vectors for emission and transition properties | |
| from collections import defaultdict | |
| from math import log, exp | |
| import sys |