Upload lrzjason_QwenEdit-Anything2Real_Alpha_0.txt with huggingface_hub
Browse files
lrzjason_QwenEdit-Anything2Real_Alpha_0.txt
CHANGED
|
@@ -1,18 +1,21 @@
|
|
| 1 |
```CODE:
|
| 2 |
import torch
|
| 3 |
from diffusers import DiffusionPipeline
|
|
|
|
| 4 |
|
| 5 |
# switch to "mps" for apple devices
|
| 6 |
pipe = DiffusionPipeline.from_pretrained("Qwen/Qwen-Image-Edit-2509", dtype=torch.bfloat16, device_map="cuda")
|
| 7 |
pipe.load_lora_weights("lrzjason/QwenEdit-Anything2Real_Alpha")
|
| 8 |
|
| 9 |
-
prompt = "
|
| 10 |
-
|
|
|
|
|
|
|
| 11 |
```
|
| 12 |
|
| 13 |
ERROR:
|
| 14 |
Traceback (most recent call last):
|
| 15 |
-
File "/tmp/lrzjason_QwenEdit-
|
| 16 |
pipe = DiffusionPipeline.from_pretrained("Qwen/Qwen-Image-Edit-2509", dtype=torch.bfloat16, device_map="cuda")
|
| 17 |
File "/tmp/.cache/uv/environments-v2/aeddbcfdb13cdb7f/lib/python3.13/site-packages/huggingface_hub/utils/_validators.py", line 114, in _inner_fn
|
| 18 |
return fn(*args, **kwargs)
|
|
|
|
| 1 |
```CODE:
|
| 2 |
import torch
|
| 3 |
from diffusers import DiffusionPipeline
|
| 4 |
+
from diffusers.utils import load_image
|
| 5 |
|
| 6 |
# switch to "mps" for apple devices
|
| 7 |
pipe = DiffusionPipeline.from_pretrained("Qwen/Qwen-Image-Edit-2509", dtype=torch.bfloat16, device_map="cuda")
|
| 8 |
pipe.load_lora_weights("lrzjason/QwenEdit-Anything2Real_Alpha")
|
| 9 |
|
| 10 |
+
prompt = "Turn this cat into a dog"
|
| 11 |
+
input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
|
| 12 |
+
|
| 13 |
+
image = pipe(image=input_image, prompt=prompt).images[0]
|
| 14 |
```
|
| 15 |
|
| 16 |
ERROR:
|
| 17 |
Traceback (most recent call last):
|
| 18 |
+
File "/tmp/lrzjason_QwenEdit-Anything2Real_Alpha_045Bokc.py", line 28, in <module>
|
| 19 |
pipe = DiffusionPipeline.from_pretrained("Qwen/Qwen-Image-Edit-2509", dtype=torch.bfloat16, device_map="cuda")
|
| 20 |
File "/tmp/.cache/uv/environments-v2/aeddbcfdb13cdb7f/lib/python3.13/site-packages/huggingface_hub/utils/_validators.py", line 114, in _inner_fn
|
| 21 |
return fn(*args, **kwargs)
|