tokenizers.py 文件源码

python
阅读 29 收藏 0 点赞 0 评论 0

项目:acl2017-interactive_summarizer 作者: UKPLab 项目源码 文件源码
def _sentence_tokenizer(self, language):
        try:
            path = to_string("tokenizers/punkt/%s.pickle") % to_string(language)
            return nltk.data.load(path)
        except (LookupError, zipfile.BadZipfile):
            raise LookupError(
                "NLTK tokenizers are missing. Download them by following command: "
                '''python -c "import nltk; nltk.download('punkt')"'''
            )
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号