ocdbytes commited on
Commit
4aac593
·
0 Parent(s):

pixl-data: sprites and scenes

Browse files
.gitattributes ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.avro filter=lfs diff=lfs merge=lfs -text
4
+ *.bin filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
7
+ *.ftz filter=lfs diff=lfs merge=lfs -text
8
+ *.gz filter=lfs diff=lfs merge=lfs -text
9
+ *.h5 filter=lfs diff=lfs merge=lfs -text
10
+ *.joblib filter=lfs diff=lfs merge=lfs -text
11
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
12
+ *.lz4 filter=lfs diff=lfs merge=lfs -text
13
+ *.mds filter=lfs diff=lfs merge=lfs -text
14
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
15
+ *.model filter=lfs diff=lfs merge=lfs -text
16
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
17
+ *.npy filter=lfs diff=lfs merge=lfs -text
18
+ *.npz filter=lfs diff=lfs merge=lfs -text
19
+ *.onnx filter=lfs diff=lfs merge=lfs -text
20
+ *.ot filter=lfs diff=lfs merge=lfs -text
21
+ *.parquet filter=lfs diff=lfs merge=lfs -text
22
+ *.pb filter=lfs diff=lfs merge=lfs -text
23
+ *.pickle filter=lfs diff=lfs merge=lfs -text
24
+ *.pkl filter=lfs diff=lfs merge=lfs -text
25
+ *.pt filter=lfs diff=lfs merge=lfs -text
26
+ *.pth filter=lfs diff=lfs merge=lfs -text
27
+ *.rar filter=lfs diff=lfs merge=lfs -text
28
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
29
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
30
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
31
+ *.tar filter=lfs diff=lfs merge=lfs -text
32
+ *.tflite filter=lfs diff=lfs merge=lfs -text
33
+ *.tgz filter=lfs diff=lfs merge=lfs -text
34
+ *.wasm filter=lfs diff=lfs merge=lfs -text
35
+ *.xz filter=lfs diff=lfs merge=lfs -text
36
+ *.zip filter=lfs diff=lfs merge=lfs -text
37
+ *.zst filter=lfs diff=lfs merge=lfs -text
38
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
39
+ # Audio files - uncompressed
40
+ *.pcm filter=lfs diff=lfs merge=lfs -text
41
+ *.sam filter=lfs diff=lfs merge=lfs -text
42
+ *.raw filter=lfs diff=lfs merge=lfs -text
43
+ # Audio files - compressed
44
+ *.aac filter=lfs diff=lfs merge=lfs -text
45
+ *.flac filter=lfs diff=lfs merge=lfs -text
46
+ *.mp3 filter=lfs diff=lfs merge=lfs -text
47
+ *.ogg filter=lfs diff=lfs merge=lfs -text
48
+ *.wav filter=lfs diff=lfs merge=lfs -text
49
+ # Image files - uncompressed
50
+ *.bmp filter=lfs diff=lfs merge=lfs -text
51
+ *.gif filter=lfs diff=lfs merge=lfs -text
52
+ *.png filter=lfs diff=lfs merge=lfs -text
53
+ *.tiff filter=lfs diff=lfs merge=lfs -text
54
+ # Image files - compressed
55
+ *.jpg filter=lfs diff=lfs merge=lfs -text
56
+ *.jpeg filter=lfs diff=lfs merge=lfs -text
57
+ *.webp filter=lfs diff=lfs merge=lfs -text
58
+ # Video files - compressed
59
+ *.mp4 filter=lfs diff=lfs merge=lfs -text
60
+ *.webm filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,166 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license:
3
+ - cc0-1.0
4
+ - cc-by-3.0
5
+ size_categories:
6
+ - 1M<n<10M
7
+ task_categories:
8
+ - text-to-image
9
+ pretty_name: pixl-data
10
+ dataset_info:
11
+ - config_name: scenes
12
+ features:
13
+ - name: id
14
+ dtype: string
15
+ - name: split
16
+ dtype: string
17
+ - name: kind
18
+ dtype: string
19
+ - name: caption
20
+ dtype: string
21
+ - name: swapped
22
+ dtype: string
23
+ - name: style
24
+ dtype: string
25
+ - name: background
26
+ dtype: string
27
+ - name: objects
28
+ dtype: string
29
+ - name: slots
30
+ dtype: string
31
+ - name: sprites
32
+ dtype: string
33
+ - name: background_path
34
+ dtype: string
35
+ - name: image
36
+ dtype: image
37
+ splits:
38
+ - name: train
39
+ num_bytes: 1544667216
40
+ num_examples: 1000000
41
+ - name: test
42
+ num_bytes: 3151051
43
+ num_examples: 2000
44
+ download_size: 973142389
45
+ dataset_size: 1547818267
46
+ - config_name: sprites
47
+ features:
48
+ - name: path
49
+ dtype: string
50
+ - name: pack
51
+ dtype: string
52
+ - name: creator
53
+ dtype: string
54
+ - name: license
55
+ dtype: string
56
+ - name: source_url
57
+ dtype: string
58
+ - name: width
59
+ dtype: string
60
+ - name: height
61
+ dtype: string
62
+ - name: label
63
+ dtype: string
64
+ - name: label_source
65
+ dtype: string
66
+ - name: image
67
+ dtype: image
68
+ splits:
69
+ - name: train
70
+ num_bytes: 4139327
71
+ num_examples: 10191
72
+ - name: test
73
+ num_bytes: 885166
74
+ num_examples: 1146
75
+ download_size: 5783549
76
+ dataset_size: 5024493
77
+ configs:
78
+ - config_name: scenes
79
+ data_files:
80
+ - split: train
81
+ path: scenes/train-*
82
+ - split: test
83
+ path: scenes/test-*
84
+ - config_name: sprites
85
+ data_files:
86
+ - split: train
87
+ path: sprites/train-*
88
+ - split: test
89
+ path: sprites/test-*
90
+ tags:
91
+ - pixel-art
92
+ - sprites
93
+ ---
94
+
95
+ # pixl-data
96
+
97
+ Training data for **pixl**, a small text-to-pixel-art model trained from scratch.
98
+
99
+ | Config | Rows | What it holds |
100
+ |---|---|---|
101
+ | `sprites` | ~11.5k | Game sprites and icons (`image`) with a short label (`label`) |
102
+ | `scenes` | 1.002M | 32×32 scenes of four sprites each (`image`), with a caption written from the placement (`caption`) |
103
+
104
+ ## Load
105
+
106
+ ```python
107
+ from datasets import load_dataset
108
+
109
+ sprites = load_dataset("ocdbytes/pixl-data", "sprites") # {"train": ..., "test": ...}
110
+ scenes = load_dataset("ocdbytes/pixl-data", "scenes")
111
+
112
+ train = load_dataset("ocdbytes/pixl-data", "scenes", split="train") # one split only
113
+ ```
114
+
115
+ ## Splits
116
+
117
+ | Config | train | test | Kept together in one split |
118
+ |---|---|---|---|
119
+ | `sprites` | ~10.4k | ~1.2k (10% of groups) | The colour variants of one tile, the frames of one animation, and the numbered and old/new versions of one Dungeon Crawl sprite |
120
+ | `scenes` | 1,000,000 | 2,000 | Set by the generator: test scenes use test sprites, or an object pair never seen together in train scenes |
121
+
122
+ Rows in each defined sprite group stay in one split, reducing leakage from related frames and variants. This grouping does not detect every possible near-copy. A group is in `test` when the first 8 hex digits of the SHA-256 of its key, as a fraction of 16⁸, are below 0.1. The split is fixed: new data never moves existing rows.
123
+
124
+ ## sprites
125
+
126
+ Sprites from CC0 packs by [Kenney](https://kenney.nl/assets) (1-Bit Pack, 1-Bit Platformer Pack, Board Game Icons, Cursor Pixel Pack, Game Icons, Monochrome Pirates, Pico-8 City, Pixel Shmup, Pixel Vehicle Pack, Tiny Battle, Tiny Dungeon, Tiny Farm, Tiny Town), [ansimuz](https://ansimuz.itch.io/sunny-land-pixel-game-art) (Sunny Land), [GrafxKid](https://grafxkid.itch.io/mini-pixel-pack-3) (Mini Pixel Pack 3), [Buch](https://opengameart.org/content/a-platformer-in-the-forest) (A Platformer in the Forest), the Dungeon Crawl Stone Soup artists ([Dungeon Crawl 32x32 tiles](https://opengameart.org/content/dungeon-crawl-32x32-tiles-supplemental)), [Idylwild](https://opengameart.org/content/idylwilds-inventory) (Idylwild's Inventory), [Scrittl](https://opengameart.org/content/spaceship-set-32x32px) (Spaceship set 32x32px), [Jull](https://opengameart.org/node/50777) (Animated spaceships) and [wender](https://opengameart.org/node/176168) (Sports cars pixelart sprites). `label_source` says where each label comes from: checked by eye (`claude-visual`), a file name (`filename`) or a sprite-sheet atlas (`atlas`).
127
+
128
+ Icons by the [game-icons.net](https://game-icons.net) contributors (the row's `creator`, e.g. Lorc or Delapouite), available on https://game-icons.net under CC BY 3.0, rendered as white silhouettes 30×30 pixels in size on a 32×32 transparent canvas. Each row's `source_url` is the icon's page. Icons with abstract names, or about gore, drugs, self-harm or nudity, were left out. Kenney's Board Game Icons and Game Icons are converted the same way, keeping only icons of objects, not interface actions; the 1-Bit Platformer Pack keeps whole objects, not its ground and platform pieces.
129
+
130
+ Monochrome sprites (the 1-Bit Pack's white tiles, the 1-Bit Platformer Pack, the Cursor Pixel Pack, Monochrome Pirates and the icons) have labels starting with "monochrome", without the colour words of their coloured versions, so a caption tells colour and monochrome apart. The 1-Bit Pack's copies of objects on a dark square are left out; its ground tiles keep theirs.
131
+
132
+ | Column | Meaning |
133
+ |---|---|
134
+ | `path` | File path in the original pack layout |
135
+ | `pack`, `creator`, `source_url` | Which pack the sprite comes from |
136
+ | `license` | CC0 1.0, or CC BY 3.0 for game-icons.net icons |
137
+ | `width`, `height` | Size in pixels |
138
+ | `label`, `label_source` | Label and where it comes from |
139
+ | `image` | The sprite (PNG, with transparency) |
140
+
141
+ ## scenes
142
+
143
+ Synthetic 32×32 scenes, each made from one sprite style: a background tile repeated in every 16 px slot and four coloured objects with different labels, one centred in each quadrant. Sprites are not scaled, except the 32×32 Dungeon Crawl tiles, which are halved to 16×16 by keeping every other pixel; halved objects that fall apart into pieces are left out. The caption names each object's quadrant, listing the objects in random order, so it is always right: "a pine tree at the bottom right, a red house at the top left, a well at the top right and a barrel at the bottom left on grass". Images are drawn in the shared 256-colour palette, so they encode back to palette tokens exactly. Until November 2026 this config held 100,000 scenes of one or two objects; they remain in the repo's history.
144
+
145
+ | Kind (`kind`) | Split | Scenes | Objects from |
146
+ |---|---|---|---|
147
+ | `train` | train | 1,000,000 | Train-split sprites, with no held-out label pair |
148
+ | `new sprites` | test | 1,000 | Test-split sprites only |
149
+ | `new pair` | test | 1,000 | Train-split sprites, with at least one label pair that never appears together in train scenes |
150
+
151
+ | Column | Meaning |
152
+ |---|---|
153
+ | `caption` | The scene's caption |
154
+ | `swapped` | The caption with the first two listed objects' quadrants exchanged, for testing whether a model reads positions |
155
+ | `kind` | See above |
156
+ | `style` | Sprite pack (or 1-Bit Pack colour family) the scene is made from |
157
+ | `background`, `background_path` | Background tile label and path in the `sprites` config; empty for a transparent scene |
158
+ | `objects`, `sprites`, `slots` | Each object's label, path and `row,column` slot, `\|`-separated |
159
+ | `image` | The scene (PNG, transparent where there is no background) |
160
+
161
+ ## Licences
162
+
163
+ Sprite rows carry their licence in `license`. Scene rows have no separate licence column; they use only CC0 sprites:
164
+
165
+ - **Sprites:** CC0 1.0, except the game-icons.net icons: CC BY 3.0 (credit the `creator`; see the sprites section).
166
+ - **Scenes:** CC0 1.0, as they are made only from CC0 sprites.
scenes/test-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9af65108b81e4719b539dbc31350c45a03953be73ed89dbaf047fba8d95a04f1
3
+ size 1981013
scenes/train-00000-of-00004.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:56dc6d6c11cfffc8fd35812585d4b0329e810be86c2c248a508eb7bd4df511c5
3
+ size 243042037
scenes/train-00001-of-00004.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f527acd96e9734a0e7d5bd2d6bc32d2852b9d830de4c597efb19579ca5897c84
3
+ size 242521722
scenes/train-00002-of-00004.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:75c4f140c95ca8575c92ddd81b12183ea0d31d2256ec35c0a5b9dd34ceb16c63
3
+ size 242814852
scenes/train-00003-of-00004.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:075ec631d733f4688778d36ec541cb67fff863994ae193146dacaf0eef1919dd
3
+ size 242782765
sprites/test-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c68fd80b60b2d8381f2817c530f173f0611ad7075e7aae091f36cb448959277d
3
+ size 642346
sprites/train-00000-of-00001.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3e2e05482404fe031b577054abde78ddd5b72bef6dfe553926aecd1aa8c0c06f
3
+ size 5141203