https://github.com/lissettecarlr/real-esrgan-streamlit
基于Real-ESRGAN的图片超分辨率web交互
https://github.com/lissettecarlr/real-esrgan-streamlit
image-restoration jpeg-compression pytorch real-esrgan streamlit super-resolution
Last synced: 8 months ago
JSON representation
基于Real-ESRGAN的图片超分辨率web交互
- Host: GitHub
- URL: https://github.com/lissettecarlr/real-esrgan-streamlit
- Owner: lissettecarlr
- Created: 2024-11-07T01:43:09.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-11-07T08:11:00.000Z (11 months ago)
- Last Synced: 2025-02-20T03:42:35.887Z (8 months ago)
- Topics: image-restoration, jpeg-compression, pytorch, real-esrgan, streamlit, super-resolution
- Language: Python
- Homepage:
- Size: 7.46 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Real-ESRGAN-streamlit
基于[Real-ESRGAN](https://github.com/xinntao/Real-ESRGAN)的web交互图片超分辨率工具。
## 1 效果

------------------
![]()
原图
![]()
输出图## 2 安装
* python3.10
```bash
conda create -n SR python=3.10
conda activate SR
```* 安装依赖
```bash
pip install torch==2.1.1 torchvision==0.16.1 --index-url https://download.pytorch.org/whl/cu118
pip install -r requirements.txt
python setup.py develop
```## 3 模型
存放在`./weights`下
* [RealESRGAN_x4plus](https://github.com/xinntao/Real-ESRGAN/releases/download/v0.1.0/RealESRGAN_x4plus.pth):X4 模型用于一般图像
* [RealESRGAN_x2plus](https://github.com/xinntao/Real-ESRGAN/releases/download/v0.2.1/RealESRGAN_x2plus.pth):X2 模型用于一般图像
* [RealESRNet_x4plus](https://github.com/xinntao/Real-ESRGAN/releases/download/v0.1.1/RealESRNet_x4plus.pth):使用均方误差(MSE)作为损失函数,可能导致过度平滑的效果
* [RealESRGAN_x4plus_anime_6B](https://github.com/xinntao/Real-ESRGAN/releases/download/v0.2.2.4/RealESRGAN_x4plus_anime_6B.pth):针对动漫图像进行了优化## 4 使用
```bash
streamlit run web.py
```