File size: 1,220 Bytes
a4c74a6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42

---
license: mit
base_model: runwayml/stable-diffusion-v1-5
tags:
- stable-diffusion
- text-to-image
- diffusers
- lora
- style
- art
---

# LoRA for Style: Abstract_Expressionism

A LoRA fine-tuned to generate images in the **Abstract Expressionism** style. Use the trigger phrase `in abstract expressionism style` in your prompts.

This LoRA was trained on the [WikiArt dataset](https://www.kaggle.com/datasets/steubk/wikiart) for 1000 steps.

## How to Use

This LoRA is designed to be used with the `diffusers` library.

```python
import torch
from diffusers import StableDiffusionPipeline
from peft import PeftModel

# --- 1. Load the base model ---
base_model_id = "runwayml/stable-diffusion-v1-5"
pipe = StableDiffusionPipeline.from_pretrained(base_model_id, torch_dtype=torch.float16).to("cuda")

# --- 2. Load the LoRA adapter ---
repo_id = "aanchal77/Final-One"
lora_path_in_repo = "styles/Abstract_Expressionism"
pipe.unet = PeftModel.from_pretrained(pipe.unet, repo_id, subfolder=lora_path_in_repo)

# --- 3. Generate an image ---
prompt = f"A futuristic cityscape in abstract expressionism style"
image = pipe(prompt, num_inference_steps=20, guidance_scale=7.5).images[0]
image.save("generated_image.png")