Safetensors
mpixel
pixel
mae
vit
tokenization-free
File size: 2,323 Bytes
41690db
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
fa58635
 
 
 
41690db
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
---
license: apache-2.0
datasets:
- HuggingFaceFW/fineweb
- HuggingFaceFW/fineweb-2
language:
- en
- uk
- zh
- hi
tags:
- pixel
- mae
- vit
- tokenization-free
---
# MPIXEL

MPIXEL, introduced in [Scaling Multilingual Pretraining of Pixel Language Models](https://arxiv.org/abs/2610.29681), is a family of multilingual pixel language models, which operate on visually rendered text. Our main models, `mpixel-base` (86M parameters) and `mpixel-large` (307M parameters), are pretrained on sixteen languages that span ten writing systems. MPIXEL uses adaptive rendering: it renders text as grapheme bigrams by default, Chinese, Japanese and Korean text one character per patch, and Arabic and Hebrew text word by word.

This model is `mpixel-4s`. It follows the [pixel-m4](https://aclanthology.org/2025.emnlp-main.1504/) setup and is pretrained on the same four languages (English, Hindi, Chinese and Ukrainian), but its text rendering, rotary positional embeddings, data source and per-language data amount are matched to mpixel-base to remove confounding factors.

## Basic usage
To use our models, please first install our [`mpixel` package](https://github.com/ilkerkesen/mpixel). Here is an example of loading a pretrained model and encoding input text:

```python
from transformers import AutoModel
import mpixel.models.auto_register  # registers MPIXEL with the Auto classes
from mpixel.processing import MPIXELProcessor

processor = MPIXELProcessor.from_pretrained("Team-PIXEL/mpixel-4s")
model = AutoModel.from_pretrained("Team-PIXEL/mpixel-4s")

inputs = processor(["Hello world!", "The quick brown fox jumps over the lazy dog."])
outputs = model(**inputs)
print(outputs.last_hidden_state.shape)  # torch.Size([2, 513, 768])
```

For further information, please take a look at our repository: [https://github.com/ilkerkesen/mpixel](https://github.com/ilkerkesen/mpixel).

## Citation

If you find MPIXEL beneficial for your research, please cite it,

```
@misc{kesen2026scalingmultilingualpretrainingpixel,
      title={Scaling Multilingual Pretraining of Pixel Language Models}, 
      author={Ilker Kesen and Jenny Kunz and Kasra Malihi and Desmond Elliott},
      year={2026},
      eprint={2610.29681},
      archivePrefix={arXiv},
      primaryClass={cs.CL},
      url={https://arxiv.org/abs/2610.29681}, 
}
```