Sunstone Image 1 Preview
scratch-built 49.1M-parameter image generator
2 min readupdated
This experimental model from VertexAGI generates small 64×64-pixel images from text descriptions. Its main difference from most modern generators is that it was trained completely from scratch without using pre-trained weights like CLIP, T5, VAE, or Stable Diffusion. The entire training process took about 4.3 days on a single consumer GTX 1660 Ti graphics card with 6 GB of VRAM. The model weighs just 98 MB and is suitable for enthusiasts who want to study the inner workings and training of diffusion architectures in practice.
Key features
- Fully independent architecture: a 4-layer text transformer with 384 dimensions and a pixel-space U-Net with attention mechanisms at 16×16 and 8×8 resolutions.
- Trained using the rectified flow method (velocity prediction) and a custom BPE tokenizer with a 32,000-token vocabulary.
- Handles sunsets, skies, landscapes, flowers, buildings, and general mood well.
- Struggles with faces, hands, fine details, text, and animals, which appear as blurry silhouettes.
What you can do
- Examine the architecture and training code of a compact text-to-image model that is actually feasible to reproduce on home hardware.
- Generate small decorative pixel-art sketches of landscapes, sunsets, and architecture.
- Run it locally even without a powerful graphics card: the script automatically selects CUDA, Apple MPS, or CPU (on Apple Silicon, 4 images take about 14 seconds to generate).
Example
pip install torch numpy pillow tokenizers
python generate.py "a sunset over the beach" --n 4 --out sunset.png
Read more
DetailsParameters: 49.1M (the final_ema_fp16.pt weight file is 98 MB).
Dataset: 565,463 photos from CommonCatalog CC-BY with automated captions from BLIP-2.
Training: 850,000 steps, batch size 32, AdamW, final validation loss of 0.0790 (EMA 0.0789).
Limitations: 64×64 resolution only (upscaling makes the image blurry), prompt length is capped at 24 tokens, and photo-caption-style phrases work best.










Comments