Doha AI Challenge โ€” fine-tuned checkpoints (Team Salahh)

This repository holds the fine-tuned model checkpoints for our winning solution to the Google Cloud Doha AI Challenge (6-target Arabic-news classification, weighted-F1).

The solution is an ensemble of Arabic transformer classifiers built on 9 pretrained backbones, each fine-tuned under several configurations/seeds. Every run is trained with 5-fold cross-validation, so each of the 42 runs contributes 5 fold checkpoints:

<tag>/fold0.pt  fold1.pt  fold2.pt  fold3.pt  fold4.pt      # 42 tags x 5 folds = 210 checkpoints

Each fold*.pt is a state_dict (bf16) of a multi-task model: a shared encoder + 6 linear classification heads (one per target). ~92 GB total.

These checkpoints are consumed by the solution/ code of the competition submission package (infer.py / reproduce_from_checkpoints.ipynb), together with recipe.json (per-target model sets) and weights.json (ensemble weights), to reproduce the final clean.csv.


1. Download the checkpoints

pip install -U "huggingface_hub[cli]"

# into the solution/ folder of the submission package, as checkpoints/<tag>/fold*.pt
huggingface-cli download salahh297/doha-checkpoints \
    --repo-type model --local-dir solution/checkpoints

(Or in Python:)

from huggingface_hub import snapshot_download
snapshot_download("salahh297/doha-checkpoints", repo_type="model",
                  local_dir="solution/checkpoints")

After download, the layout is solution/checkpoints/<tag>/fold{0..4}.pt.


2. Reproduce clean.csv from the checkpoints (GPU)

You need the competition solution/ folder (code + recipe.json + weights.json + data/Train.csv, data/Test.csv) alongside the downloaded checkpoints/.

cd solution
pip install torch "transformers==4.57.1" accelerate sentencepiece arabert farasapy scikit-learn pandas numpy

# script:
python3 infer.py
# or the notebook (same result):
#   jupyter nbconvert --to notebook --execute reproduce_from_checkpoints.ipynb

infer.py rebuilds each model, loads its five fold checkpoints from checkpoints/<tag>/fold*.pt, runs them forward on the test set (GPU), averages the five test-probability sets per model, and combines the per-target model sets (recipe.json) with the ensemble weights (weights.json) to write clean.csv.

  • GPU: A100 40GB, or A100 / H100 80GB (H100 80GB recommended).
  • The farasa-segmented run preprocesses the test text with the farasa segmenter and is slow (tens of minutes); all other runs are fast.
  • Fixed seeds are used throughout, so the pipeline is reproducible.

Team: Salahh.

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support