prateekralhan / Streamlit-based-Image-Super-Resolution-using-ESRGAN

A simple streamlit based webapp showcasing Image Super Resolution using ESRGAN

Repository from Github https://github.comprateekralhan/Streamlit-based-Image-Super-Resolution-using-ESRGANRepository from Github https://github.comprateekralhan/Streamlit-based-Image-Super-Resolution-using-ESRGAN

Streamlit based ISR using ESRGAN Project Status: Active

A simple streamlit based webapp demonstrating Image Super Resolution using ESRGAN.

demo

Installation:

  • Simply run the command pip install -r requirements.txt to install the dependencies.

Usage:

  1. Clone this repository and install the dependencies as mentioned above.
  2. Make a directory within this cloned repository with the name .streamlit (Don't forget the dot !!).
  3. Create a file config.toml in this directory (Be aware of the file extension !!).
  4. Copy-Paste the following contents in this file and save :
[theme]
primaryColor="#b11b1b"
backgroundColor="#080e1c"
secondaryBackgroundColor="#203659"
textColor="#bf7c7c"
  1. Navigate to the root directory and create another directory with the name models.
  2. Download pretrained models from here, and place them inside this directory.
  3. Navigate to the root directory of this repository and simply run the command:
streamlit run app.py

Navigate to http://localhost:8501 in your web-browser.

1

2

  1. By default, streamlit allows us to upload files of max. 200MB. If you want to have more size for uploading files, execute the command :
streamlit run app.py --server.maxUploadSize=1028

Results

Running the Dockerized App

  1. Ensure you have Docker Installed and Setup in your OS (Windows/Mac/Linux). For detailed Instructions, please refer this.
  2. Navigate to the folder where you have cloned this repository ( where the Dockerfile is present ).
  3. Build the Docker Image (don't forget the dot!! 😄 ):
docker build -f Dockerfile -t app:latest .
  1. Run the docker:
docker run -p 8501:8501 app:latest

This will launch the dockerized app. Navigate to http://localhost:8501/ in your browser to have a look at your application. You can check the status of your all available running dockers by:

docker ps

References:

https://github.com/xinntao/ESRGAN
@InProceedings{wang2018esrgan,
    author = {Wang, Xintao and Yu, Ke and Wu, Shixiang and Gu, Jinjin and Liu, Yihao and Dong, Chao and Qiao, Yu and Loy, Chen Change},
    title = {ESRGAN: Enhanced super-resolution generative adversarial networks},
    booktitle = {The European Conference on Computer Vision Workshops (ECCVW)},
    month = {September},
    year = {2018}
}

About

A simple streamlit based webapp showcasing Image Super Resolution using ESRGAN

License:MIT License


Languages

Language:Python 93.8%Language:Dockerfile 3.6%Language:Shell 2.2%Language:Procfile 0.4%