Instructions to use xocialize/background-remove-FLUX.2-klein-4B-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use xocialize/background-remove-FLUX.2-klein-4B-lora with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.2-klein-4B", dtype=torch.bfloat16, device_map="cuda") pipe.load_lora_weights("xocialize/background-remove-FLUX.2-klein-4B-lora") prompt = "Remove the background from the image" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Draw Things
File size: 573 Bytes
10f38b4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 | Flux Background Remove — FLUX.2-klein-4B LoRA
=============================================
Original author: fal (fal.ai)
Source: https://huggingface.co/fal/flux-2-klein-4B-background-remove-lora
Live demo: https://fal.ai/models/fal-ai/flux-2/klein/4b/base/edit/lora
Published by fal under the Apache License, Version 2.0.
This repository is a verbatim, byte-identical mirror of the canonical
diffusers/PEFT weight file, maintained by xocialize for long-term availability.
All credit for the weights belongs to fal. See README.md for provenance hashes.
|