首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
  • 您找到你想要的搜索结果了吗?
    是的
    没有找到

    NLTK For Python3版本变化说明

    grammar: ContextFreeGrammar → CFG, WeightedGrammar → PCFG, StatisticalDependencyGrammar → ProbabilisticDependencyGrammar, WeightedProduction → ProbabilisticProduction draw.tree: TreeSegmentWidget.node() → TreeSegmentWidget.label(), TreeSegmentWidget.set_node() → TreeSegmentWidget.set_label() parsers: nbest_parse() → parse() ccg.parse.chart: EdgeI.next() → EdgeI.nextsym() Chunk parser: top_node → root_label; chunk_node → chunk_label WordNet properties are now access methods, e.g. Synset.definition → Synset.definition() sem.relextract: mk_pairs() → _tree2semi_rel(), mk_reldicts() → semi_rel2reldict(), show_clause() → clause(), show_raw_rtuple() → rtuple() corpusname.tagged_words(simplify_tags=True) → corpusname.tagged_words(tagset=’universal’) util.clean_html() → BeautifulSoup.get_text(). clean_html() is now dropped, install & use BeautifulSoup or some other html parser instead. util.ibigrams() → util.bigrams() util.ingrams() → util.ngrams() util.itrigrams() → util.trigrams() metrics.windowdiff → metrics.segmentation.windowdiff(), metrics.windowdiff.demo() was removed. parse.generate2 was re-written and merged into parse.generate

    02
    领券