đ Flux-Sketch-Paint-LoRA
This project is a text - to - image LoRA model based on the diffusers
library. It can generate various sketch - style paintings according to text descriptions, offering a rich visual experience.
đ Quick Start
Setting Up
import torch
from pipelines import DiffusionPipeline
base_model = "black-forest-labs/FLUX.1-dev"
pipe = DiffusionPipeline.from_pretrained(base_model, torch_dtype=torch.bfloat16)
lora_repo = "strangerzonehf/Sketch-paint"
trigger_word = "Sketch paint"
pipe.load_lora_weights(lora_repo)
device = torch.device("cuda")
pipe.to(device)
Trigger words
You should use Sketch paint
to trigger the image generation.
Download model
Weights for this model are available in Safetensors format.
Download them in the Files & versions tab.
⨠Features
- Text - to - Image Generation: Generate high - quality sketch - style paintings based on text descriptions.
- Rich Visual Effects: Capable of generating various scenarios and characters, such as portraits of women, paintings of animals, and abstract art.
đĻ Installation
The README does not provide specific installation steps, so this section is skipped.
đģ Usage Examples
Basic Usage
First, ensure that the model is set up as described in the "Quick Start" section. Then, you can use the following code to generate an image:
text_prompt = 'Sketch paint, An eye - level perspective, a medium - sized portrait of a woman, is depicted in a blue and white monochromatic fashion. The womans head is adorned with a large, fluffy, fuzzy hat, adorned with white flowers. Her hair is pulled back, framing her face, adding a touch of depth to the composition. She is wearing a black dress with a white scarf draped over her shoulders. Her dress is draped in a low - angle pattern, adding texture to the overall composition. The background is a dark blue, creating a stark contrast to the womans face.'
image = pipe(text_prompt).images[0]
image.save("generated_image.png")
đ Documentation
Model description for Flux - Sketch - Paint - LoRA
Image Processing Parameters
Property |
Details |
LR Scheduler |
constant |
Optimizer |
AdamW |
Network Dim |
64 |
Network Alpha |
32 |
Epoch |
17 |
Noise Offset |
0.03 |
Multires Noise Discount |
0.1 |
Multires Noise Iterations |
10 |
Repeat & Steps |
25 & 3070 |
Save Every N Epochs |
1 |
Labeling: florence2 - en(natural language & English)
Total Images Used for Training: 19
Best Dimensions & Inference
Property |
Details |
Best Dimensions (Aspect Ratio) |
1280 x 832 (3:2) |
Default Dimensions (Aspect Ratio) |
1024 x 1024 (1:1) |
Recommended Inference Steps |
30â35 |
đ§ Technical Details
The README does not provide detailed technical implementation details, so this section is skipped.
đ License
The README does not provide license information, so this section is skipped.