This post aims to explain how to colorize black and white infrared images using AI. If you have some infrared images in grayscale mode then you can now colorize them using AI. DeOldify is a free and open-source tool that you can use to do it with ease. It is basically meant to restore old photos, but the colorizer models that it has can color black while images as well that ho no visible light information in them.
We have used a tool before to color black and white images, but coloring infrared images is a whole another thing. Infrared images kind of have scattered color depth and there are not so many tools to process them. But luckily, DeOldify supports coloring those kinds of photos as well. And not only coloring but it actually generates multiple variations of the final images and you can save the ones that you think are the best.
How to Colorize Black and White Infrared Images using AI?
There are two ways in which you can use DeOldify. One is you can build it yourself. But in that case, you will need higher system requirements with state-of-the-art hardware. But there is another way as well, where you can download and use any of the pre-built models. And I am going to use the second method here to demonstrate how DeOldify works.
You can open the Google Colab Notebook from its GitHub repository in order to try it. The notebook looks like this. You can even make a copy of it in your Google account as well.
Now, you just start running every cell of the Colab. To run a cell, you just click inside it to activate it and then press Shift+Enter. Alternately, you can simply press the play button that appears when you activate a cell. In the beginning, it will download some dependencies and model files.
When you reach the input configuration cell, here you have to enter the URL of the image that you want to use. Just enter URL of the infrared B&W image and here and run this cell. It will take a few seconds and then it will generate a colorized image. Here you can see how intelligently it colors the input photos and images.
Run the final cell, and here it will generate multiple variations of colorized image. You can save all those images and then use them wherever you want.
This is how you can use this simple and powerful AI based tool to colorize black and white infrared images. The output is produces is pretty awesome and if you are a programmer then you can tweak some model parameters as well. Or, if you know advanced programming, then you can always train your own model. The instructions for that are given on its GitHub repository.
I am really impressed by the output that DeOldify produces. All you have to do is just give it a gray scaled image and it will take care of the rest. It intelligently colors the images and since it is open source and runs freely on Google Colab, there are no restrictions. There are no watermarks or restrictions on image resolutions.