mirror of
https://github.com/explosion/spaCy.git
synced 2024-12-26 01:46:28 +03:00
* Re-enable entity training
This commit is contained in:
parent
f729164c01
commit
0c91dd9e15
|
@ -226,10 +226,10 @@ def train(Language, train_loc, model_dir, n_iter=15, feat_set=u'basic', seed=0,
|
||||||
gold = GoldParse(tokens, annot_tuples)
|
gold = GoldParse(tokens, annot_tuples)
|
||||||
nlp.tagger(tokens)
|
nlp.tagger(tokens)
|
||||||
nlp.parser.train(tokens, gold, force_gold=force_gold)
|
nlp.parser.train(tokens, gold, force_gold=force_gold)
|
||||||
#nlp.entity.train(tokens, gold, force_gold=force_gold)
|
nlp.entity.train(tokens, gold, force_gold=force_gold)
|
||||||
nlp.tagger.train(tokens, gold.tags)
|
nlp.tagger.train(tokens, gold.tags)
|
||||||
|
|
||||||
#nlp.entity(tokens)
|
nlp.entity(tokens)
|
||||||
nlp.parser(tokens)
|
nlp.parser(tokens)
|
||||||
scorer.score(tokens, gold, verbose=False)
|
scorer.score(tokens, gold, verbose=False)
|
||||||
print '%d:\t%.3f\t%.3f\t%.3f' % (itn, scorer.uas, scorer.ents_f, scorer.tags_acc)
|
print '%d:\t%.3f\t%.3f\t%.3f' % (itn, scorer.uas, scorer.ents_f, scorer.tags_acc)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user