Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,9 +14,7 @@ else:
|
|
14 |
pipe = DiffusionPipeline.from_pretrained("stabilityai/sdxl-turbo", use_safetensors=True)
|
15 |
pipe = pipe.to(device)
|
16 |
|
17 |
-
def edit_image(
|
18 |
-
image = Image.open(img_data)
|
19 |
-
|
20 |
if operation == "rotate":
|
21 |
angle = int(args[0])
|
22 |
image = image.rotate(angle, expand=True)
|
|
|
14 |
pipe = DiffusionPipeline.from_pretrained("stabilityai/sdxl-turbo", use_safetensors=True)
|
15 |
pipe = pipe.to(device)
|
16 |
|
17 |
+
def edit_image(image, operation, *args):
|
|
|
|
|
18 |
if operation == "rotate":
|
19 |
angle = int(args[0])
|
20 |
image = image.rotate(angle, expand=True)
|