Instructions to use Joypop/GDPO with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use Joypop/GDPO with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline from diffusers.utils import load_image # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("Joypop/GDPO", dtype=torch.bfloat16, device_map="cuda") prompt = "Turn this cat into a dog" input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png") image = pipe(image=input_image, prompt=prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -36,8 +36,6 @@ pip install -r requirements.txt
|
|
| 36 |
|
| 37 |
## 🏂 Quick Inference
|
| 38 |
|
| 39 |
-
### Real-world Image Super-resolution
|
| 40 |
-
|
| 41 |
#### Step 1: Download the pretrained models
|
| 42 |
- Download the model weights [](https://huggingface.co/Joypop/GDPO/tree/main) and put the model weights in the `ckp/`:
|
| 43 |
|
|
@@ -58,13 +56,10 @@ CUDA_VISIBLE_DEVICES=0, python GDPOSR/inferences/test.py \
|
|
| 58 |
```
|
| 59 |
or
|
| 60 |
```
|
| 61 |
-
bash scripts/test/
|
| 62 |
-
```
|
| 63 |
-
We also provide the tile code to save the GPU memory for inference. You can run the running command and change the tile size and stride according to the VRAM of your device.
|
| 64 |
-
```
|
| 65 |
-
python GDPO/inferences/inference_tile.py
|
| 66 |
```
|
| 67 |
|
|
|
|
| 68 |
## 🔗 Citations
|
| 69 |
|
| 70 |
```
|
|
|
|
| 36 |
|
| 37 |
## 🏂 Quick Inference
|
| 38 |
|
|
|
|
|
|
|
| 39 |
#### Step 1: Download the pretrained models
|
| 40 |
- Download the model weights [](https://huggingface.co/Joypop/GDPO/tree/main) and put the model weights in the `ckp/`:
|
| 41 |
|
|
|
|
| 56 |
```
|
| 57 |
or
|
| 58 |
```
|
| 59 |
+
bash scripts/test/test.sh
|
|
|
|
|
|
|
|
|
|
|
|
|
| 60 |
```
|
| 61 |
|
| 62 |
+
|
| 63 |
## 🔗 Citations
|
| 64 |
|
| 65 |
```
|