Add files using upload-large-folder tool
Browse files
README.md
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
| 3 |
library_name: realesrgan
|
|
@@ -11,7 +13,7 @@ tags:
|
|
| 11 |
- image-enhancement
|
| 12 |
---
|
| 13 |
|
| 14 |
-
# FLUX Upscale Models Collection
|
| 15 |
|
| 16 |
This repository contains Real-ESRGAN upscale models for post-processing and enhancing generated images. These models can upscale images by 2x or 4x while adding fine details and improving sharpness.
|
| 17 |
|
|
@@ -47,7 +49,7 @@ model = RRDBNet(num_in_ch=3, num_out_ch=3, num_feat=64, num_block=23, num_grow_c
|
|
| 47 |
|
| 48 |
upsampler = RealESRGANer(
|
| 49 |
scale=4,
|
| 50 |
-
model_path="
|
| 51 |
model=model,
|
| 52 |
tile=0,
|
| 53 |
tile_pad=10,
|
|
@@ -81,7 +83,7 @@ img_array = np.array(image)
|
|
| 81 |
model = RRDBNet(num_in_ch=3, num_out_ch=3, num_feat=64, num_block=23)
|
| 82 |
upsampler = RealESRGANer(
|
| 83 |
scale=4,
|
| 84 |
-
model_path="
|
| 85 |
model=model
|
| 86 |
)
|
| 87 |
upscaled, _ = upsampler.enhance(img_array, outscale=4)
|
|
@@ -118,6 +120,31 @@ These models are released under the Apache 2.0 license.
|
|
| 118 |
}
|
| 119 |
```
|
| 120 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 121 |
## Model Card Contact
|
| 122 |
|
| 123 |
-
For questions about Real-ESRGAN models, refer to the official Real-ESRGAN repository and documentation.
|
|
|
|
| 1 |
+
<!-- README Version: v1.0 -->
|
| 2 |
+
|
| 3 |
---
|
| 4 |
license: apache-2.0
|
| 5 |
library_name: realesrgan
|
|
|
|
| 13 |
- image-enhancement
|
| 14 |
---
|
| 15 |
|
| 16 |
+
# FLUX Upscale Models Collection v1.0
|
| 17 |
|
| 18 |
This repository contains Real-ESRGAN upscale models for post-processing and enhancing generated images. These models can upscale images by 2x or 4x while adding fine details and improving sharpness.
|
| 19 |
|
|
|
|
| 49 |
|
| 50 |
upsampler = RealESRGANer(
|
| 51 |
scale=4,
|
| 52 |
+
model_path="E:\\huggingface\\flux-upscale\\upscale_models\\4x-UltraSharp.pth",
|
| 53 |
model=model,
|
| 54 |
tile=0,
|
| 55 |
tile_pad=10,
|
|
|
|
| 83 |
model = RRDBNet(num_in_ch=3, num_out_ch=3, num_feat=64, num_block=23)
|
| 84 |
upsampler = RealESRGANer(
|
| 85 |
scale=4,
|
| 86 |
+
model_path="E:\\huggingface\\flux-upscale\\upscale_models\\4x-UltraSharp.pth",
|
| 87 |
model=model
|
| 88 |
)
|
| 89 |
upscaled, _ = upsampler.enhance(img_array, outscale=4)
|
|
|
|
| 120 |
}
|
| 121 |
```
|
| 122 |
|
| 123 |
+
## Performance Tips
|
| 124 |
+
|
| 125 |
+
- **GPU Acceleration**: Use `half=True` for FP16 inference on compatible GPUs (2x faster)
|
| 126 |
+
- **Tiling**: For large images, enable tiling with `tile=512` to reduce VRAM usage
|
| 127 |
+
- **Batch Processing**: Process multiple images in sequence to amortize model loading time
|
| 128 |
+
- **CPU Fallback**: Models work on CPU but will be significantly slower
|
| 129 |
+
- **Optimal Scale**: Use 2x for faster processing, 4x for maximum detail enhancement
|
| 130 |
+
|
| 131 |
+
## Model Specifications
|
| 132 |
+
|
| 133 |
+
- **Architecture**: RRDB (Residual in Residual Dense Block)
|
| 134 |
+
- **Input Channels**: 3 (RGB)
|
| 135 |
+
- **Output Channels**: 3 (RGB)
|
| 136 |
+
- **Feature Dimensions**: 64
|
| 137 |
+
- **Blocks**: 23 (standard configuration)
|
| 138 |
+
- **Format**: PyTorch `.pth` files
|
| 139 |
+
- **Precision**: FP32 (supports FP16 inference)
|
| 140 |
+
|
| 141 |
+
## Links and Resources
|
| 142 |
+
|
| 143 |
+
- **Real-ESRGAN Paper**: [arXiv:2107.10833](https://arxiv.org/abs/2107.10833)
|
| 144 |
+
- **Official Repository**: [xinntao/Real-ESRGAN](https://github.com/xinntao/Real-ESRGAN)
|
| 145 |
+
- **BasicSR Library**: [xinntao/BasicSR](https://github.com/xinntao/BasicSR)
|
| 146 |
+
- **Model Downloads**: Available through official Real-ESRGAN releases
|
| 147 |
+
|
| 148 |
## Model Card Contact
|
| 149 |
|
| 150 |
+
For questions about Real-ESRGAN models, refer to the official Real-ESRGAN repository and documentation at https://github.com/xinntao/Real-ESRGAN
|