Track downloads (top-level config.json); fuller card metadata and tags
Browse files- README.md +19 -3
- config.json +58 -0
README.md
CHANGED
|
@@ -1,14 +1,29 @@
|
|
| 1 |
---
|
| 2 |
license: mit
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3 |
tags:
|
| 4 |
- pixel-art
|
| 5 |
- sprites
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
- text-to-image
|
| 7 |
- image-to-image
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8 |
- onnx
|
| 9 |
- webgpu
|
| 10 |
-
|
| 11 |
-
|
| 12 |
---
|
| 13 |
|
| 14 |
# pixy
|
|
@@ -33,6 +48,7 @@ library_name: onnx
|
|
| 33 |
| `tokenizer.json` | CLIP BPE vocabulary and merges | 1 MB |
|
| 34 |
| `palette_index.bin` | 20k training captions' CLIP embeddings (int8) and palettes, for "palette from a theme" | 11 MB |
|
| 35 |
| `meta.json` | preset palettes, file sizes, index layout | 3 KB |
|
|
|
|
| 36 |
|
| 37 |
| `pytorch/model.safetensors` | the sprite model's PyTorch weights (EMA, fp32, step 8000) | 160 MB |
|
| 38 |
| `pytorch/config.json`, `pytorch/model.py`, `pytorch/sample.py` | model config, model definition, text → sprite script | 20 KB |
|
|
@@ -58,7 +74,7 @@ It also turns an image of a single object (a photo, an icon, a drawing) into a s
|
|
| 58 |
|
| 59 |
```bash
|
| 60 |
pip install torch transformers safetensors pillow huggingface_hub
|
| 61 |
-
hf download harryfrz/pixy --include "pytorch/*" --local-dir pixy
|
| 62 |
cd pixy/pytorch
|
| 63 |
python sample.py --prompt "spooky mushroom" --palette endesga32 --n 8 --out mushrooms.png
|
| 64 |
python sample.py --prompt "golden key" --palette "#0f380f,#306230,#8bac0f,#9bbc0f" # any hex list, 1 to 32 colours
|
|
|
|
| 1 |
---
|
| 2 |
license: mit
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
library_name: onnx
|
| 6 |
+
pipeline_tag: text-to-image
|
| 7 |
+
datasets:
|
| 8 |
+
- Angais/pixel-art-atlas-1.4m
|
| 9 |
tags:
|
| 10 |
- pixel-art
|
| 11 |
- sprites
|
| 12 |
+
- sprite-generation
|
| 13 |
+
- game-assets
|
| 14 |
+
- gamedev
|
| 15 |
+
- 16x16
|
| 16 |
+
- palette
|
| 17 |
- text-to-image
|
| 18 |
- image-to-image
|
| 19 |
+
- masked-diffusion
|
| 20 |
+
- discrete-diffusion
|
| 21 |
+
- maskgit
|
| 22 |
+
- clip
|
| 23 |
- onnx
|
| 24 |
- webgpu
|
| 25 |
+
- pytorch
|
| 26 |
+
- safetensors
|
| 27 |
---
|
| 28 |
|
| 29 |
# pixy
|
|
|
|
| 48 |
| `tokenizer.json` | CLIP BPE vocabulary and merges | 1 MB |
|
| 49 |
| `palette_index.bin` | 20k training captions' CLIP embeddings (int8) and palettes, for "palette from a theme" | 11 MB |
|
| 50 |
| `meta.json` | preset palettes, file sizes, index layout | 3 KB |
|
| 51 |
+
| `config.json` | model summary: architecture, text encoder, sampling settings, file list (also what the Hub counts as a download) | 1 KB |
|
| 52 |
|
| 53 |
| `pytorch/model.safetensors` | the sprite model's PyTorch weights (EMA, fp32, step 8000) | 160 MB |
|
| 54 |
| `pytorch/config.json`, `pytorch/model.py`, `pytorch/sample.py` | model config, model definition, text → sprite script | 20 KB |
|
|
|
|
| 74 |
|
| 75 |
```bash
|
| 76 |
pip install torch transformers safetensors pillow huggingface_hub
|
| 77 |
+
hf download harryfrz/pixy --include "pytorch/*" "config.json" --local-dir pixy
|
| 78 |
cd pixy/pytorch
|
| 79 |
python sample.py --prompt "spooky mushroom" --palette endesga32 --n 8 --out mushrooms.png
|
| 80 |
python sample.py --prompt "golden key" --palette "#0f380f,#306230,#8bac0f,#9bbc0f" # any hex list, 1 to 32 colours
|
config.json
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"model": "pixy",
|
| 3 |
+
"description": "16x16 pixel-art sprites in your palette: text and/or image -> palette indices (0 transparent, k = palette colour k).",
|
| 4 |
+
"architecture": "PaletteSpriteModel",
|
| 5 |
+
"model_cfg": {
|
| 6 |
+
"dim": 512,
|
| 7 |
+
"depth": 12,
|
| 8 |
+
"heads": 8,
|
| 9 |
+
"mlp_hidden": 1408,
|
| 10 |
+
"text_dim": 512,
|
| 11 |
+
"text_len": 33,
|
| 12 |
+
"p_max": 32,
|
| 13 |
+
"color_freqs": 6,
|
| 14 |
+
"guide": true
|
| 15 |
+
},
|
| 16 |
+
"text_encoder": {
|
| 17 |
+
"name": "openai/clip-vit-base-patch32",
|
| 18 |
+
"max_length": 32,
|
| 19 |
+
"features": "pooled output first, then the 32 token states: [B, 33, 512]"
|
| 20 |
+
},
|
| 21 |
+
"sampling": {
|
| 22 |
+
"steps": 12,
|
| 23 |
+
"cfg": 3.0,
|
| 24 |
+
"temperature": 1.0,
|
| 25 |
+
"choice_noise": 2.0
|
| 26 |
+
},
|
| 27 |
+
"palette": {
|
| 28 |
+
"min_colors": 1,
|
| 29 |
+
"max_colors": 32,
|
| 30 |
+
"color_space": "OKLab"
|
| 31 |
+
},
|
| 32 |
+
"weights": "EMA",
|
| 33 |
+
"training_step": 8000,
|
| 34 |
+
"version": "step8000",
|
| 35 |
+
"files": {
|
| 36 |
+
"pytorch": [
|
| 37 |
+
"pytorch/model.safetensors",
|
| 38 |
+
"pytorch/config.json",
|
| 39 |
+
"pytorch/model.py",
|
| 40 |
+
"pytorch/sample.py"
|
| 41 |
+
],
|
| 42 |
+
"onnx_webgpu": [
|
| 43 |
+
"sprite_fp16.onnx",
|
| 44 |
+
"text_fp16.onnx",
|
| 45 |
+
"tokenizer.json"
|
| 46 |
+
],
|
| 47 |
+
"onnx_cpu": [
|
| 48 |
+
"sprite_fp32.onnx",
|
| 49 |
+
"text_fp32.onnx",
|
| 50 |
+
"tokenizer.json"
|
| 51 |
+
],
|
| 52 |
+
"browser": [
|
| 53 |
+
"meta.json",
|
| 54 |
+
"palette_index.bin"
|
| 55 |
+
]
|
| 56 |
+
},
|
| 57 |
+
"license": "mit"
|
| 58 |
+
}
|