Learn more >
DeployableImage-to-Image Translation or Transformation
Get this modelTry the API
By IBM Developer Staff | Updated March 29, 2019 - Published March 25, 2019
Artificial intelligenceDeep learningVisual recognitionImage-to-Image Translation or Transformation
This model is able to upscale a pixelated image by a factor of 4, while generating photo-realistic details. The backbone of this neural network is a Generative Adversarial Network (GAN) trained on 600,000 images of the OpenImages V4 dataset.
The GAN is based on SRGAN-tensorflow GitHub repository and this research article.
The performance of this implementation was evaluated on three datasets: Set5, Set14, and BSD100.
The PSNR (peak signal to noise ratio) and SSIM (structural similarity index) metrics were evaluated, although the paper discusses
the MOS (mean opinion score) as the most favorable metric. In essence, the SRGAN implementation trades a better PSNR or SSIM score for a result more appealing to the human eye. This leads to a collection of output images with more crisp and realistic details.
NOTE: The SRGAN in the paper was trained on 350k ImageNet samples, whereas this SRGAN was trained on 600k OpenImages V4 pictures.
This model can be deployed using the following mechanisms:
Deploy from Dockerhub:
docker run -it -p 5000:5000 codait/max-image-resolution-enhancer
Deploy on Red Hat OpenShift:
Follow the instructions for the OpenShift web console or the OpenShift Container Platform CLI in this tutorial and specify codait/max-image-resolution-enhancer as the image name.
Deploy on Kubernetes:
kubectl apply -f https://raw.githubusercontent.com/IBM/MAX-Image-Resolution-Enhancer/master/max-image-resolution-enhancer.yaml
Locally: follow the instructions in the model README on GitHub
You can test or use this model using cURL
Use the model/predict endpoint to load a test image (you can use one of the test images from the assets/test_examples/low_resolution folder) in order to get a high resolution output image returned.
Once deployed, you can test the model from the command line. For example:
curl -F "image=@samples/test_examples/low_resolution/food.png" -XPOST http://localhost:5000/model/predict > food_high_res.png
The above command will send the low resolution food.png file to the model, and save the high resolution output image to the food_high_res.png file in the root directory.
The ideal input image is a PNG file with a resolution between 100×100 and 500×500, preferably without any post-capture processing and flashy colors. The model is able to generate details from a pixelated image (low DPI), but is not able to correct a ‘blurred’ image.
Left: input image (128×80). Right: output image (512×320)
Process image, video, audio, or text data using deep learning models from the Model Asset Exchange in Node-RED flows.
Artificial intelligenceDeep learning+
September 10, 2019
Artificial intelligenceData science+
Get an overview of computer vision with deep learning and learn how it can help your applications recognize what an…
Back to top