albertvillanova's picture
Convert dataset to Parquet (#4)
d4bf86d verified
metadata
language: en
size_categories: 10K<n<100K
task_categories:
  - text-classification
task_ids:
  - multi-class-classification
  - topic-classification
tags:
  - long context
dataset_info:
  - config_name: default
    features:
      - name: text
        dtype: string
      - name: label
        dtype:
          class_label:
            names:
              '0': math.AC
              '1': cs.CV
              '2': cs.AI
              '3': cs.SY
              '4': math.GR
              '5': cs.CE
              '6': cs.PL
              '7': cs.IT
              '8': cs.DS
              '9': cs.NE
              '10': math.ST
    splits:
      - name: train
        num_bytes: 1650691690
        num_examples: 28388
      - name: validation
        num_bytes: 144469423
        num_examples: 2500
      - name: test
        num_bytes: 141183324
        num_examples: 2500
    download_size: 1011043995
    dataset_size: 1936344437
  - config_name: no_ref
    features:
      - name: text
        dtype: string
      - name: label
        dtype:
          class_label:
            names:
              '0': math.AC
              '1': cs.CV
              '2': cs.AI
              '3': cs.SY
              '4': math.GR
              '5': cs.CE
              '6': cs.PL
              '7': cs.IT
              '8': cs.DS
              '9': cs.NE
              '10': math.ST
    splits:
      - name: train
        num_bytes: 1650587077
        num_examples: 28388
      - name: validation
        num_bytes: 144460101
        num_examples: 2500
      - name: test
        num_bytes: 141174323
        num_examples: 2500
    download_size: 1010911333
    dataset_size: 1936221501
configs:
  - config_name: default
    data_files:
      - split: train
        path: data/train-*
      - split: validation
        path: data/validation-*
      - split: test
        path: data/test-*
  - config_name: no_ref
    data_files:
      - split: train
        path: no_ref/train-*
      - split: validation
        path: no_ref/validation-*
      - split: test
        path: no_ref/test-*

Arxiv Classification: a classification of Arxiv Papers (11 classes).

This dataset is intended for long context classification (documents have all > 4k tokens).
Copied from "Long Document Classification From Local Word Glimpses via Recurrent Attention Learning"

@ARTICLE{8675939,
  author={He, Jun and Wang, Liqun and Liu, Liu and Feng, Jiao and Wu, Hao},
  journal={IEEE Access}, 
  title={Long Document Classification From Local Word Glimpses via Recurrent Attention Learning}, 
  year={2019},
  volume={7},
  number={},
  pages={40707-40718},
  doi={10.1109/ACCESS.2019.2907992}
  }

It contains 11 slightly unbalanced classes, 33k Arxiv Papers divided into 3 splits: train (28k), val (2.5k) and test (2.5k).

2 configs:

  • default
  • no_ref, removes references to the class inside the document (eg: [cs.LG] -> [])

Compatible with run_glue.py script:

export MODEL_NAME=roberta-base
export MAX_SEQ_LENGTH=512

python run_glue.py \
  --model_name_or_path $MODEL_NAME \
  --dataset_name ccdv/arxiv-classification  \
  --do_train \
  --do_eval \
  --max_seq_length $MAX_SEQ_LENGTH \
  --per_device_train_batch_size 8 \
  --gradient_accumulation_steps 4 \
  --learning_rate 2e-5 \
  --num_train_epochs 1 \
  --max_eval_samples 500 \
  --output_dir tmp/arxiv