randomart / README.md
DD-65's picture
Update model card
7860b8a verified
|
Raw
History Blame Contribute Delete
2.42 kB
---
license: other
library_name: diffusers
pipeline_tag: unconditional-image-generation
tags:
- diffusers
- ddpm
- unconditional-image-generation
- art
- diffusion-models-class
---
# RandomArt DDPM
My first real Model, following the [HF diffusion model course](https://huggingface.co/learn/diffusion-course/unit1/2#step-2-download-a-training-dataset).
RandomArt is an unconditional diffusion model trained from scratch on 7k Images of [huggan/wikiart](https://huggingface.co/datasets/huggan/wikiart) on Apple Silicon. It generates 128×128 painterly and abstract
compositions without text prompts.
## Examples
| | | |
|---|---|---|
| ![](samples/generated-500_1.png) | ![](samples/generated-500_2.png) | ![](samples/generated-500_3.png) |
## Usage
Install PyTorch and Diffusers, then run the model as follows:
```python
import torch
from diffusers import DDPMPipeline
if torch.backends.mps.is_available():
device = "mps"
elif torch.cuda.is_available():
device = "cuda"
else:
device = "cpu"
pipe = DDPMPipeline.from_pretrained("DD-65/randomart").to(device)
image = pipe(num_inference_steps=250).images[0]
image.save("randomart.png")
```
For faster exploration, use 100 inference steps. Around 250 steps provides a
useful speed/quality balance, while 500 steps gives more time to final renders.
## Model details
- Architecture: `UNet2DModel` with a `DDPMScheduler`
- Resolution: 128×128 RGB
- Conditioning: none
- Training objective: epsilon/noise prediction
- Scheduler training timesteps: 1,000
## Limitations
The model is designed for experimental image generation. It tends to learn
local painterly texture more strongly than coherent object anatomy or global
geometry. Outputs may resemble characteristics present in the training
collection. The training images and their associated rights are not included
in this repository; users are responsible for evaluating generated outputs for
their intended use.
## License
This model was trained on [huggan/wikiart](https://huggingface.co/datasets/huggan/wikiart), whose license limits
use to non-commercial research and requires compliance with WikiArt's
terms and conditions.
The model weights are therefore provided for non-commercial research
and experimental use only. No rights are granted to the underlying
artworks, and users are responsible for ensuring their use complies
with applicable copyright law and WikiArt's terms.