Text-to-Image
Diffusers
Safetensors
English
Kazakh
Lumina2Pipeline
Lumina2Pipeline
lumina
kazakh
central-asia
cultural-alignment
beynele
Instructions to use issai/Beynele with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use issai/Beynele with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("issai/Beynele", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
- DiffusionBee
| import torch | |
| from diffusers import Lumina2Pipeline | |
| MODEL_ID = "issai/Beynele" | |
| PROMPTS = [ | |
| "A Kazakh dombra resting on a patterned felt carpet.", | |
| "A cinematic aerial photo of Astana's Baiterek Tower at golden hour.", | |
| 'The Kazakh Cyrillic word "бейнеле" sculpted from soft white clouds in a bright blue sky.', | |
| ] | |
| def load_pipeline(): | |
| pipe = Lumina2Pipeline.from_pretrained( | |
| MODEL_ID, | |
| torch_dtype=torch.bfloat16, | |
| ) | |
| pipe.enable_model_cpu_offload() | |
| return pipe | |
| if __name__ == "__main__": | |
| pipe = load_pipeline() | |
| for idx, prompt in enumerate(PROMPTS, start=1): | |
| image = pipe( | |
| prompt, | |
| height=1024, | |
| width=1024, | |
| guidance_scale=4.0, | |
| num_inference_steps=40, | |
| cfg_trunc_ratio=0.25, | |
| cfg_normalization=True, | |
| generator=torch.Generator("cpu").manual_seed(42 + idx), | |
| ).images[0] | |
| image.save(f"beynele_example_{idx}.png") | |