cosplay / app.py
appinitdev's picture
Update app.py
6614b19 verified
Raw
History Blame Contribute Delete
408 Bytes
import torch
from diffusers import FluxPipeline
# Usamos la variante en precisión FP8, que reduce la huella de memoria a la mitad
pipe = FluxPipeline.from_pretrained(
"black-forest-labs/FLUX.1-dev",
torch_dtype=torch.float8_e4m3fn,
device_map="balanced"
).to("cuda")
# Cargar el LoRA
pipe.load_lora_weights("joyfox/Kontext-Cosplay-Lora", weight_name="kontext_cosplay_lora_20000.safetensors")