Instructions to use AdamLucek/FLUX.1-dev-lora-adaml with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use AdamLucek/FLUX.1-dev-lora-adaml with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev", torch_dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("AdamLucek/FLUX.1-dev-lora-adaml") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
- DiffusionBee
| tags: | |
| - text-to-image | |
| - lora | |
| - diffusers | |
| - flux | |
| base_model: black-forest-labs/FLUX.1-dev | |
| license: creativeml-openrail-m | |
| library_name: diffusers | |
| # Flux.1-Dev LoRA Adapter Trained on Me | |
| LoRA Adapter for [black-forest-labs/FLUX.1-dev](https://huggingface.co/black-forest-labs/FLUX.1-dev) trained on pictures of me with [ai-toolkit](https://github.com/ostris/ai-toolkit/tree/main) | |
| # Model Details | |
| **Some Amusing Examples** | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/ZG8SCJngcopb_eapEIWpf.png" width=400> | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/9EJxi0-wVpRmhndEOtqet.png" width=400> | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/yzM48yFaHmHgYFAQJdATw.png" width=400> | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/Ye1-e96hf1g1BPB29CyUE.png" width=400> | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/4P7ctpWuHNzLO8aVYJ8q8.png" width=400> | |
| LoRA was trained with the trigger phrase `4d4m luc3k` | |
| Full training config available at [train_lora_flux_me.yaml](./train_lora_flux_me.yaml) | |
| # Usage | |
| With diffusers package | |
| *Note: FLUX uses ~70GBvram when loaded directly with diffusers* | |
| *Note: Recommended to load at ~70% scale for best results* | |
| ```python | |
| from diffusers import DiffusionPipeline | |
| pipeline = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-dev") | |
| pipeline.load_lora_weights("AdamLucek/FLUX.1-dev-lora-adaml", weight_name="flux_lora_Adam.safetensors.safetensors") | |
| pipeline.to("cuda") | |
| prompt = "4d4m luc3k as a DJ in a fancy nightclub wearing sunglasses." | |
| out = pipeline( | |
| prompt=prompt, | |
| guidance_scale=3.5, | |
| num_inference_steps=50, | |
| cross_attention_kwargs={"scale": 0.7} | |
| ).images[0] | |
| out.save("adam_flux_lora.png") | |
| ``` | |
| ComfyUI Setup | |
| <img src="https://huggingface.co/static-proxy/cdn-uploads.huggingface.co/production/uploads/65ba68a15d2ef0a4b2c892b4/7c_8aakMNzY4OPjSn5q-5.png" width=800> | |
| File available at [workflow_adamlora.json](workflow_adamlora.json) | |
| # Additional Details | |
| Please see base model page [black-forest-labs/FLUX.1-dev](https://huggingface.co/black-forest-labs/FLUX.1-dev) for all details on appropriate usage, licensing, and more. |