【问题标题】:Loading treebank corpus with brown's tagset使用 brown 的标签集加载树库语料库
【发布时间】:2015-07-22 16:41:30
【问题描述】:

我有一个来自 nltk 的 WSJ 树库语料库。我想用棕色语料库的标签集加载它。有可能吗?

import nltk
wsj = nltk.corpus.treebank.tagged_sents(tagset ='universal') # universal tags
wsj2 = nltk.corpus.treebank.tagged_sents() # treebank specific tags

【问题讨论】:

    标签: python-2.7 nlp nltk corpus tagged-corpus


    【解决方案1】:

    根据thread 中的讨论,这是不可能的。

    到目前为止,NLTK 仅提供将特定标签集映射到通用标签集的可能性。 也许讨论中建议的解决方案之一可以提供帮助:

    显然 NLTK 尚不支持此功能,但请参阅 Dan Zeman 的 Interset 工具或我的脚本https://gist.github.com/nschneid/6476715

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2014-12-02
      • 1970-01-01
      • 1970-01-01
      • 2017-07-26
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多