# torchtext

> 原文： [https://pytorch.org/text](https://pytorch.org/text)

[`torchtext`](#module-torchtext "torchtext") 程序包包含数据处理实用程序和流行的自然语言数据集。

包装参考

*   [torchtext](#)
*   [torchtext.data](data.html)
    *   [数据集，批处理和示例](data.html#dataset-batch-and-example)
    *   [字段](data.html#fields)
    *   [迭代器](data.html#iterators)
    *   [管道](data.html#pipeline)
    *   [功能](data.html#functions)
*   [torchtext.data.utils](data_utils.html)
    *   [get_tokenizer](data_utils.html#get-tokenizer)
    *   [ngrams_iterator](data_utils.html#ngrams-iterator)
*   [torchtext.data.functional](data_functional.html)
    *   [generate_sp_model](data_functional.html#generate-sp-model)
    *   [load_sp_model](data_functional.html#load-sp-model)
    *   [句子数字编辑器](data_functional.html#sentencepiece-numericalizer)
    *   [句子 _ 令牌](data_functional.html#sentencepiece-tokenizer)
    *   [custom_replace](data_functional.html#custom-replace)
    *   [simple_space_split](data_functional.html#simple-space-split)
    *   [numericize_tokens_from_iterator](data_functional.html#numericalize-tokens-from-iterator)
*   [torchtext.data.metrics](data_metrics.html)
    *   [bleu_score](data_metrics.html#bleu-score)
*   [torchtext.datasets](datasets.html)
    *   [语言建模](datasets.html#language-modeling)
    *   [情绪分析](datasets.html#sentiment-analysis)
    *   [文本分类](datasets.html#text-classification)
    *   [问题分类](datasets.html#question-classification)
    *   [需求](datasets.html#entailment)
    *   [语言建模](datasets.html#id1)
    *   [机器翻译](datasets.html#machine-translation)
    *   [序列标记](datasets.html#sequence-tagging)
    *   [问答](datasets.html#question-answering)
    *   [无监督学习](datasets.html#unsupervised-learning)
*   [torchtext.vocab](vocab.html)
    *   [词汇](vocab.html#vocab)
    *   [SubwordVocab](vocab.html#subwordvocab)
    *   [矢量](vocab.html#vectors)
    *   [GloVe](vocab.html#glove)
    *   [FastText](vocab.html#fasttext)
    *   [CharNGram](vocab.html#charngram)
    *   [build_vocab_from_iterator](vocab.html#build-vocab-from-iterator)
*   [torchtext.utils](utils.html)
    *   [报告钩子](utils.html#reporthook)
    *   [download_from_url](utils.html#download-from-url)
    *   [unicode_csv_reader](utils.html#unicode-csv-reader)
    *   [extract_archive](utils.html#extract-archive)
*   [torchtext.experimental.datasets](experimental_datasets.html)
    *   [情绪分析](experimental_datasets.html#sentiment-analysis)
    *   [语言建模](experimental_datasets.html#language-modeling)
*   [示例](examples.html)

# 指数和表格

*   [索引](genindex.html)

*   [模块索引](py-modindex.html)

*   [搜索页](search.html)