Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -12,7 +12,7 @@ from src.pipeline import FluxPipeline
|
|
| 12 |
from src.transformer_flux import FluxTransformer2DModel
|
| 13 |
from src.lora_helper import set_single_lora, set_multi_lora, unset_lora
|
| 14 |
|
| 15 |
-
|
| 16 |
class ImageProcessor:
|
| 17 |
def __init__(self, path):
|
| 18 |
device = "cuda"
|
|
@@ -25,7 +25,6 @@ class ImageProcessor:
|
|
| 25 |
for name, attn_processor in transformer.attn_processors.items():
|
| 26 |
attn_processor.bank_kv.clear()
|
| 27 |
|
| 28 |
-
@spaces.GPU
|
| 29 |
def process_image(self, prompt='', subject_imgs=[], spatial_imgs=[], height=768, width=768, output_path=None, seed=42):
|
| 30 |
image = self.pipe(
|
| 31 |
prompt,
|
|
|
|
| 12 |
from src.transformer_flux import FluxTransformer2DModel
|
| 13 |
from src.lora_helper import set_single_lora, set_multi_lora, unset_lora
|
| 14 |
|
| 15 |
+
|
| 16 |
class ImageProcessor:
|
| 17 |
def __init__(self, path):
|
| 18 |
device = "cuda"
|
|
|
|
| 25 |
for name, attn_processor in transformer.attn_processors.items():
|
| 26 |
attn_processor.bank_kv.clear()
|
| 27 |
|
|
|
|
| 28 |
def process_image(self, prompt='', subject_imgs=[], spatial_imgs=[], height=768, width=768, output_path=None, seed=42):
|
| 29 |
image = self.pipe(
|
| 30 |
prompt,
|