https://github.com/reshalfahsi/image-super-resolution
Image Super-Resolution Using ESRGAN
https://github.com/reshalfahsi/image-super-resolution
esrgan image-enhancement image-processing kornia pytorch-lightning super-resolution
Last synced: over 1 year ago
JSON representation
Image Super-Resolution Using ESRGAN
- Host: GitHub
- URL: https://github.com/reshalfahsi/image-super-resolution
- Owner: reshalfahsi
- Created: 2023-08-08T08:08:38.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-08-09T03:34:00.000Z (almost 3 years ago)
- Last Synced: 2025-01-15T07:14:45.398Z (over 1 year ago)
- Topics: esrgan, image-enhancement, image-processing, kornia, pytorch-lightning, super-resolution
- Language: Jupyter Notebook
- Homepage:
- Size: 7.38 MB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Image Super-Resolution Using ESRGAN
Image super-resolution attempts to produce pixels within the image to fill the lack of information due to its low-resolution nature. Hence, it yields a higher-resolution image. One approach to this problem is via generative networks, e.g., ESRGAN (Enhanced Super-Resolution Generative Adversarial Network). This type of GAN is built explicitly for image super-resolution by considering several losses, i.e., contextual loss (focus on the distribution of the feature), perceptual loss (pixel-wise loss), and adversarial loss. These three losses are utilized for the generator loss. On the contrary, the discriminator loss only takes into account the adversarial loss. There are two stages during training: (1) train only the generator on the perceptual loss, and (2) train the generator and discriminator based on those, as mentioned earlier. The model is trained and evaluated on the BSDS500 dataset. The final result of the predicted high-resolution image is subjected to the sharpening method by subtracting the image with the Laplacian of the image.
## Experiment
This [link](https://github.com/reshalfahsi/image-super-resolution/blob/master/ImageSuperResolution.ipynb) provides the code for the experiments.
## Result
## Quantitative Result
Quantitatively, the performance of ESRGAN after training with 420 epochs is presented as follows:
Metrics | Test Dataset |
------------ | ------------- |
PSNR | 22.587 |
SSIM | 0.586 |
MAE | 0.049 |
## Evaluation Metrics Curve
Generator and discriminator loss curves on the train setss.
PSNR curve on the train set and the validation set.
SSIM curve on the train set and the validation set.
MAE curve on the train set and the validation set.
## Qualitative Result
The qualitative results of the model are shown below.
Qualitative comparison between the reference high-resolution images (left column), high-resolution images via bicubic interpolation (middle column), and predicted high-resolution images through ESRGAN (right column).
## Credit
- [ESRGAN: Enhanced Super-Resolution Generative Adversarial Networks](https://arxiv.org/pdf/1809.00219.pdf)
- [Berkeley Segmentation Data Set and Benchmarks 500 (BSDS500)](https://github.com/BIDS/BSDS500)
- [Image Super-Resolution using an Efficient Sub-Pixel CNN](https://keras.io/examples/vision/super_resolution_sub_pixel/)
- [PyTorch-GAN](https://github.com/eriklindernoren/PyTorch-GAN)
- [PyTorch Lightning](https://lightning.ai/docs/pytorch/latest/)
- [Kornia](https://kornia.readthedocs.io/en/latest/index.html)