Module: TorchText::Datasets::TextClassification

Defined in:
lib/torchtext/datasets/text_classification.rb

Constant Summary collapse

URLS =
{
  "AG_NEWS" => "https://drive.google.com/uc?export=download&id=0Bz8a_Dbh9QhbUDNpeUdjb0wxRms"
}
PATHS =
{
  "AG_NEWS" => "ag_news_csv"
}
FILENAMES =
{
  "AG_NEWS" => "ag_news_csv.tar.gz"
}
DATASETS =
{
  "AG_NEWS" => method(:ag_news)
}
LABELS =
{
  "AG_NEWS" => {
    0 => "World",
    1 => "Sports",
    2 => "Business",
    3 => "Sci/Tech"
  }
}

Class Method Summary collapse

Class Method Details

.ag_news(*args, **kwargs) ⇒ Object



15
16
17
# File 'lib/torchtext/datasets/text_classification.rb', line 15

def ag_news(*args, **kwargs)
  setup_datasets("AG_NEWS", *args, **kwargs)
end